@theokit/sdk 5.15.0 → 5.15.1
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/CHANGELOG.md +12 -0
- package/dist/{agent-DRDGUU6T.js → agent-66U5QCPF.js} +5 -5
- package/dist/{agent-DRDGUU6T.js.map → agent-66U5QCPF.js.map} +1 -1
- package/dist/{agent-B6FQad6P.d.cts → agent-BL4kxgwq.d.cts} +7 -1
- package/dist/{agent-B6C9i_qu.d.ts → agent-ByDx7K30.d.ts} +7 -1
- package/dist/{agent-VI2HITPT.cjs → agent-CB27KF6O.cjs} +6 -6
- package/dist/{agent-VI2HITPT.cjs.map → agent-CB27KF6O.cjs.map} +1 -1
- package/dist/{chunk-IOBHFP2E.js → chunk-26GI3OYA.js} +71 -4
- package/dist/chunk-26GI3OYA.js.map +1 -0
- package/dist/{chunk-64ECM3XM.cjs → chunk-26UQG242.cjs} +49 -49
- package/dist/{chunk-64ECM3XM.cjs.map → chunk-26UQG242.cjs.map} +1 -1
- package/dist/{chunk-DJKGDLYZ.cjs → chunk-3E3VSMB6.cjs} +73 -6
- package/dist/{chunk-DJKGDLYZ.cjs.map → chunk-3E3VSMB6.cjs.map} +1 -1
- package/dist/{chunk-U7PRI3XM.cjs → chunk-FBIDOOJM.cjs} +3 -3
- package/dist/{chunk-U7PRI3XM.cjs.map → chunk-FBIDOOJM.cjs.map} +1 -1
- package/dist/{chunk-ARC2V7NY.js → chunk-O2RCS3SJ.js} +3 -3
- package/dist/{chunk-ARC2V7NY.js.map → chunk-O2RCS3SJ.js.map} +1 -1
- package/dist/{chunk-KMFBNKCT.cjs → chunk-TRPRTZEH.cjs} +4 -4
- package/dist/{chunk-KMFBNKCT.cjs.map → chunk-TRPRTZEH.cjs.map} +1 -1
- package/dist/{chunk-23SS4ID4.js → chunk-VNRNZ3WI.js} +3 -3
- package/dist/{chunk-23SS4ID4.js.map → chunk-VNRNZ3WI.js.map} +1 -1
- package/dist/{chunk-5M5GQYBM.js → chunk-ZQWRUJHE.js} +6 -6
- package/dist/{chunk-5M5GQYBM.js.map → chunk-ZQWRUJHE.js.map} +1 -1
- package/dist/{compact-session-NX7HUNTB.cjs → compact-session-CHBJOYWP.cjs} +12 -12
- package/dist/{compact-session-NX7HUNTB.cjs.map → compact-session-CHBJOYWP.cjs.map} +1 -1
- package/dist/{compact-session-Q5IGNFPW.js → compact-session-F3J3FMEU.js} +3 -3
- package/dist/{compact-session-Q5IGNFPW.js.map → compact-session-F3J3FMEU.js.map} +1 -1
- package/dist/{cron-Bh3aWgQ2.d.cts → cron-B7KH9sHW.d.cts} +1 -1
- package/dist/{cron-CCDxeeFZ.d.ts → cron-FEO7UAQF.d.ts} +1 -1
- package/dist/cron.cjs +5 -5
- package/dist/cron.d.cts +2 -2
- package/dist/cron.d.ts +2 -2
- package/dist/cron.js +4 -4
- package/dist/eval.cjs +4 -4
- package/dist/eval.js +3 -3
- package/dist/index.cjs +31 -31
- package/dist/index.d.cts +3 -3
- package/dist/index.d.ts +3 -3
- package/dist/index.js +7 -7
- package/dist/{inject-session-4ROYLZHY.js → inject-session-LC2TROHM.js} +3 -3
- package/dist/{inject-session-4ROYLZHY.js.map → inject-session-LC2TROHM.js.map} +1 -1
- package/dist/{inject-session-AWKDCGHV.cjs → inject-session-T4RXANG3.cjs} +4 -4
- package/dist/{inject-session-AWKDCGHV.cjs.map → inject-session-T4RXANG3.cjs.map} +1 -1
- package/dist/internal/llm/hermes-tool-extract.d.ts +2 -0
- package/dist/subagents-loader.d.cts +1 -1
- package/dist/subagents-loader.d.ts +1 -1
- package/dist/types/hooks.d.ts +7 -1
- package/package.json +1 -1
- package/dist/chunk-IOBHFP2E.js.map +0 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunk3E3VSMB6_cjs = require('./chunk-3E3VSMB6.cjs');
|
|
4
4
|
require('./chunk-55LLQFHW.cjs');
|
|
5
5
|
require('./chunk-YJNYDJ2T.cjs');
|
|
6
6
|
require('./chunk-3F53FLQ7.cjs');
|
|
@@ -28,39 +28,39 @@ require('./chunk-RNXXYF22.cjs');
|
|
|
28
28
|
|
|
29
29
|
Object.defineProperty(exports, "COMPACT_SUMMARY_MARKER", {
|
|
30
30
|
enumerable: true,
|
|
31
|
-
get: function () { return
|
|
31
|
+
get: function () { return chunk3E3VSMB6_cjs.COMPACT_SUMMARY_MARKER; }
|
|
32
32
|
});
|
|
33
33
|
Object.defineProperty(exports, "COMPACT_USER_MESSAGE_MAX_TOKENS", {
|
|
34
34
|
enumerable: true,
|
|
35
|
-
get: function () { return
|
|
35
|
+
get: function () { return chunk3E3VSMB6_cjs.COMPACT_USER_MESSAGE_MAX_TOKENS; }
|
|
36
36
|
});
|
|
37
37
|
Object.defineProperty(exports, "DEFAULT_PRE_COMPACT_TIMEOUT_MS", {
|
|
38
38
|
enumerable: true,
|
|
39
|
-
get: function () { return
|
|
39
|
+
get: function () { return chunk3E3VSMB6_cjs.DEFAULT_PRE_COMPACT_TIMEOUT_MS; }
|
|
40
40
|
});
|
|
41
41
|
Object.defineProperty(exports, "autoCompactIfNeeded", {
|
|
42
42
|
enumerable: true,
|
|
43
|
-
get: function () { return
|
|
43
|
+
get: function () { return chunk3E3VSMB6_cjs.autoCompactIfNeeded; }
|
|
44
44
|
});
|
|
45
45
|
Object.defineProperty(exports, "buildDefaultSummarizer", {
|
|
46
46
|
enumerable: true,
|
|
47
|
-
get: function () { return
|
|
47
|
+
get: function () { return chunk3E3VSMB6_cjs.buildDefaultSummarizer; }
|
|
48
48
|
});
|
|
49
49
|
Object.defineProperty(exports, "compactSessionTranscript", {
|
|
50
50
|
enumerable: true,
|
|
51
|
-
get: function () { return
|
|
51
|
+
get: function () { return chunk3E3VSMB6_cjs.compactSessionTranscript; }
|
|
52
52
|
});
|
|
53
53
|
Object.defineProperty(exports, "isCompactSummary", {
|
|
54
54
|
enumerable: true,
|
|
55
|
-
get: function () { return
|
|
55
|
+
get: function () { return chunk3E3VSMB6_cjs.isCompactSummary; }
|
|
56
56
|
});
|
|
57
57
|
Object.defineProperty(exports, "resolveSummarizerRoute", {
|
|
58
58
|
enumerable: true,
|
|
59
|
-
get: function () { return
|
|
59
|
+
get: function () { return chunk3E3VSMB6_cjs.resolveSummarizerRoute; }
|
|
60
60
|
});
|
|
61
61
|
Object.defineProperty(exports, "shouldAutoCompact", {
|
|
62
62
|
enumerable: true,
|
|
63
|
-
get: function () { return
|
|
63
|
+
get: function () { return chunk3E3VSMB6_cjs.shouldAutoCompact; }
|
|
64
64
|
});
|
|
65
|
-
//# sourceMappingURL=compact-session-
|
|
66
|
-
//# sourceMappingURL=compact-session-
|
|
65
|
+
//# sourceMappingURL=compact-session-CHBJOYWP.cjs.map
|
|
66
|
+
//# sourceMappingURL=compact-session-CHBJOYWP.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":[],"names":[],"mappings":"","file":"compact-session-
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"compact-session-CHBJOYWP.cjs"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { COMPACT_SUMMARY_MARKER, COMPACT_USER_MESSAGE_MAX_TOKENS, DEFAULT_PRE_COMPACT_TIMEOUT_MS, autoCompactIfNeeded, buildDefaultSummarizer, compactSessionTranscript, isCompactSummary, resolveSummarizerRoute, shouldAutoCompact } from './chunk-
|
|
1
|
+
export { COMPACT_SUMMARY_MARKER, COMPACT_USER_MESSAGE_MAX_TOKENS, DEFAULT_PRE_COMPACT_TIMEOUT_MS, autoCompactIfNeeded, buildDefaultSummarizer, compactSessionTranscript, isCompactSummary, resolveSummarizerRoute, shouldAutoCompact } from './chunk-26GI3OYA.js';
|
|
2
2
|
import './chunk-NK5EOTDY.js';
|
|
3
3
|
import './chunk-2XC6KDJM.js';
|
|
4
4
|
import './chunk-7ACS6P5Z.js';
|
|
@@ -21,5 +21,5 @@ import './chunk-5IUDICRK.js';
|
|
|
21
21
|
import './chunk-Q7GYMXVC.js';
|
|
22
22
|
import './chunk-TNFOU6SB.js';
|
|
23
23
|
import './chunk-3OY6H3I7.js';
|
|
24
|
-
//# sourceMappingURL=compact-session-
|
|
25
|
-
//# sourceMappingURL=compact-session-
|
|
24
|
+
//# sourceMappingURL=compact-session-F3J3FMEU.js.map
|
|
25
|
+
//# sourceMappingURL=compact-session-F3J3FMEU.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":[],"names":[],"mappings":"","file":"compact-session-
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"compact-session-F3J3FMEU.js"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Workflow, WorkflowRun } from './workflow.cjs';
|
|
2
|
-
import { A as AgentOptions, d as ListResult } from './agent-
|
|
2
|
+
import { A as AgentOptions, d as ListResult } from './agent-BL4kxgwq.cjs';
|
|
3
3
|
import { aJ as SDKUserMessage, b as Run } from './sdk-agent-BA_6_wtc.cjs';
|
|
4
4
|
|
|
5
5
|
/**
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Workflow, WorkflowRun } from './workflow.js';
|
|
2
|
-
import { A as AgentOptions, d as ListResult } from './agent-
|
|
2
|
+
import { A as AgentOptions, d as ListResult } from './agent-ByDx7K30.js';
|
|
3
3
|
import { aJ as SDKUserMessage, b as Run } from './sdk-agent-CnwPODYH.js';
|
|
4
4
|
|
|
5
5
|
/**
|
package/dist/cron.cjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
require('./chunk-
|
|
3
|
+
var chunkTRPRTZEH_cjs = require('./chunk-TRPRTZEH.cjs');
|
|
4
|
+
require('./chunk-26UQG242.cjs');
|
|
5
5
|
require('./chunk-L7JPXZ2C.cjs');
|
|
6
|
-
require('./chunk-
|
|
6
|
+
require('./chunk-FBIDOOJM.cjs');
|
|
7
7
|
require('./chunk-BUUUWQMB.cjs');
|
|
8
8
|
require('./chunk-NEH3BPFD.cjs');
|
|
9
9
|
require('./chunk-7YUPSBDV.cjs');
|
|
@@ -13,7 +13,7 @@ require('./chunk-GHX4P3V2.cjs');
|
|
|
13
13
|
require('./chunk-RS7YQR4X.cjs');
|
|
14
14
|
require('./chunk-VWYFGE27.cjs');
|
|
15
15
|
require('./chunk-FTXY4D44.cjs');
|
|
16
|
-
require('./chunk-
|
|
16
|
+
require('./chunk-3E3VSMB6.cjs');
|
|
17
17
|
require('./chunk-55LLQFHW.cjs');
|
|
18
18
|
require('./chunk-YJNYDJ2T.cjs');
|
|
19
19
|
require('./chunk-3F53FLQ7.cjs');
|
|
@@ -67,7 +67,7 @@ require('./chunk-RNXXYF22.cjs');
|
|
|
67
67
|
|
|
68
68
|
Object.defineProperty(exports, "Cron", {
|
|
69
69
|
enumerable: true,
|
|
70
|
-
get: function () { return
|
|
70
|
+
get: function () { return chunkTRPRTZEH_cjs.Cron; }
|
|
71
71
|
});
|
|
72
72
|
//# sourceMappingURL=cron.cjs.map
|
|
73
73
|
//# sourceMappingURL=cron.cjs.map
|
package/dist/cron.d.cts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import './workflow.cjs';
|
|
2
|
-
import './agent-
|
|
2
|
+
import './agent-BL4kxgwq.cjs';
|
|
3
3
|
import './sdk-agent-BA_6_wtc.cjs';
|
|
4
|
-
export { C as Cron } from './cron-
|
|
4
|
+
export { C as Cron } from './cron-B7KH9sHW.cjs';
|
|
5
5
|
import 'zod';
|
|
6
6
|
import './errors-base-B5g01neU.cjs';
|
|
7
7
|
import './agent-prims-CZyxfCmS.cjs';
|
package/dist/cron.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import './workflow.js';
|
|
2
|
-
import './agent-
|
|
2
|
+
import './agent-ByDx7K30.js';
|
|
3
3
|
import './sdk-agent-CnwPODYH.js';
|
|
4
|
-
export { C as Cron } from './cron-
|
|
4
|
+
export { C as Cron } from './cron-FEO7UAQF.js';
|
|
5
5
|
import 'zod';
|
|
6
6
|
import './errors-base-B5g01neU.js';
|
|
7
7
|
import './agent-prims-CZyxfCmS.js';
|
package/dist/cron.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { Cron } from './chunk-
|
|
2
|
-
import './chunk-
|
|
1
|
+
export { Cron } from './chunk-O2RCS3SJ.js';
|
|
2
|
+
import './chunk-ZQWRUJHE.js';
|
|
3
3
|
import './chunk-HWMGR3HA.js';
|
|
4
|
-
import './chunk-
|
|
4
|
+
import './chunk-VNRNZ3WI.js';
|
|
5
5
|
import './chunk-K2BQQ445.js';
|
|
6
6
|
import './chunk-3BBTHFGJ.js';
|
|
7
7
|
import './chunk-HJ2LV464.js';
|
|
@@ -11,7 +11,7 @@ import './chunk-H73MEMQB.js';
|
|
|
11
11
|
import './chunk-QK2ERTO3.js';
|
|
12
12
|
import './chunk-LCCT5ZXJ.js';
|
|
13
13
|
import './chunk-RGVMJU57.js';
|
|
14
|
-
import './chunk-
|
|
14
|
+
import './chunk-26GI3OYA.js';
|
|
15
15
|
import './chunk-NK5EOTDY.js';
|
|
16
16
|
import './chunk-2XC6KDJM.js';
|
|
17
17
|
import './chunk-7ACS6P5Z.js';
|
package/dist/eval.cjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var chunkFLDHYF5C_cjs = require('./chunk-FLDHYF5C.cjs');
|
|
4
|
-
var
|
|
4
|
+
var chunk26UQG242_cjs = require('./chunk-26UQG242.cjs');
|
|
5
5
|
require('./chunk-L7JPXZ2C.cjs');
|
|
6
|
-
require('./chunk-
|
|
6
|
+
require('./chunk-FBIDOOJM.cjs');
|
|
7
7
|
var chunkBUUUWQMB_cjs = require('./chunk-BUUUWQMB.cjs');
|
|
8
8
|
require('./chunk-NEH3BPFD.cjs');
|
|
9
9
|
require('./chunk-7YUPSBDV.cjs');
|
|
@@ -13,7 +13,7 @@ require('./chunk-GHX4P3V2.cjs');
|
|
|
13
13
|
require('./chunk-RS7YQR4X.cjs');
|
|
14
14
|
require('./chunk-VWYFGE27.cjs');
|
|
15
15
|
require('./chunk-FTXY4D44.cjs');
|
|
16
|
-
require('./chunk-
|
|
16
|
+
require('./chunk-3E3VSMB6.cjs');
|
|
17
17
|
require('./chunk-55LLQFHW.cjs');
|
|
18
18
|
require('./chunk-YJNYDJ2T.cjs');
|
|
19
19
|
require('./chunk-3F53FLQ7.cjs');
|
|
@@ -800,7 +800,7 @@ function makeDefaultEmbedder(opts) {
|
|
|
800
800
|
let runtime;
|
|
801
801
|
return (texts) => {
|
|
802
802
|
if (runtime === void 0) {
|
|
803
|
-
runtime =
|
|
803
|
+
runtime = chunk26UQG242_cjs.openRouterMemoryEmbeddingProviderAdapter.create(embedderCreateOptions(opts));
|
|
804
804
|
}
|
|
805
805
|
return runtime.then((rt) => rt.embed(texts));
|
|
806
806
|
};
|
package/dist/eval.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { shellEscapePosix, LocalSandbox } from './chunk-QGDPMM3C.js';
|
|
2
|
-
import { openRouterMemoryEmbeddingProviderAdapter } from './chunk-
|
|
2
|
+
import { openRouterMemoryEmbeddingProviderAdapter } from './chunk-ZQWRUJHE.js';
|
|
3
3
|
import './chunk-HWMGR3HA.js';
|
|
4
|
-
import './chunk-
|
|
4
|
+
import './chunk-VNRNZ3WI.js';
|
|
5
5
|
import { getTracer } from './chunk-K2BQQ445.js';
|
|
6
6
|
import './chunk-3BBTHFGJ.js';
|
|
7
7
|
import './chunk-HJ2LV464.js';
|
|
@@ -11,7 +11,7 @@ import './chunk-H73MEMQB.js';
|
|
|
11
11
|
import './chunk-QK2ERTO3.js';
|
|
12
12
|
import './chunk-LCCT5ZXJ.js';
|
|
13
13
|
import './chunk-RGVMJU57.js';
|
|
14
|
-
import './chunk-
|
|
14
|
+
import './chunk-26GI3OYA.js';
|
|
15
15
|
import './chunk-NK5EOTDY.js';
|
|
16
16
|
import './chunk-2XC6KDJM.js';
|
|
17
17
|
import './chunk-7ACS6P5Z.js';
|
package/dist/index.cjs
CHANGED
|
@@ -10,10 +10,10 @@ var chunkR35ZJAYT_cjs = require('./chunk-R35ZJAYT.cjs');
|
|
|
10
10
|
require('./chunk-SETHRLQS.cjs');
|
|
11
11
|
var chunkBNEUB52I_cjs = require('./chunk-BNEUB52I.cjs');
|
|
12
12
|
require('./chunk-VTYY7XL5.cjs');
|
|
13
|
-
var
|
|
14
|
-
var
|
|
13
|
+
var chunkTRPRTZEH_cjs = require('./chunk-TRPRTZEH.cjs');
|
|
14
|
+
var chunk26UQG242_cjs = require('./chunk-26UQG242.cjs');
|
|
15
15
|
var chunkL7JPXZ2C_cjs = require('./chunk-L7JPXZ2C.cjs');
|
|
16
|
-
require('./chunk-
|
|
16
|
+
require('./chunk-FBIDOOJM.cjs');
|
|
17
17
|
require('./chunk-BUUUWQMB.cjs');
|
|
18
18
|
require('./chunk-NEH3BPFD.cjs');
|
|
19
19
|
require('./chunk-7YUPSBDV.cjs');
|
|
@@ -23,7 +23,7 @@ require('./chunk-GHX4P3V2.cjs');
|
|
|
23
23
|
require('./chunk-RS7YQR4X.cjs');
|
|
24
24
|
var chunkVWYFGE27_cjs = require('./chunk-VWYFGE27.cjs');
|
|
25
25
|
var chunkFTXY4D44_cjs = require('./chunk-FTXY4D44.cjs');
|
|
26
|
-
var
|
|
26
|
+
var chunk3E3VSMB6_cjs = require('./chunk-3E3VSMB6.cjs');
|
|
27
27
|
require('./chunk-55LLQFHW.cjs');
|
|
28
28
|
require('./chunk-YJNYDJ2T.cjs');
|
|
29
29
|
require('./chunk-3F53FLQ7.cjs');
|
|
@@ -81,8 +81,8 @@ var os = require('os');
|
|
|
81
81
|
// src/agent-factory.ts
|
|
82
82
|
function createAgentFactory(common) {
|
|
83
83
|
return {
|
|
84
|
-
forSession: (agentId, overrides) =>
|
|
85
|
-
getOrCreate: (agentId, overrides) =>
|
|
84
|
+
forSession: (agentId, overrides) => chunk26UQG242_cjs.Agent.create(mergeAgentOptions(common, overrides, agentId)),
|
|
85
|
+
getOrCreate: (agentId, overrides) => chunk26UQG242_cjs.Agent.getOrCreate(agentId, mergeAgentOptions(common, overrides, agentId))
|
|
86
86
|
};
|
|
87
87
|
}
|
|
88
88
|
function mergeAgentOptions(common, overrides, agentId) {
|
|
@@ -1100,7 +1100,7 @@ var Memory = {
|
|
|
1100
1100
|
return await peer.IndexManager.open(openArgs);
|
|
1101
1101
|
}
|
|
1102
1102
|
const { IndexManager } = await import('./index-manager-2KH75BRW.cjs');
|
|
1103
|
-
openArgs.embedding = await resolveEmbedding(opts.embedding,
|
|
1103
|
+
openArgs.embedding = await resolveEmbedding(opts.embedding, chunk26UQG242_cjs.MEMORY_EMBEDDING_ADAPTERS);
|
|
1104
1104
|
return await IndexManager.open(openArgs);
|
|
1105
1105
|
},
|
|
1106
1106
|
/**
|
|
@@ -1111,7 +1111,7 @@ var Memory = {
|
|
|
1111
1111
|
*/
|
|
1112
1112
|
async runDreamingSweep(opts) {
|
|
1113
1113
|
const peer = await tryLoadSdkMemoryPeer();
|
|
1114
|
-
const catalog = peer !== null ? peer.MEMORY_EMBEDDING_ADAPTERS :
|
|
1114
|
+
const catalog = peer !== null ? peer.MEMORY_EMBEDDING_ADAPTERS : chunk26UQG242_cjs.MEMORY_EMBEDDING_ADAPTERS;
|
|
1115
1115
|
const sweepArgs = await buildDreamingSweepArgs(opts, catalog);
|
|
1116
1116
|
const result = peer !== null ? (
|
|
1117
1117
|
// biome-ignore lint/suspicious/noExplicitAny: peer is dynamically loaded — structural compat ensured by sdk-memory
|
|
@@ -1722,7 +1722,7 @@ function guardSessionDestruction(sessionId, live) {
|
|
|
1722
1722
|
// src/session-messages.ts
|
|
1723
1723
|
async function readSessionMessages2(options) {
|
|
1724
1724
|
const cwd = options.cwd ?? process.cwd();
|
|
1725
|
-
const baseDir =
|
|
1725
|
+
const baseDir = chunk26UQG242_cjs.resolveSessionDir({ sessionDir: options.sessionDir });
|
|
1726
1726
|
return chunkMSW7LB2V_cjs.readSessionMessages(new chunkFTXY4D44_cjs.FsSessionStore({ baseDir, cwd }), options.sessionId);
|
|
1727
1727
|
}
|
|
1728
1728
|
|
|
@@ -1739,7 +1739,7 @@ function isBuiltAgent(m) {
|
|
|
1739
1739
|
return typeof m.send === "function";
|
|
1740
1740
|
}
|
|
1741
1741
|
async function materialize(def, index) {
|
|
1742
|
-
const { Agent: Agent2 } = await import('./agent-
|
|
1742
|
+
const { Agent: Agent2 } = await import('./agent-CB27KF6O.cjs');
|
|
1743
1743
|
return Agent2.create({
|
|
1744
1744
|
// `AgentDefinition.model` admits the sentinel `'inherit'`, which is not a model id. Inheriting
|
|
1745
1745
|
// here means "declare nothing and let the default apply" — forwarding the literal would create
|
|
@@ -1881,7 +1881,7 @@ var FIXTURE_USER = {
|
|
|
1881
1881
|
};
|
|
1882
1882
|
var FIXTURE_MODELS = [
|
|
1883
1883
|
{
|
|
1884
|
-
id:
|
|
1884
|
+
id: chunk26UQG242_cjs.DEFAULT_AGENTIC_MODEL_ID,
|
|
1885
1885
|
name: "Gemini 2.0 Flash",
|
|
1886
1886
|
displayName: "Gemini 2.0 Flash",
|
|
1887
1887
|
parameters: [
|
|
@@ -1957,7 +1957,7 @@ async function listLocalModelsViaOpenAiCompat(baseUrl) {
|
|
|
1957
1957
|
try {
|
|
1958
1958
|
response = await fetch(url, { method: "GET" });
|
|
1959
1959
|
} catch (fetchErr) {
|
|
1960
|
-
const mapped =
|
|
1960
|
+
const mapped = chunk3E3VSMB6_cjs.mapOllamaTransportError({
|
|
1961
1961
|
providerId: "ollama",
|
|
1962
1962
|
cause: fetchErr,
|
|
1963
1963
|
endpoint: "/v1/models"
|
|
@@ -1969,8 +1969,8 @@ async function listLocalModelsViaOpenAiCompat(baseUrl) {
|
|
|
1969
1969
|
);
|
|
1970
1970
|
}
|
|
1971
1971
|
if (!response.ok) {
|
|
1972
|
-
const body = await
|
|
1973
|
-
const mapped =
|
|
1972
|
+
const body = await chunk3E3VSMB6_cjs.readErrorResponseBody(response);
|
|
1973
|
+
const mapped = chunk3E3VSMB6_cjs.mapOllamaHttpError({
|
|
1974
1974
|
providerId: "ollama",
|
|
1975
1975
|
status: response.status,
|
|
1976
1976
|
body,
|
|
@@ -2084,7 +2084,7 @@ var Theokit = class {
|
|
|
2084
2084
|
envVars: p.envVars
|
|
2085
2085
|
}));
|
|
2086
2086
|
},
|
|
2087
|
-
embeddingAdapters: () => Object.entries(
|
|
2087
|
+
embeddingAdapters: () => Object.entries(chunk26UQG242_cjs.MEMORY_EMBEDDING_ADAPTERS).map(([id, adapter]) => ({
|
|
2088
2088
|
id,
|
|
2089
2089
|
transport: adapter.transport,
|
|
2090
2090
|
defaultModel: adapter.defaultModel
|
|
@@ -2102,7 +2102,7 @@ var Theokit = class {
|
|
|
2102
2102
|
};
|
|
2103
2103
|
async function maybeListLocalModels(providerName) {
|
|
2104
2104
|
chunkP7QYG4RZ_cjs.registerBuiltins();
|
|
2105
|
-
await
|
|
2105
|
+
await chunk3E3VSMB6_cjs.discoverProviderPlugins();
|
|
2106
2106
|
const profile = chunkP7QYG4RZ_cjs.getProviderProfile(providerName);
|
|
2107
2107
|
if (profile === void 0) return void 0;
|
|
2108
2108
|
if (profile.authType !== "none") return void 0;
|
|
@@ -2120,13 +2120,13 @@ async function executeCatalogRequest(request) {
|
|
|
2120
2120
|
if (apiKey === void 0) {
|
|
2121
2121
|
throw new chunkCEGU5AVD_cjs.AuthenticationError("Missing API key", { code: "missing_api_key" });
|
|
2122
2122
|
}
|
|
2123
|
-
if (
|
|
2123
|
+
if (chunk3E3VSMB6_cjs.shouldUseFixtureMode(apiKey)) {
|
|
2124
2124
|
return request.fixture;
|
|
2125
2125
|
}
|
|
2126
|
-
if (!
|
|
2126
|
+
if (!chunk3E3VSMB6_cjs.isFixtureApiKey(apiKey) && process.env.THEOKIT_API_BASE_URL === void 0) {
|
|
2127
2127
|
throw new chunkCEGU5AVD_cjs.AuthenticationError("Invalid API key", { code: "authentication_error" });
|
|
2128
2128
|
}
|
|
2129
|
-
return
|
|
2129
|
+
return chunk3E3VSMB6_cjs.httpRequest(request.path, { apiKey });
|
|
2130
2130
|
}
|
|
2131
2131
|
|
|
2132
2132
|
// src/tool-blast-radius.ts
|
|
@@ -2307,43 +2307,43 @@ Object.defineProperty(exports, "SqliteSessionStore", {
|
|
|
2307
2307
|
});
|
|
2308
2308
|
Object.defineProperty(exports, "Cron", {
|
|
2309
2309
|
enumerable: true,
|
|
2310
|
-
get: function () { return
|
|
2310
|
+
get: function () { return chunkTRPRTZEH_cjs.Cron; }
|
|
2311
2311
|
});
|
|
2312
2312
|
Object.defineProperty(exports, "Agent", {
|
|
2313
2313
|
enumerable: true,
|
|
2314
|
-
get: function () { return
|
|
2314
|
+
get: function () { return chunk26UQG242_cjs.Agent; }
|
|
2315
2315
|
});
|
|
2316
2316
|
Object.defineProperty(exports, "AgentBuilder", {
|
|
2317
2317
|
enumerable: true,
|
|
2318
|
-
get: function () { return
|
|
2318
|
+
get: function () { return chunk26UQG242_cjs.AgentBuilder; }
|
|
2319
2319
|
});
|
|
2320
2320
|
Object.defineProperty(exports, "Tool", {
|
|
2321
2321
|
enumerable: true,
|
|
2322
|
-
get: function () { return
|
|
2322
|
+
get: function () { return chunk26UQG242_cjs.Tool; }
|
|
2323
2323
|
});
|
|
2324
2324
|
Object.defineProperty(exports, "ToolError", {
|
|
2325
2325
|
enumerable: true,
|
|
2326
|
-
get: function () { return
|
|
2326
|
+
get: function () { return chunk26UQG242_cjs.ToolError; }
|
|
2327
2327
|
});
|
|
2328
2328
|
Object.defineProperty(exports, "UsageAccumulator", {
|
|
2329
2329
|
enumerable: true,
|
|
2330
|
-
get: function () { return
|
|
2330
|
+
get: function () { return chunk26UQG242_cjs.UsageAccumulator; }
|
|
2331
2331
|
});
|
|
2332
2332
|
Object.defineProperty(exports, "computeCost", {
|
|
2333
2333
|
enumerable: true,
|
|
2334
|
-
get: function () { return
|
|
2334
|
+
get: function () { return chunk26UQG242_cjs.computeCost; }
|
|
2335
2335
|
});
|
|
2336
2336
|
Object.defineProperty(exports, "getPricingEntry", {
|
|
2337
2337
|
enumerable: true,
|
|
2338
|
-
get: function () { return
|
|
2338
|
+
get: function () { return chunk26UQG242_cjs.getPricingEntry; }
|
|
2339
2339
|
});
|
|
2340
2340
|
Object.defineProperty(exports, "managedSettingsPathFor", {
|
|
2341
2341
|
enumerable: true,
|
|
2342
|
-
get: function () { return
|
|
2342
|
+
get: function () { return chunk26UQG242_cjs.managedSettingsPathFor; }
|
|
2343
2343
|
});
|
|
2344
2344
|
Object.defineProperty(exports, "readManagedSettings", {
|
|
2345
2345
|
enumerable: true,
|
|
2346
|
-
get: function () { return
|
|
2346
|
+
get: function () { return chunk26UQG242_cjs.readManagedSettings; }
|
|
2347
2347
|
});
|
|
2348
2348
|
Object.defineProperty(exports, "emitRunEvent", {
|
|
2349
2349
|
enumerable: true,
|
|
@@ -2351,11 +2351,11 @@ Object.defineProperty(exports, "emitRunEvent", {
|
|
|
2351
2351
|
});
|
|
2352
2352
|
Object.defineProperty(exports, "inferApiMode", {
|
|
2353
2353
|
enumerable: true,
|
|
2354
|
-
get: function () { return
|
|
2354
|
+
get: function () { return chunk3E3VSMB6_cjs.inferApiMode; }
|
|
2355
2355
|
});
|
|
2356
2356
|
Object.defineProperty(exports, "normalizeUsage", {
|
|
2357
2357
|
enumerable: true,
|
|
2358
|
-
get: function () { return
|
|
2358
|
+
get: function () { return chunk3E3VSMB6_cjs.normalizeUsage; }
|
|
2359
2359
|
});
|
|
2360
2360
|
Object.defineProperty(exports, "withCwdMutex", {
|
|
2361
2361
|
enumerable: true,
|
package/dist/index.d.cts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { T as TheokitAgentError, E as ErrorMetadata } from './errors-base-B5g01neU.cjs';
|
|
2
2
|
export { a as ErrorCode } from './errors-base-B5g01neU.cjs';
|
|
3
|
-
import { A as AgentOptions, L as LocalOptions, B as BuiltinToolName, M as MemorySettings, S as SystemPromptResolver, C as CloudOptions, a as AgentDefinition, b as SkillsSettings, c as ListAgentsOptions, d as ListResult, e as SDKAgentInfo, G as GetAgentOptions, f as ListRunsOptions, g as GetRunOptions, h as AgentOperationOptions, i as AgentDescription, P as Plugin$1, j as ProviderProfile, I as InlineSkill, k as Skill, l as BudgetTracker, m as MemoryProvider, n as PreToolCallDecision } from './agent-
|
|
4
|
-
export { o as ActiveMemoryPassArgs, p as ActiveMemoryPassResult, q as AgentSubagentDescription, r as AgentToolDescription, s as BudgetCheck, t as BudgetTotal, u as BudgetUsageEvent, v as CloudEnv, w as CloudRepo, x as CompatSource, y as CompatSourceAdapter, z as CompatSurface, D as CreateSkillSpec, H as HookApprovalGate, E as HookApprovalRequest, F as HookName, J as LlmCallContext, K as MemoryProviderAgentRef, N as MemoryProviderFactory, O as MemoryProviderHandle, Q as MemoryProviderInitOptions, R as PluginContext, T as PluginHookDisposer, U as PostAssistantReplyContext, V as PostToolCallContext, W as PreToolCallContext, X as PreUserSendContext, Y as PreUserSendResult, Z as ProviderTransform, _ as ProviderTransformContext, $ as RecordSessionSummaryArgs, a0 as SessionLifecycleContext, a1 as SettingSource, a2 as Skill, a3 as SkillsResolver, a4 as SkillsResolverContext, a5 as SystemPromptContext, a6 as SystemPromptMemoryFact, a7 as TelemetrySettings, a8 as ToolCallSummary, a9 as ToolContext, aa as ToolResultTransformContext, ab as TransformContext } from './agent-
|
|
3
|
+
import { A as AgentOptions, L as LocalOptions, B as BuiltinToolName, M as MemorySettings, S as SystemPromptResolver, C as CloudOptions, a as AgentDefinition, b as SkillsSettings, c as ListAgentsOptions, d as ListResult, e as SDKAgentInfo, G as GetAgentOptions, f as ListRunsOptions, g as GetRunOptions, h as AgentOperationOptions, i as AgentDescription, P as Plugin$1, j as ProviderProfile, I as InlineSkill, k as Skill, l as BudgetTracker, m as MemoryProvider, n as PreToolCallDecision } from './agent-BL4kxgwq.cjs';
|
|
4
|
+
export { o as ActiveMemoryPassArgs, p as ActiveMemoryPassResult, q as AgentSubagentDescription, r as AgentToolDescription, s as BudgetCheck, t as BudgetTotal, u as BudgetUsageEvent, v as CloudEnv, w as CloudRepo, x as CompatSource, y as CompatSourceAdapter, z as CompatSurface, D as CreateSkillSpec, H as HookApprovalGate, E as HookApprovalRequest, F as HookName, J as LlmCallContext, K as MemoryProviderAgentRef, N as MemoryProviderFactory, O as MemoryProviderHandle, Q as MemoryProviderInitOptions, R as PluginContext, T as PluginHookDisposer, U as PostAssistantReplyContext, V as PostToolCallContext, W as PreToolCallContext, X as PreUserSendContext, Y as PreUserSendResult, Z as ProviderTransform, _ as ProviderTransformContext, $ as RecordSessionSummaryArgs, a0 as SessionLifecycleContext, a1 as SettingSource, a2 as Skill, a3 as SkillsResolver, a4 as SkillsResolverContext, a5 as SystemPromptContext, a6 as SystemPromptMemoryFact, a7 as TelemetrySettings, a8 as ToolCallSummary, a9 as ToolContext, aa as ToolResultTransformContext, ab as TransformContext } from './agent-BL4kxgwq.cjs';
|
|
5
5
|
import { ad as RunEvent, v as CostBreakdown, b0 as TokenUsage, R as RunResult, P as ProviderRoutingSettings, S as SDKAgent, M as McpServerConfig, C as ContextSettings, a as PluginsSettings, b as Run, c as Processor, J as JudgeResult, G as GoalOptions, d as GoalEvent, e as GoalResult, f as MemoryId, g as RunEventSink$1, h as SDKProvider, i as SDKMessage } from './sdk-agent-BA_6_wtc.cjs';
|
|
6
6
|
export { A as AgentConversationTurn, j as AgentMemory, k as AgentOperation, l as AssistantMessage, m as CompletionCheck, n as CompletionCheckResult, o as ContextBudget, p as ContextManagerKind, q as ContextSnapshot, r as ContextSource, s as ContextSourceStatus, t as ConversationStep, u as ConversationTurn, v as CostBreakdown, w as CostSource, x as CostStatus, D as DoomLoopThresholds, E as EnvPolicy, F as ForkOptions, y as ForkResult, z as GenerateOptions, B as GenerateRunResult, I as InputProcessorContext, H as InteractionUpdate, K as InvalidateCacheOptions, L as McpAuthConfig, N as McpHttpServerConfig, O as McpOAuthConfig, Q as McpStdioServerConfig, T as MemoryAdapter, U as MemoryAdapterCapabilities, V as MemoryContext, W as MemoryFact, X as MemoryRevision, Y as MemoryToolSchema, Z as MemoryTurnMessage, _ as MessageOrigin, $ as OutputProcessorContext, a0 as PartialToolCallUpdate, a1 as PersonalityPreset, a2 as ProcessorControls, a3 as ProcessorTripwire, a4 as ProcessorViolation, a5 as ProviderCapability, a6 as ProviderRoute, a7 as PruneToolResultsOptions, a8 as QueueMode, a9 as ResolvedProviderRoute, aa as RunCompactBoundaryEvent, ab as RunCompletionCheckEvent, ac as RunErrorDetail, ad as RunEvent, ae as RunGitInfo, af as RunMemoryDegradedEvent, ag as RunPermissionDeniedEvent, ah as RunRateLimitEvent, ai as RunStatus, aj as RunTaskCompletedEvent, ak as RunTaskStartedEvent, al as RunTaskUpdatedEvent, am as RunTimelineEvent, an as RunToCompletionOptions, ao as RunToCompletionResult, ap as RunToolProgressEvent, aq as RunTripwireEvent, ar as RunUntilIterator, as as SDKAgentPlugins, at as SDKAgentSkillDetail, au as SDKAgentSkills, av as SDKArtifact, aw as SDKAssistantMessage, ax as SDKContextManager, ay as SDKImage, az as SDKImageDimension, aA as SDKObjectDelta, aB as SDKPluginMetadata, aC as SDKProvidersManager, aD as SDKRequestMessage, aE as SDKStatusMessage, aF as SDKSystemMessage, aG as SDKTaskMessage, aH as SDKThinkingMessage, aI as SDKToolUseMessage, aJ as SDKUserMessage, aK as SDKUserMessageEvent, aL as SendOptions, aM as ShellCommand, aN as ShellConversationTurn, aO as ShellOutput, aP as ShellOutputDeltaUpdate, aQ as StepCompletedUpdate, aR as StepStartedUpdate, aS as StreamToCompletionResult, aT as SummaryCompletedUpdate, aU as SummaryStartedUpdate, aV as SummaryUpdate, aW as SystemPromptSkillRef, aX as TextDeltaUpdate, aY as ThinkingCompletedUpdate, aZ as ThinkingDeltaUpdate, a_ as ThinkingMessage, a$ as TokenDeltaUpdate, b0 as TokenUsage, b1 as ToolCall, b2 as ToolCallCompletedUpdate, b3 as ToolCallStartedUpdate, b4 as ToolResult, b5 as ToolResultGuardOptions, b6 as ToolUseBlock, b7 as TurnEndedUpdate, b8 as UserMessage, b9 as UserMessageAppendedUpdate, ba as Verdict } from './sdk-agent-BA_6_wtc.cjs';
|
|
7
7
|
import * as zod from 'zod';
|
|
@@ -10,7 +10,7 @@ import { S as StructuredOutputError, B as BudgetOptions, a as BudgetHandle, b as
|
|
|
10
10
|
export { A as AgentDisposedError, c as AgentRunError, d as AgentRunErrorCode, e as AuthenticationError, f as BudgetExceedEvent, g as BudgetExceededError, h as BudgetLimit, i as BudgetMode, j as BudgetScope, k as BudgetThresholdEvent, l as BudgetWindow, C as ConfigurationError, I as IntegrationNotConnectedError, m as InvalidTaskIdError, M as MemoryAdapterError, n as MemoryAdapterErrorCode, N as NetworkError, R as RateLimitError, T as TaskNotFoundError, U as UnknownAgentError, o as UnsupportedBudgetOperationError, p as UnsupportedRunOperationError, q as UnsupportedTaskOperationError, r as isTransientError } from './errors-BiDQFWTG.cjs';
|
|
11
11
|
import { M as ModelSelection, C as CustomTool, T as ToolResultContentBlock, P as PermissionMode } from './agent-prims-CZyxfCmS.cjs';
|
|
12
12
|
export { I as ImageBlock, a as ModelParameterValue, R as RunOperation, b as TextBlock, c as ToolContextMessage } from './agent-prims-CZyxfCmS.cjs';
|
|
13
|
-
export { C as Cron, a as CronCreateOptions, b as CronGetOptions, c as CronJob, d as CronJobStatus, e as CronListOptions, f as CronOperationOptions, g as CronRunOptions, h as CronRuntime, i as CronSchedulerStatus, j as CronStartOptions } from './cron-
|
|
13
|
+
export { C as Cron, a as CronCreateOptions, b as CronGetOptions, c as CronJob, d as CronJobStatus, e as CronListOptions, f as CronOperationOptions, g as CronRunOptions, h as CronRuntime, i as CronSchedulerStatus, j as CronStartOptions } from './cron-B7KH9sHW.cjs';
|
|
14
14
|
export { S as SqliteSessionStore, a as SqliteSessionStoreOptions, w as withCwdMutex } from './sqlite-session-store-TKXtT4ON.cjs';
|
|
15
15
|
import { StepResult } from './workflow.cjs';
|
|
16
16
|
export { Workflow, agentStep, fn } from './workflow.cjs';
|
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { T as TheokitAgentError, E as ErrorMetadata } from './errors-base-B5g01neU.js';
|
|
2
2
|
export { a as ErrorCode } from './errors-base-B5g01neU.js';
|
|
3
|
-
import { A as AgentOptions, L as LocalOptions, B as BuiltinToolName, M as MemorySettings, S as SystemPromptResolver, C as CloudOptions, a as AgentDefinition, b as SkillsSettings, c as ListAgentsOptions, d as ListResult, e as SDKAgentInfo, G as GetAgentOptions, f as ListRunsOptions, g as GetRunOptions, h as AgentOperationOptions, i as AgentDescription, P as Plugin$1, j as ProviderProfile, I as InlineSkill, k as Skill, l as BudgetTracker, m as MemoryProvider, n as PreToolCallDecision } from './agent-
|
|
4
|
-
export { o as ActiveMemoryPassArgs, p as ActiveMemoryPassResult, q as AgentSubagentDescription, r as AgentToolDescription, s as BudgetCheck, t as BudgetTotal, u as BudgetUsageEvent, v as CloudEnv, w as CloudRepo, x as CompatSource, y as CompatSourceAdapter, z as CompatSurface, D as CreateSkillSpec, H as HookApprovalGate, E as HookApprovalRequest, F as HookName, J as LlmCallContext, K as MemoryProviderAgentRef, N as MemoryProviderFactory, O as MemoryProviderHandle, Q as MemoryProviderInitOptions, R as PluginContext, T as PluginHookDisposer, U as PostAssistantReplyContext, V as PostToolCallContext, W as PreToolCallContext, X as PreUserSendContext, Y as PreUserSendResult, Z as ProviderTransform, _ as ProviderTransformContext, $ as RecordSessionSummaryArgs, a0 as SessionLifecycleContext, a1 as SettingSource, a2 as Skill, a3 as SkillsResolver, a4 as SkillsResolverContext, a5 as SystemPromptContext, a6 as SystemPromptMemoryFact, a7 as TelemetrySettings, a8 as ToolCallSummary, a9 as ToolContext, aa as ToolResultTransformContext, ab as TransformContext } from './agent-
|
|
3
|
+
import { A as AgentOptions, L as LocalOptions, B as BuiltinToolName, M as MemorySettings, S as SystemPromptResolver, C as CloudOptions, a as AgentDefinition, b as SkillsSettings, c as ListAgentsOptions, d as ListResult, e as SDKAgentInfo, G as GetAgentOptions, f as ListRunsOptions, g as GetRunOptions, h as AgentOperationOptions, i as AgentDescription, P as Plugin$1, j as ProviderProfile, I as InlineSkill, k as Skill, l as BudgetTracker, m as MemoryProvider, n as PreToolCallDecision } from './agent-ByDx7K30.js';
|
|
4
|
+
export { o as ActiveMemoryPassArgs, p as ActiveMemoryPassResult, q as AgentSubagentDescription, r as AgentToolDescription, s as BudgetCheck, t as BudgetTotal, u as BudgetUsageEvent, v as CloudEnv, w as CloudRepo, x as CompatSource, y as CompatSourceAdapter, z as CompatSurface, D as CreateSkillSpec, H as HookApprovalGate, E as HookApprovalRequest, F as HookName, J as LlmCallContext, K as MemoryProviderAgentRef, N as MemoryProviderFactory, O as MemoryProviderHandle, Q as MemoryProviderInitOptions, R as PluginContext, T as PluginHookDisposer, U as PostAssistantReplyContext, V as PostToolCallContext, W as PreToolCallContext, X as PreUserSendContext, Y as PreUserSendResult, Z as ProviderTransform, _ as ProviderTransformContext, $ as RecordSessionSummaryArgs, a0 as SessionLifecycleContext, a1 as SettingSource, a2 as Skill, a3 as SkillsResolver, a4 as SkillsResolverContext, a5 as SystemPromptContext, a6 as SystemPromptMemoryFact, a7 as TelemetrySettings, a8 as ToolCallSummary, a9 as ToolContext, aa as ToolResultTransformContext, ab as TransformContext } from './agent-ByDx7K30.js';
|
|
5
5
|
import { ad as RunEvent, v as CostBreakdown, b0 as TokenUsage, R as RunResult, P as ProviderRoutingSettings, S as SDKAgent, M as McpServerConfig, C as ContextSettings, a as PluginsSettings, b as Run, c as Processor, J as JudgeResult, G as GoalOptions, d as GoalEvent, e as GoalResult, f as MemoryId, g as RunEventSink$1, h as SDKProvider, i as SDKMessage } from './sdk-agent-CnwPODYH.js';
|
|
6
6
|
export { A as AgentConversationTurn, j as AgentMemory, k as AgentOperation, l as AssistantMessage, m as CompletionCheck, n as CompletionCheckResult, o as ContextBudget, p as ContextManagerKind, q as ContextSnapshot, r as ContextSource, s as ContextSourceStatus, t as ConversationStep, u as ConversationTurn, v as CostBreakdown, w as CostSource, x as CostStatus, D as DoomLoopThresholds, E as EnvPolicy, F as ForkOptions, y as ForkResult, z as GenerateOptions, B as GenerateRunResult, I as InputProcessorContext, H as InteractionUpdate, K as InvalidateCacheOptions, L as McpAuthConfig, N as McpHttpServerConfig, O as McpOAuthConfig, Q as McpStdioServerConfig, T as MemoryAdapter, U as MemoryAdapterCapabilities, V as MemoryContext, W as MemoryFact, X as MemoryRevision, Y as MemoryToolSchema, Z as MemoryTurnMessage, _ as MessageOrigin, $ as OutputProcessorContext, a0 as PartialToolCallUpdate, a1 as PersonalityPreset, a2 as ProcessorControls, a3 as ProcessorTripwire, a4 as ProcessorViolation, a5 as ProviderCapability, a6 as ProviderRoute, a7 as PruneToolResultsOptions, a8 as QueueMode, a9 as ResolvedProviderRoute, aa as RunCompactBoundaryEvent, ab as RunCompletionCheckEvent, ac as RunErrorDetail, ad as RunEvent, ae as RunGitInfo, af as RunMemoryDegradedEvent, ag as RunPermissionDeniedEvent, ah as RunRateLimitEvent, ai as RunStatus, aj as RunTaskCompletedEvent, ak as RunTaskStartedEvent, al as RunTaskUpdatedEvent, am as RunTimelineEvent, an as RunToCompletionOptions, ao as RunToCompletionResult, ap as RunToolProgressEvent, aq as RunTripwireEvent, ar as RunUntilIterator, as as SDKAgentPlugins, at as SDKAgentSkillDetail, au as SDKAgentSkills, av as SDKArtifact, aw as SDKAssistantMessage, ax as SDKContextManager, ay as SDKImage, az as SDKImageDimension, aA as SDKObjectDelta, aB as SDKPluginMetadata, aC as SDKProvidersManager, aD as SDKRequestMessage, aE as SDKStatusMessage, aF as SDKSystemMessage, aG as SDKTaskMessage, aH as SDKThinkingMessage, aI as SDKToolUseMessage, aJ as SDKUserMessage, aK as SDKUserMessageEvent, aL as SendOptions, aM as ShellCommand, aN as ShellConversationTurn, aO as ShellOutput, aP as ShellOutputDeltaUpdate, aQ as StepCompletedUpdate, aR as StepStartedUpdate, aS as StreamToCompletionResult, aT as SummaryCompletedUpdate, aU as SummaryStartedUpdate, aV as SummaryUpdate, aW as SystemPromptSkillRef, aX as TextDeltaUpdate, aY as ThinkingCompletedUpdate, aZ as ThinkingDeltaUpdate, a_ as ThinkingMessage, a$ as TokenDeltaUpdate, b0 as TokenUsage, b1 as ToolCall, b2 as ToolCallCompletedUpdate, b3 as ToolCallStartedUpdate, b4 as ToolResult, b5 as ToolResultGuardOptions, b6 as ToolUseBlock, b7 as TurnEndedUpdate, b8 as UserMessage, b9 as UserMessageAppendedUpdate, ba as Verdict } from './sdk-agent-CnwPODYH.js';
|
|
7
7
|
import * as zod from 'zod';
|
|
@@ -10,7 +10,7 @@ import { S as StructuredOutputError, B as BudgetOptions, a as BudgetHandle, b as
|
|
|
10
10
|
export { A as AgentDisposedError, c as AgentRunError, d as AgentRunErrorCode, e as AuthenticationError, f as BudgetExceedEvent, g as BudgetExceededError, h as BudgetLimit, i as BudgetMode, j as BudgetScope, k as BudgetThresholdEvent, l as BudgetWindow, C as ConfigurationError, I as IntegrationNotConnectedError, m as InvalidTaskIdError, M as MemoryAdapterError, n as MemoryAdapterErrorCode, N as NetworkError, R as RateLimitError, T as TaskNotFoundError, U as UnknownAgentError, o as UnsupportedBudgetOperationError, p as UnsupportedRunOperationError, q as UnsupportedTaskOperationError, r as isTransientError } from './errors-Pf22PJJ-.js';
|
|
11
11
|
import { M as ModelSelection, C as CustomTool, T as ToolResultContentBlock, P as PermissionMode } from './agent-prims-CZyxfCmS.js';
|
|
12
12
|
export { I as ImageBlock, a as ModelParameterValue, R as RunOperation, b as TextBlock, c as ToolContextMessage } from './agent-prims-CZyxfCmS.js';
|
|
13
|
-
export { C as Cron, a as CronCreateOptions, b as CronGetOptions, c as CronJob, d as CronJobStatus, e as CronListOptions, f as CronOperationOptions, g as CronRunOptions, h as CronRuntime, i as CronSchedulerStatus, j as CronStartOptions } from './cron-
|
|
13
|
+
export { C as Cron, a as CronCreateOptions, b as CronGetOptions, c as CronJob, d as CronJobStatus, e as CronListOptions, f as CronOperationOptions, g as CronRunOptions, h as CronRuntime, i as CronSchedulerStatus, j as CronStartOptions } from './cron-FEO7UAQF.js';
|
|
14
14
|
export { S as SqliteSessionStore, a as SqliteSessionStoreOptions, w as withCwdMutex } from './sqlite-session-store-BbcpKY1L.js';
|
|
15
15
|
import { StepResult } from './workflow.js';
|
|
16
16
|
export { Workflow, agentStep, fn } from './workflow.js';
|
package/dist/index.js
CHANGED
|
@@ -9,12 +9,12 @@ export { Workflow, agentStep, fn } from './chunk-73IITAF7.js';
|
|
|
9
9
|
import './chunk-TDED5XES.js';
|
|
10
10
|
export { SqliteSessionStore } from './chunk-BPL5CVZ5.js';
|
|
11
11
|
import './chunk-HY66GLM6.js';
|
|
12
|
-
export { Cron } from './chunk-
|
|
13
|
-
import { MEMORY_EMBEDDING_ADAPTERS, resolveSessionDir, DEFAULT_AGENTIC_MODEL_ID, Agent } from './chunk-
|
|
14
|
-
export { Agent, AgentBuilder, Tool, ToolError, UsageAccumulator, computeCost, getPricingEntry, managedSettingsPathFor, readManagedSettings } from './chunk-
|
|
12
|
+
export { Cron } from './chunk-O2RCS3SJ.js';
|
|
13
|
+
import { MEMORY_EMBEDDING_ADAPTERS, resolveSessionDir, DEFAULT_AGENTIC_MODEL_ID, Agent } from './chunk-ZQWRUJHE.js';
|
|
14
|
+
export { Agent, AgentBuilder, Tool, ToolError, UsageAccumulator, computeCost, getPricingEntry, managedSettingsPathFor, readManagedSettings } from './chunk-ZQWRUJHE.js';
|
|
15
15
|
import { configure, submit, list, get, cancel, subscribe } from './chunk-HWMGR3HA.js';
|
|
16
16
|
export { emitRunEvent } from './chunk-HWMGR3HA.js';
|
|
17
|
-
import './chunk-
|
|
17
|
+
import './chunk-VNRNZ3WI.js';
|
|
18
18
|
import './chunk-K2BQQ445.js';
|
|
19
19
|
import './chunk-3BBTHFGJ.js';
|
|
20
20
|
import './chunk-HJ2LV464.js';
|
|
@@ -24,8 +24,8 @@ import './chunk-H73MEMQB.js';
|
|
|
24
24
|
import './chunk-QK2ERTO3.js';
|
|
25
25
|
import { resolveMemoryRoot } from './chunk-LCCT5ZXJ.js';
|
|
26
26
|
import { FsSessionStore } from './chunk-RGVMJU57.js';
|
|
27
|
-
import { discoverProviderPlugins, shouldUseFixtureMode, isFixtureApiKey, httpRequest, mapOllamaTransportError, readErrorResponseBody, mapOllamaHttpError } from './chunk-
|
|
28
|
-
export { inferApiMode, normalizeUsage } from './chunk-
|
|
27
|
+
import { discoverProviderPlugins, shouldUseFixtureMode, isFixtureApiKey, httpRequest, mapOllamaTransportError, readErrorResponseBody, mapOllamaHttpError } from './chunk-26GI3OYA.js';
|
|
28
|
+
export { inferApiMode, normalizeUsage } from './chunk-26GI3OYA.js';
|
|
29
29
|
import './chunk-NK5EOTDY.js';
|
|
30
30
|
import './chunk-2XC6KDJM.js';
|
|
31
31
|
import './chunk-7ACS6P5Z.js';
|
|
@@ -1745,7 +1745,7 @@ function isBuiltAgent(m) {
|
|
|
1745
1745
|
return typeof m.send === "function";
|
|
1746
1746
|
}
|
|
1747
1747
|
async function materialize(def, index) {
|
|
1748
|
-
const { Agent: Agent2 } = await import('./agent-
|
|
1748
|
+
const { Agent: Agent2 } = await import('./agent-66U5QCPF.js');
|
|
1749
1749
|
return Agent2.create({
|
|
1750
1750
|
// `AgentDefinition.model` admits the sentinel `'inherit'`, which is not a model id. Inheriting
|
|
1751
1751
|
// here means "declare nothing and let the default apply" — forwarding the literal would create
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { enqueueSessionWrite } from './chunk-
|
|
1
|
+
import { enqueueSessionWrite } from './chunk-VNRNZ3WI.js';
|
|
2
2
|
import { invalidateSessionCache } from './chunk-2XC6KDJM.js';
|
|
3
3
|
import './chunk-AGO5S5WD.js';
|
|
4
4
|
import { SessionTranscript } from './chunk-XESYJ4JC.js';
|
|
@@ -23,5 +23,5 @@ async function injectSessionTurn(opts) {
|
|
|
23
23
|
}
|
|
24
24
|
|
|
25
25
|
export { injectSessionTurn };
|
|
26
|
-
//# sourceMappingURL=inject-session-
|
|
27
|
-
//# sourceMappingURL=inject-session-
|
|
26
|
+
//# sourceMappingURL=inject-session-LC2TROHM.js.map
|
|
27
|
+
//# sourceMappingURL=inject-session-LC2TROHM.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/internal/session/inject-session.ts"],"names":[],"mappings":";;;;;;;;;AAWA,eAAsB,kBAAkB,IAAA,EAMtB;AAChB,EAAA,MAAM,oBAAoB,IAAA,CAAK,GAAA,CAAI,KAAK,IAAA,CAAK,GAAA,CAAI,SAAS,YAAY;AACpE,IAAA,MAAM,QAAQ,MAAM,IAAA,CAAK,MAAM,WAAA,CAAY,IAAA,CAAK,IAAI,OAAO,CAAA;AAC3D,IAAA,MAAM,UAAA,GAAa,iBAAA,CAAkB,WAAA,CAAY,KAAA,EAAO;AAAA,MACtD,GAAA,EAAK,KAAK,GAAA,CAAI,GAAA;AAAA,MACd,WAAW,IAAA,CAAK,SAAA;AAAA,MAChB,KAAA,EAAO,IAAA,CAAK,GAAA,CAAI,KAAA,IAAS;AAAA,KAC1B,CAAA;AACD,IAAA,UAAA,CAAW,cAAA,CAAe,KAAK,QAAQ,CAAA;AACvC,IAAA,UAAA,CAAW,mBAAA,CAAoB,EAAE,IAAA,EAAM,IAAA,CAAK,eAAe,CAAA;AAC3D,IAAA,MAAM,IAAA,CAAK,KAAA,CAAM,aAAA,CAAc,IAAA,CAAK,GAAA,CAAI,OAAA,EAAS,UAAA,CAAW,OAAA,EAAQ,CAAE,KAAA,CAAM,KAAA,CAAM,MAAM,CAAC,CAAA;AACzF,IAAA,sBAAA,CAAuB,IAAA,CAAK,GAAA,CAAI,GAAA,EAAK,IAAA,CAAK,IAAI,OAAO,CAAA;AAAA,EACvD,CAAC,CAAA;AACH","file":"inject-session-
|
|
1
|
+
{"version":3,"sources":["../src/internal/session/inject-session.ts"],"names":[],"mappings":";;;;;;;;;AAWA,eAAsB,kBAAkB,IAAA,EAMtB;AAChB,EAAA,MAAM,oBAAoB,IAAA,CAAK,GAAA,CAAI,KAAK,IAAA,CAAK,GAAA,CAAI,SAAS,YAAY;AACpE,IAAA,MAAM,QAAQ,MAAM,IAAA,CAAK,MAAM,WAAA,CAAY,IAAA,CAAK,IAAI,OAAO,CAAA;AAC3D,IAAA,MAAM,UAAA,GAAa,iBAAA,CAAkB,WAAA,CAAY,KAAA,EAAO;AAAA,MACtD,GAAA,EAAK,KAAK,GAAA,CAAI,GAAA;AAAA,MACd,WAAW,IAAA,CAAK,SAAA;AAAA,MAChB,KAAA,EAAO,IAAA,CAAK,GAAA,CAAI,KAAA,IAAS;AAAA,KAC1B,CAAA;AACD,IAAA,UAAA,CAAW,cAAA,CAAe,KAAK,QAAQ,CAAA;AACvC,IAAA,UAAA,CAAW,mBAAA,CAAoB,EAAE,IAAA,EAAM,IAAA,CAAK,eAAe,CAAA;AAC3D,IAAA,MAAM,IAAA,CAAK,KAAA,CAAM,aAAA,CAAc,IAAA,CAAK,GAAA,CAAI,OAAA,EAAS,UAAA,CAAW,OAAA,EAAQ,CAAE,KAAA,CAAM,KAAA,CAAM,MAAM,CAAC,CAAA;AACzF,IAAA,sBAAA,CAAuB,IAAA,CAAK,GAAA,CAAI,GAAA,EAAK,IAAA,CAAK,IAAI,OAAO,CAAA;AAAA,EACvD,CAAC,CAAA;AACH","file":"inject-session-LC2TROHM.js","sourcesContent":["/**\n * M51 (agent-builder) — inject a SYNTHETIC user+assistant pair into a session's persisted transcript\n * WITHOUT running an LLM turn. This is the Codex review-exit mechanism (`exit_success.xml` appended to\n * the parent thread history so follow-ups like \"fix finding 2\" work): the pair chains onto the DAG\n * leaf (M50 pattern) and the in-memory cache is invalidated so the NEXT send re-hydrates with it.\n */\nimport type { SessionStore } from \"../../types/session-store.js\";\nimport { SessionTranscript } from \"../persistence/session-transcript.js\";\nimport { enqueueSessionWrite, invalidateSessionCache } from \"./agent-session.js\";\nimport type { CompactLocation } from \"./compact-session.js\";\n\nexport async function injectSessionTurn(opts: {\n store: SessionStore;\n loc: CompactLocation;\n sessionId: string;\n userText: string;\n assistantText: string;\n}): Promise<void> {\n await enqueueSessionWrite(opts.loc.cwd, opts.loc.agentId, async () => {\n const prior = await opts.store.readRecords(opts.loc.agentId);\n const transcript = SessionTranscript.fromRecords(prior, {\n cwd: opts.loc.cwd,\n sessionId: opts.sessionId,\n model: opts.loc.model ?? \"unknown\",\n });\n transcript.appendUserTurn(opts.userText);\n transcript.appendAssistantTurn({ text: opts.assistantText });\n await opts.store.appendRecords(opts.loc.agentId, transcript.records().slice(prior.length));\n invalidateSessionCache(opts.loc.cwd, opts.loc.agentId);\n });\n}\n"]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkFBIDOOJM_cjs = require('./chunk-FBIDOOJM.cjs');
|
|
4
4
|
var chunkYJNYDJ2T_cjs = require('./chunk-YJNYDJ2T.cjs');
|
|
5
5
|
require('./chunk-MSW7LB2V.cjs');
|
|
6
6
|
var chunk3WKWBYPO_cjs = require('./chunk-3WKWBYPO.cjs');
|
|
@@ -10,7 +10,7 @@ require('./chunk-RNXXYF22.cjs');
|
|
|
10
10
|
|
|
11
11
|
// src/internal/session/inject-session.ts
|
|
12
12
|
async function injectSessionTurn(opts) {
|
|
13
|
-
await
|
|
13
|
+
await chunkFBIDOOJM_cjs.enqueueSessionWrite(opts.loc.cwd, opts.loc.agentId, async () => {
|
|
14
14
|
const prior = await opts.store.readRecords(opts.loc.agentId);
|
|
15
15
|
const transcript = chunk3WKWBYPO_cjs.SessionTranscript.fromRecords(prior, {
|
|
16
16
|
cwd: opts.loc.cwd,
|
|
@@ -25,5 +25,5 @@ async function injectSessionTurn(opts) {
|
|
|
25
25
|
}
|
|
26
26
|
|
|
27
27
|
exports.injectSessionTurn = injectSessionTurn;
|
|
28
|
-
//# sourceMappingURL=inject-session-
|
|
29
|
-
//# sourceMappingURL=inject-session-
|
|
28
|
+
//# sourceMappingURL=inject-session-T4RXANG3.cjs.map
|
|
29
|
+
//# sourceMappingURL=inject-session-T4RXANG3.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/internal/session/inject-session.ts"],"names":["enqueueSessionWrite","SessionTranscript","invalidateSessionCache"],"mappings":";;;;;;;;;;;AAWA,eAAsB,kBAAkB,IAAA,EAMtB;AAChB,EAAA,MAAMA,sCAAoB,IAAA,CAAK,GAAA,CAAI,KAAK,IAAA,CAAK,GAAA,CAAI,SAAS,YAAY;AACpE,IAAA,MAAM,QAAQ,MAAM,IAAA,CAAK,MAAM,WAAA,CAAY,IAAA,CAAK,IAAI,OAAO,CAAA;AAC3D,IAAA,MAAM,UAAA,GAAaC,mCAAA,CAAkB,WAAA,CAAY,KAAA,EAAO;AAAA,MACtD,GAAA,EAAK,KAAK,GAAA,CAAI,GAAA;AAAA,MACd,WAAW,IAAA,CAAK,SAAA;AAAA,MAChB,KAAA,EAAO,IAAA,CAAK,GAAA,CAAI,KAAA,IAAS;AAAA,KAC1B,CAAA;AACD,IAAA,UAAA,CAAW,cAAA,CAAe,KAAK,QAAQ,CAAA;AACvC,IAAA,UAAA,CAAW,mBAAA,CAAoB,EAAE,IAAA,EAAM,IAAA,CAAK,eAAe,CAAA;AAC3D,IAAA,MAAM,IAAA,CAAK,KAAA,CAAM,aAAA,CAAc,IAAA,CAAK,GAAA,CAAI,OAAA,EAAS,UAAA,CAAW,OAAA,EAAQ,CAAE,KAAA,CAAM,KAAA,CAAM,MAAM,CAAC,CAAA;AACzF,IAAAC,wCAAA,CAAuB,IAAA,CAAK,GAAA,CAAI,GAAA,EAAK,IAAA,CAAK,IAAI,OAAO,CAAA;AAAA,EACvD,CAAC,CAAA;AACH","file":"inject-session-
|
|
1
|
+
{"version":3,"sources":["../src/internal/session/inject-session.ts"],"names":["enqueueSessionWrite","SessionTranscript","invalidateSessionCache"],"mappings":";;;;;;;;;;;AAWA,eAAsB,kBAAkB,IAAA,EAMtB;AAChB,EAAA,MAAMA,sCAAoB,IAAA,CAAK,GAAA,CAAI,KAAK,IAAA,CAAK,GAAA,CAAI,SAAS,YAAY;AACpE,IAAA,MAAM,QAAQ,MAAM,IAAA,CAAK,MAAM,WAAA,CAAY,IAAA,CAAK,IAAI,OAAO,CAAA;AAC3D,IAAA,MAAM,UAAA,GAAaC,mCAAA,CAAkB,WAAA,CAAY,KAAA,EAAO;AAAA,MACtD,GAAA,EAAK,KAAK,GAAA,CAAI,GAAA;AAAA,MACd,WAAW,IAAA,CAAK,SAAA;AAAA,MAChB,KAAA,EAAO,IAAA,CAAK,GAAA,CAAI,KAAA,IAAS;AAAA,KAC1B,CAAA;AACD,IAAA,UAAA,CAAW,cAAA,CAAe,KAAK,QAAQ,CAAA;AACvC,IAAA,UAAA,CAAW,mBAAA,CAAoB,EAAE,IAAA,EAAM,IAAA,CAAK,eAAe,CAAA;AAC3D,IAAA,MAAM,IAAA,CAAK,KAAA,CAAM,aAAA,CAAc,IAAA,CAAK,GAAA,CAAI,OAAA,EAAS,UAAA,CAAW,OAAA,EAAQ,CAAE,KAAA,CAAM,KAAA,CAAM,MAAM,CAAC,CAAA;AACzF,IAAAC,wCAAA,CAAuB,IAAA,CAAK,GAAA,CAAI,GAAA,EAAK,IAAA,CAAK,IAAI,OAAO,CAAA;AAAA,EACvD,CAAC,CAAA;AACH","file":"inject-session-T4RXANG3.cjs","sourcesContent":["/**\n * M51 (agent-builder) — inject a SYNTHETIC user+assistant pair into a session's persisted transcript\n * WITHOUT running an LLM turn. This is the Codex review-exit mechanism (`exit_success.xml` appended to\n * the parent thread history so follow-ups like \"fix finding 2\" work): the pair chains onto the DAG\n * leaf (M50 pattern) and the in-memory cache is invalidated so the NEXT send re-hydrates with it.\n */\nimport type { SessionStore } from \"../../types/session-store.js\";\nimport { SessionTranscript } from \"../persistence/session-transcript.js\";\nimport { enqueueSessionWrite, invalidateSessionCache } from \"./agent-session.js\";\nimport type { CompactLocation } from \"./compact-session.js\";\n\nexport async function injectSessionTurn(opts: {\n store: SessionStore;\n loc: CompactLocation;\n sessionId: string;\n userText: string;\n assistantText: string;\n}): Promise<void> {\n await enqueueSessionWrite(opts.loc.cwd, opts.loc.agentId, async () => {\n const prior = await opts.store.readRecords(opts.loc.agentId);\n const transcript = SessionTranscript.fromRecords(prior, {\n cwd: opts.loc.cwd,\n sessionId: opts.sessionId,\n model: opts.loc.model ?? \"unknown\",\n });\n transcript.appendUserTurn(opts.userText);\n transcript.appendAssistantTurn({ text: opts.assistantText });\n await opts.store.appendRecords(opts.loc.agentId, transcript.records().slice(prior.length));\n invalidateSessionCache(opts.loc.cwd, opts.loc.agentId);\n });\n}\n"]}
|
|
@@ -8,4 +8,6 @@ export interface HermesExtractResult {
|
|
|
8
8
|
* block whose name is not a tool in the current request. Empty when no allowlist was applied or
|
|
9
9
|
* nothing was gated out. The caller logs these so a guard firing is observable in production. */
|
|
10
10
|
droppedNames: string[];
|
|
11
|
+
/** Names of the leaked-call formats recovered (e.g. `gemini-ctrl42`); empty when none. */
|
|
12
|
+
formats: string[];
|
|
11
13
|
}
|