@agenticmail/enterprise 0.5.81 → 0.5.82
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chunk-34JUBP5Q.js +9107 -0
- package/dist/chunk-CFEPEV5P.js +898 -0
- package/dist/chunk-HP2BGRVX.js +15035 -0
- package/dist/chunk-TQYCMFOC.js +2387 -0
- package/dist/chunk-UJFEKPLU.js +2191 -0
- package/dist/cli.js +1 -1
- package/dist/db-adapter-45VLU6DA.js +7 -0
- package/dist/index.js +5 -5
- package/dist/routes-JRYIFCOS.js +6759 -0
- package/dist/runtime-4IEMMVEK.js +47 -0
- package/dist/server-4PWWE5OI.js +12 -0
- package/dist/setup-OBJMVWSP.js +20 -0
- package/package.json +1 -1
- package/src/engine/db-adapter.ts +8 -2
- package/src/engine/lifecycle.ts +10 -1
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import {
|
|
2
|
+
AgentRuntime,
|
|
3
|
+
EmailChannel,
|
|
4
|
+
FollowUpScheduler,
|
|
5
|
+
SessionManager,
|
|
6
|
+
SubAgentManager,
|
|
7
|
+
ToolRegistry,
|
|
8
|
+
callLLM,
|
|
9
|
+
createAgentRuntime,
|
|
10
|
+
createNoopHooks,
|
|
11
|
+
createRuntimeHooks,
|
|
12
|
+
estimateMessageTokens,
|
|
13
|
+
estimateTokens,
|
|
14
|
+
executeTool,
|
|
15
|
+
runAgentLoop,
|
|
16
|
+
toolsToDefinitions
|
|
17
|
+
} from "./chunk-HP2BGRVX.js";
|
|
18
|
+
import "./chunk-TYW5XTOW.js";
|
|
19
|
+
import "./chunk-JLSQOQ5L.js";
|
|
20
|
+
import {
|
|
21
|
+
PROVIDER_REGISTRY,
|
|
22
|
+
listAllProviders,
|
|
23
|
+
resolveApiKeyForProvider,
|
|
24
|
+
resolveProvider
|
|
25
|
+
} from "./chunk-67KZYSLU.js";
|
|
26
|
+
import "./chunk-KFQGP6VL.js";
|
|
27
|
+
export {
|
|
28
|
+
AgentRuntime,
|
|
29
|
+
EmailChannel,
|
|
30
|
+
FollowUpScheduler,
|
|
31
|
+
PROVIDER_REGISTRY,
|
|
32
|
+
SessionManager,
|
|
33
|
+
SubAgentManager,
|
|
34
|
+
ToolRegistry,
|
|
35
|
+
callLLM,
|
|
36
|
+
createAgentRuntime,
|
|
37
|
+
createNoopHooks,
|
|
38
|
+
createRuntimeHooks,
|
|
39
|
+
estimateMessageTokens,
|
|
40
|
+
estimateTokens,
|
|
41
|
+
executeTool,
|
|
42
|
+
listAllProviders,
|
|
43
|
+
resolveApiKeyForProvider,
|
|
44
|
+
resolveProvider,
|
|
45
|
+
runAgentLoop,
|
|
46
|
+
toolsToDefinitions
|
|
47
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import {
|
|
2
|
+
createServer
|
|
3
|
+
} from "./chunk-UJFEKPLU.js";
|
|
4
|
+
import "./chunk-3SMTCIR4.js";
|
|
5
|
+
import "./chunk-JLSQOQ5L.js";
|
|
6
|
+
import "./chunk-RO537U6H.js";
|
|
7
|
+
import "./chunk-DRXMYYKN.js";
|
|
8
|
+
import "./chunk-67KZYSLU.js";
|
|
9
|
+
import "./chunk-KFQGP6VL.js";
|
|
10
|
+
export {
|
|
11
|
+
createServer
|
|
12
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import {
|
|
2
|
+
promptCompanyInfo,
|
|
3
|
+
promptDatabase,
|
|
4
|
+
promptDeployment,
|
|
5
|
+
promptDomain,
|
|
6
|
+
promptRegistration,
|
|
7
|
+
provision,
|
|
8
|
+
runSetupWizard
|
|
9
|
+
} from "./chunk-CFEPEV5P.js";
|
|
10
|
+
import "./chunk-QDXUZP7Y.js";
|
|
11
|
+
import "./chunk-KFQGP6VL.js";
|
|
12
|
+
export {
|
|
13
|
+
promptCompanyInfo,
|
|
14
|
+
promptDatabase,
|
|
15
|
+
promptDeployment,
|
|
16
|
+
promptDomain,
|
|
17
|
+
promptRegistration,
|
|
18
|
+
provision,
|
|
19
|
+
runSetupWizard
|
|
20
|
+
};
|
package/package.json
CHANGED
package/src/engine/db-adapter.ts
CHANGED
|
@@ -1022,10 +1022,11 @@ export class EngineDatabase {
|
|
|
1022
1022
|
}
|
|
1023
1023
|
|
|
1024
1024
|
private rowToManagedAgent(row: any): ManagedAgent {
|
|
1025
|
-
|
|
1025
|
+
const config = sj(row.config);
|
|
1026
|
+
const agent: ManagedAgent = {
|
|
1026
1027
|
id: row.id,
|
|
1027
1028
|
orgId: row.org_id,
|
|
1028
|
-
config
|
|
1029
|
+
config,
|
|
1029
1030
|
state: row.state,
|
|
1030
1031
|
stateHistory: [], // Loaded separately via getStateHistory
|
|
1031
1032
|
health: sj(row.health || '{}'),
|
|
@@ -1036,6 +1037,11 @@ export class EngineDatabase {
|
|
|
1036
1037
|
lastHealthCheckAt: row.last_health_check_at,
|
|
1037
1038
|
version: row.version,
|
|
1038
1039
|
};
|
|
1040
|
+
// Restore budgetConfig from config JSON
|
|
1041
|
+
if ((config as any)?.budgetConfig) {
|
|
1042
|
+
agent.budgetConfig = (config as any).budgetConfig;
|
|
1043
|
+
}
|
|
1044
|
+
return agent;
|
|
1039
1045
|
}
|
|
1040
1046
|
|
|
1041
1047
|
private rowToOrg(row: any): Organization {
|
package/src/engine/lifecycle.ts
CHANGED
|
@@ -708,6 +708,9 @@ export class AgentLifecycleManager {
|
|
|
708
708
|
const agent = this.agents.get(agentId);
|
|
709
709
|
if (!agent) throw new Error(`Agent ${agentId} not found`);
|
|
710
710
|
agent.budgetConfig = config;
|
|
711
|
+
// Also store in config JSON so it survives DB round-trips
|
|
712
|
+
if (!agent.config) agent.config = {} as any;
|
|
713
|
+
(agent.config as any).budgetConfig = config;
|
|
711
714
|
agent.updatedAt = new Date().toISOString();
|
|
712
715
|
await this.persistAgent(agent);
|
|
713
716
|
}
|
|
@@ -716,7 +719,13 @@ export class AgentLifecycleManager {
|
|
|
716
719
|
* Get per-agent budget configuration
|
|
717
720
|
*/
|
|
718
721
|
getBudgetConfig(agentId: string): AgentBudgetConfig | undefined {
|
|
719
|
-
|
|
722
|
+
const agent = this.agents.get(agentId);
|
|
723
|
+
if (!agent) return undefined;
|
|
724
|
+
// Restore from config JSON if not on top-level
|
|
725
|
+
if (!agent.budgetConfig && (agent.config as any)?.budgetConfig) {
|
|
726
|
+
agent.budgetConfig = (agent.config as any).budgetConfig;
|
|
727
|
+
}
|
|
728
|
+
return agent.budgetConfig;
|
|
720
729
|
}
|
|
721
730
|
|
|
722
731
|
/**
|