@stigmer/runner 3.31.0 → 3.33.0
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/.build-fingerprint +1 -1
- package/dist/activities/execute-deep-agent/cas-capture-backend.d.ts +13 -6
- package/dist/activities/execute-deep-agent/cas-capture-backend.js +21 -5
- package/dist/activities/execute-deep-agent/cas-capture-backend.js.map +1 -1
- package/dist/activities/execute-deep-agent/deepagents-profiles.d.ts +21 -7
- package/dist/activities/execute-deep-agent/deepagents-profiles.js +24 -9
- package/dist/activities/execute-deep-agent/deepagents-profiles.js.map +1 -1
- package/dist/activities/execute-deep-agent/platform-route.d.ts +75 -0
- package/dist/activities/execute-deep-agent/platform-route.js +107 -0
- package/dist/activities/execute-deep-agent/platform-route.js.map +1 -0
- package/dist/activities/execute-deep-agent/subagent-transformer.d.ts +2 -0
- package/dist/activities/execute-deep-agent/subagent-transformer.js +29 -5
- package/dist/activities/execute-deep-agent/subagent-transformer.js.map +1 -1
- package/dist/activities/execute-deep-agent/subagent-wiring.d.ts +5 -7
- package/dist/activities/execute-deep-agent/subagent-wiring.js +5 -7
- package/dist/activities/execute-deep-agent/subagent-wiring.js.map +1 -1
- package/dist/activities/execute-deep-agent/translator.d.ts +6 -2
- package/dist/activities/execute-deep-agent/translator.js +6 -2
- package/dist/activities/execute-deep-agent/translator.js.map +1 -1
- package/dist/activities/execute-deep-agent/turn-setup.js +14 -3
- package/dist/activities/execute-deep-agent/turn-setup.js.map +1 -1
- package/dist/middleware/index.d.ts +7 -3
- package/dist/middleware/index.js +7 -3
- package/dist/middleware/index.js.map +1 -1
- package/dist/shared/workspace/stigmer-link.d.ts +15 -3
- package/dist/shared/workspace/stigmer-link.js +22 -3
- package/dist/shared/workspace/stigmer-link.js.map +1 -1
- package/dist/shared/workspace/types.d.ts +4 -3
- package/package.json +15 -9
- package/src/activities/execute-deep-agent/__tests__/builtin-tool-surface.test.ts +107 -0
- package/src/activities/execute-deep-agent/__tests__/cas-capture-backend.test.ts +14 -0
- package/src/activities/execute-deep-agent/__tests__/hermetic/fixtures/paused-session.deepagents-1.10.2.json +592 -0
- package/src/activities/execute-deep-agent/__tests__/hermetic/goldens/sub-agent-delegation.status.json +2 -2
- package/src/activities/execute-deep-agent/__tests__/hermetic/goldens/tool-call.status.json +1 -1
- package/src/activities/execute-deep-agent/__tests__/hermetic/plain-turn.test.ts +10 -13
- package/src/activities/execute-deep-agent/__tests__/hermetic/resume-across-engine-upgrade.test.ts +374 -0
- package/src/activities/execute-deep-agent/__tests__/hermetic/sub-agent-delegation.test.ts +7 -0
- package/src/activities/execute-deep-agent/__tests__/hermetic/tool-call.test.ts +6 -0
- package/src/activities/execute-deep-agent/__tests__/plan-mode-path-normalization.test.ts +16 -8
- package/src/activities/execute-deep-agent/__tests__/platform-route.test.ts +148 -0
- package/src/activities/execute-deep-agent/__tests__/subagent-transformer.test.ts +24 -0
- package/src/activities/execute-deep-agent/__tests__/summarization-verification.test.ts +16 -9
- package/src/activities/execute-deep-agent/cas-capture-backend.ts +25 -6
- package/src/activities/execute-deep-agent/deepagents-profiles.ts +25 -9
- package/src/activities/execute-deep-agent/platform-route.ts +134 -0
- package/src/activities/execute-deep-agent/subagent-transformer.ts +40 -6
- package/src/activities/execute-deep-agent/subagent-wiring.ts +5 -7
- package/src/activities/execute-deep-agent/translator.ts +6 -2
- package/src/activities/execute-deep-agent/turn-setup.ts +17 -3
- package/src/middleware/index.ts +7 -3
- package/src/shared/workspace/__tests__/stigmer-link.test.ts +41 -18
- package/src/shared/workspace/stigmer-link.ts +22 -3
- package/src/shared/workspace/types.ts +4 -3
package/dist/.build-fingerprint
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"hash":"
|
|
1
|
+
{"hash":"cd5b1f400f84c402","builtAt":"2026-09-28T08:35:05.618Z","fileCount":334}
|
|
@@ -19,11 +19,16 @@
|
|
|
19
19
|
* deepagents rejects filesystem `permissions` combined with an execution-capable
|
|
20
20
|
* backend — plan mode is read-only by construction, so no shell tool there.
|
|
21
21
|
*
|
|
22
|
-
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
22
|
+
* The observed mutations are `write` (create, or since deepagents 1.12 a
|
|
23
|
+
* whole-file overwrite — `recordBefore` reads the existing bytes either way)
|
|
24
|
+
* and `edit` (modify), so this observes CREATE and MODIFY. deepagents 1.13
|
|
25
|
+
* added a recursive backend `delete` and a `delete` tool over it; the native
|
|
26
|
+
* harness does not expose that tool (`deepagents-profiles.ts`), and these
|
|
27
|
+
* backends refuse a backend delete outright, so a graph whose model no profile
|
|
28
|
+
* resolves cannot delete a subtree behind the observer's back. Deleting stays
|
|
29
|
+
* on the shell (`rm`), which the approval gate holds as always, and a
|
|
30
|
+
* delete-category tool from elsewhere has its before-bytes recorded by the gate
|
|
31
|
+
* at authorization time (`captureDeleteBefore`, issue #303).
|
|
27
32
|
*
|
|
28
33
|
* VIRTUAL ROOT — THE ONE PATH DIALECT (issue #754)
|
|
29
34
|
* ------------------------------------------------
|
|
@@ -46,7 +51,7 @@
|
|
|
46
51
|
* virtual-root confinement (issue #754)
|
|
47
52
|
*/
|
|
48
53
|
import { FilesystemBackend, LocalShellBackend } from "deepagents";
|
|
49
|
-
import type { LocalShellBackendOptions } from "deepagents";
|
|
54
|
+
import type { DeleteResult, LocalShellBackendOptions } from "deepagents";
|
|
50
55
|
import type { CasCaptureObserver } from "./cas-capture-observer.js";
|
|
51
56
|
export type { CasBeforeMap } from "./cas-capture-observer.js";
|
|
52
57
|
type FilesystemBackendOptions = NonNullable<ConstructorParameters<typeof FilesystemBackend>[0]>;
|
|
@@ -58,12 +63,14 @@ export declare class CasCaptureFilesystemBackend extends FilesystemBackend {
|
|
|
58
63
|
constructor(options: FilesystemBackendOptions, deps: CasCaptureDeps);
|
|
59
64
|
write(filePath: string, content: string): Promise<import("deepagents").WriteResult>;
|
|
60
65
|
edit(filePath: string, oldString: string, newString: string, replaceAll?: boolean): Promise<import("deepagents").EditResult>;
|
|
66
|
+
delete(filePath: string): Promise<DeleteResult>;
|
|
61
67
|
}
|
|
62
68
|
export declare class CasCaptureShellBackend extends LocalShellBackend {
|
|
63
69
|
private readonly observer;
|
|
64
70
|
constructor(options: LocalShellBackendOptions, deps: CasCaptureDeps);
|
|
65
71
|
write(filePath: string, content: string): Promise<import("deepagents").WriteResult>;
|
|
66
72
|
edit(filePath: string, oldString: string, newString: string, replaceAll?: boolean): Promise<import("deepagents").EditResult>;
|
|
73
|
+
delete(filePath: string): Promise<DeleteResult>;
|
|
67
74
|
}
|
|
68
75
|
export type CasCaptureBackend = CasCaptureFilesystemBackend | CasCaptureShellBackend;
|
|
69
76
|
export interface CreateCasCaptureBackendOptions {
|
|
@@ -19,11 +19,16 @@
|
|
|
19
19
|
* deepagents rejects filesystem `permissions` combined with an execution-capable
|
|
20
20
|
* backend — plan mode is read-only by construction, so no shell tool there.
|
|
21
21
|
*
|
|
22
|
-
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
22
|
+
* The observed mutations are `write` (create, or since deepagents 1.12 a
|
|
23
|
+
* whole-file overwrite — `recordBefore` reads the existing bytes either way)
|
|
24
|
+
* and `edit` (modify), so this observes CREATE and MODIFY. deepagents 1.13
|
|
25
|
+
* added a recursive backend `delete` and a `delete` tool over it; the native
|
|
26
|
+
* harness does not expose that tool (`deepagents-profiles.ts`), and these
|
|
27
|
+
* backends refuse a backend delete outright, so a graph whose model no profile
|
|
28
|
+
* resolves cannot delete a subtree behind the observer's back. Deleting stays
|
|
29
|
+
* on the shell (`rm`), which the approval gate holds as always, and a
|
|
30
|
+
* delete-category tool from elsewhere has its before-bytes recorded by the gate
|
|
31
|
+
* at authorization time (`captureDeleteBefore`, issue #303).
|
|
27
32
|
*
|
|
28
33
|
* VIRTUAL ROOT — THE ONE PATH DIALECT (issue #754)
|
|
29
34
|
* ------------------------------------------------
|
|
@@ -46,6 +51,11 @@
|
|
|
46
51
|
* virtual-root confinement (issue #754)
|
|
47
52
|
*/
|
|
48
53
|
import { FilesystemBackend, LocalShellBackend } from "deepagents";
|
|
54
|
+
function refusedDelete(filePath) {
|
|
55
|
+
return {
|
|
56
|
+
error: `Error: deleting '${filePath}' through the file tools is not available; use the shell (rm)`,
|
|
57
|
+
};
|
|
58
|
+
}
|
|
49
59
|
export class CasCaptureFilesystemBackend extends FilesystemBackend {
|
|
50
60
|
observer;
|
|
51
61
|
constructor(options, deps) {
|
|
@@ -60,6 +70,9 @@ export class CasCaptureFilesystemBackend extends FilesystemBackend {
|
|
|
60
70
|
await this.observer.recordBefore(filePath);
|
|
61
71
|
return super.edit(filePath, oldString, newString, replaceAll);
|
|
62
72
|
}
|
|
73
|
+
async delete(filePath) {
|
|
74
|
+
return refusedDelete(filePath);
|
|
75
|
+
}
|
|
63
76
|
}
|
|
64
77
|
export class CasCaptureShellBackend extends LocalShellBackend {
|
|
65
78
|
observer;
|
|
@@ -75,6 +88,9 @@ export class CasCaptureShellBackend extends LocalShellBackend {
|
|
|
75
88
|
await this.observer.recordBefore(filePath);
|
|
76
89
|
return super.edit(filePath, oldString, newString, replaceAll);
|
|
77
90
|
}
|
|
91
|
+
async delete(filePath) {
|
|
92
|
+
return refusedDelete(filePath);
|
|
93
|
+
}
|
|
78
94
|
}
|
|
79
95
|
/**
|
|
80
96
|
* Construct the CAS-observing backend for a deepagents agent graph.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cas-capture-backend.js","sourceRoot":"","sources":["../../../src/activities/execute-deep-agent/cas-capture-backend.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"cas-capture-backend.js","sourceRoot":"","sources":["../../../src/activities/execute-deep-agent/cas-capture-backend.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmDG;AAEH,OAAO,EAAE,iBAAiB,EAAE,iBAAiB,EAAE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AC,QAAQ,EAAE,OAAO,CAAC,CAAC;IACxC,CAAC;IAEQ,KAAK,CAAC,IAAI,CACjB,QAAgB,EAChB,SAAiB,EACjB,SAAiB,EACjB,UAAoB;QAEpB,MAAM,IAAI,CAAC,QAAQ,CAAC,YAAY,CAAC,QAAQ,CAAC,CAAC;QAC3C,OAAO,KAAK,CAAC,IAAI,CAAC,QAAQ,EAAE,SAAS,EAAE,SAAS,EAAE,UAAU,CAAC,CAAC;IAChE,CAAC;IAEQ,KAAK,CAAC,MAAM,CAAC,QAAgB;QACpC,OAAO,aAAa,CAAC,QAAQ,CAAC,CAAC;IACjC,CAAC;CACF;AAWD;;;;;GAKG;AACH,MAAM,CAAC,KAAK,UAAU,uBAAuB,CAC3C,OAAuC;IAEvC,MAAM,EAAE,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,GAAG,OAAO,CAAC;IAEhD,IAAI,QAAQ,KAAK,SAAS,EAAE,CAAC;QAC3B,MAAM,OAAO,GAAG,IAAI,sBAAsB,CACxC,EAAE,OAAO,EAAE,WAAW,EAAE,IAAI,EAAE,GAAG,EAAE,QAAQ,EAAE,EAC7C,EAAE,QAAQ,EAAE,CACb,CAAC;QACF,MAAM,OAAO,CAAC,UAAU,EAAE,CAAC;QAC3B,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,OAAO,IAAI,2BAA2B,CAAC,EAAE,OAAO,EAAE,WAAW,EAAE,IAAI,EAAE,EAAE,EAAE,QAAQ,EAAE,CAAC,CAAC;AACvF,CAAC"}
|
|
@@ -1,15 +1,29 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Stigmer-specific deepagents harness profile registrations.
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
* The injected sub-agent carries only deepagents' built-in middleware — not our
|
|
7
|
-
* approval gate — so it is an ungated write/edit path today and would be an
|
|
8
|
-
* ungated `execute` path with a shell backend.
|
|
4
|
+
* Two defaults of deepagents' `createDeepAgent()` are turned off for every
|
|
5
|
+
* provider the runner builds a model for:
|
|
9
6
|
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
7
|
+
* - The auto-injected `general-purpose` sub-agent. It carries only
|
|
8
|
+
* deepagents' built-in middleware — not our approval gate — so it would be
|
|
9
|
+
* an ungated write/edit path, and an ungated `execute` path with a shell
|
|
10
|
+
* backend. The runner compiles its own gated `general-purpose` instead
|
|
11
|
+
* (`subagent-transformer.ts`).
|
|
12
|
+
* - The built-in `delete` tool (deepagents 1.13+), a recursive delete through
|
|
13
|
+
* the backend. The CAS capture backends observe `write` and `edit` only, so
|
|
14
|
+
* a directory delete would lose the before-bytes file review needs for the
|
|
15
|
+
* gitignored files beneath it. Deleting stays where it has always been on
|
|
16
|
+
* this harness: `rm` through the approval-gated shell. Excluding the tool
|
|
17
|
+
* here means the filesystem middleware never builds it, on the parent and
|
|
18
|
+
* on every sub-agent (1.14 resolves the profile per sub-agent model); the
|
|
19
|
+
* capture backends refuse a backend delete as well, for a graph whose model
|
|
20
|
+
* no profile resolves (`cas-capture-backend.ts`).
|
|
21
|
+
*
|
|
22
|
+
* Registrations merge additively with deepagents' built-in model profiles, so
|
|
23
|
+
* neither exclusion alters the model prompt overlays.
|
|
12
24
|
*/
|
|
25
|
+
/** Built-in tools the native harness never exposes; see the header. */
|
|
26
|
+
export declare const EXCLUDED_BUILTIN_TOOLS: readonly string[];
|
|
13
27
|
/** Idempotent: safe to call from runner boot and from tests. */
|
|
14
28
|
export declare function registerStigmerDeepagentsProfiles(): void;
|
|
15
29
|
/** Test-only: reset the once guard so profile registration can be re-exercised. */
|
|
@@ -1,26 +1,41 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Stigmer-specific deepagents harness profile registrations.
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
* The injected sub-agent carries only deepagents' built-in middleware — not our
|
|
7
|
-
* approval gate — so it is an ungated write/edit path today and would be an
|
|
8
|
-
* ungated `execute` path with a shell backend.
|
|
4
|
+
* Two defaults of deepagents' `createDeepAgent()` are turned off for every
|
|
5
|
+
* provider the runner builds a model for:
|
|
9
6
|
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
7
|
+
* - The auto-injected `general-purpose` sub-agent. It carries only
|
|
8
|
+
* deepagents' built-in middleware — not our approval gate — so it would be
|
|
9
|
+
* an ungated write/edit path, and an ungated `execute` path with a shell
|
|
10
|
+
* backend. The runner compiles its own gated `general-purpose` instead
|
|
11
|
+
* (`subagent-transformer.ts`).
|
|
12
|
+
* - The built-in `delete` tool (deepagents 1.13+), a recursive delete through
|
|
13
|
+
* the backend. The CAS capture backends observe `write` and `edit` only, so
|
|
14
|
+
* a directory delete would lose the before-bytes file review needs for the
|
|
15
|
+
* gitignored files beneath it. Deleting stays where it has always been on
|
|
16
|
+
* this harness: `rm` through the approval-gated shell. Excluding the tool
|
|
17
|
+
* here means the filesystem middleware never builds it, on the parent and
|
|
18
|
+
* on every sub-agent (1.14 resolves the profile per sub-agent model); the
|
|
19
|
+
* capture backends refuse a backend delete as well, for a graph whose model
|
|
20
|
+
* no profile resolves (`cas-capture-backend.ts`).
|
|
21
|
+
*
|
|
22
|
+
* Registrations merge additively with deepagents' built-in model profiles, so
|
|
23
|
+
* neither exclusion alters the model prompt overlays.
|
|
12
24
|
*/
|
|
13
25
|
import { registerHarnessProfile } from "deepagents";
|
|
14
|
-
const
|
|
26
|
+
const PROVIDERS_WITH_STIGMER_PROFILE = ["anthropic", "openai"];
|
|
27
|
+
/** Built-in tools the native harness never exposes; see the header. */
|
|
28
|
+
export const EXCLUDED_BUILTIN_TOOLS = ["delete"];
|
|
15
29
|
let registered = false;
|
|
16
30
|
/** Idempotent: safe to call from runner boot and from tests. */
|
|
17
31
|
export function registerStigmerDeepagentsProfiles() {
|
|
18
32
|
if (registered)
|
|
19
33
|
return;
|
|
20
34
|
registered = true;
|
|
21
|
-
for (const provider of
|
|
35
|
+
for (const provider of PROVIDERS_WITH_STIGMER_PROFILE) {
|
|
22
36
|
registerHarnessProfile(provider, {
|
|
23
37
|
generalPurposeSubagent: { enabled: false },
|
|
38
|
+
excludedTools: [...EXCLUDED_BUILTIN_TOOLS],
|
|
24
39
|
});
|
|
25
40
|
}
|
|
26
41
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deepagents-profiles.js","sourceRoot":"","sources":["../../../src/activities/execute-deep-agent/deepagents-profiles.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"deepagents-profiles.js","sourceRoot":"","sources":["../../../src/activities/execute-deep-agent/deepagents-profiles.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AAEH,OAAO,EAAE,sBAAsB,EAAE,MAAM,YAAY,CAAC;AAEpD,MAAM,8BAA8B,GAAG,CAAC,WAAW,EAAE,QAAQ,CAAU,CAAC;AAExE,uEAAuE;AACvE,MAAM,CAAC,MAAM,sBAAsB,GAAsB,CAAC,QAAQ,CAAC,CAAC;AAEpE,IAAI,UAAU,GAAG,KAAK,CAAC;AAEvB,gEAAgE;AAChE,MAAM,UAAU,iCAAiC;IAC/C,IAAI,UAAU;QAAE,OAAO;IACvB,UAAU,GAAG,IAAI,CAAC;IAElB,KAAK,MAAM,QAAQ,IAAI,8BAA8B,EAAE,CAAC;QACtD,sBAAsB,CAAC,QAAQ,EAAE;YAC/B,sBAAsB,EAAE,EAAE,OAAO,EAAE,KAAK,EAAE;YAC1C,aAAa,EAAE,CAAC,GAAG,sBAAsB,CAAC;SAC3C,CAAC,CAAC;IACL,CAAC;AACH,CAAC;AAED,mFAAmF;AACnF,MAAM,UAAU,sCAAsC;IACpD,UAAU,GAAG,KAAK,CAAC;AACrB,CAAC"}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The platform's read-only `.stigmer/` mount inside the native agent's
|
|
3
|
+
* virtual filesystem.
|
|
4
|
+
*
|
|
5
|
+
* WHY A ROUTE, NOT THE SYMLINK
|
|
6
|
+
* ----------------------------
|
|
7
|
+
* Platform content — resolved skills, attached inputs, the approved plan —
|
|
8
|
+
* lives in the session's platform dir, outside the workspace, and reaches the
|
|
9
|
+
* agent at `.stigmer/…` (`shared/workspace/stigmer-link.ts`). The Cursor SDK
|
|
10
|
+
* and the shell follow the workspace's `.stigmer` symlink to it. The native
|
|
11
|
+
* file tools cannot: deepagents (since 1.14) resolves every path of a
|
|
12
|
+
* `virtualMode` backend to its REAL location and refuses one that lands
|
|
13
|
+
* outside the root ("Path '…' resolves outside root directory",
|
|
14
|
+
* `FilesystemBackend.assertRealPathWithinRoot`), and every backend the native
|
|
15
|
+
* harness builds is virtual-rooted (`cas-capture-backend.ts`, issue #754).
|
|
16
|
+
* Turning that confinement off would reopen the escape it closes, so the
|
|
17
|
+
* platform dir is mounted instead through deepagents' own router,
|
|
18
|
+
* `CompositeBackend`, at exactly the prefix the prompts name.
|
|
19
|
+
*
|
|
20
|
+
* WHY READ-ONLY
|
|
21
|
+
* -------------
|
|
22
|
+
* Nothing legitimately writes platform content from a turn: inputs are
|
|
23
|
+
* presented as read-only and plan mode denies every write. A writable mount
|
|
24
|
+
* would also be dangerous and unreviewed: `CompositeBackend.delete` fans a
|
|
25
|
+
* delete out to every route beneath its target, so a delete of `/` or of
|
|
26
|
+
* `/.stigmer` would empty the platform dir, and a routed write would reach
|
|
27
|
+
* the platform dir without passing the CAS observer that file review reads.
|
|
28
|
+
* Every mutation through the mount therefore fails, which also makes the
|
|
29
|
+
* composite refuse any fan-out that touches it.
|
|
30
|
+
*
|
|
31
|
+
* WHEN IT IS MOUNTED
|
|
32
|
+
* ------------------
|
|
33
|
+
* On the turns where the workspace link points at the platform dir — the
|
|
34
|
+
* turns whose skill or attachment phase made it — so what the agent can
|
|
35
|
+
* reach is exactly what the link exposes to the shell on the same turn.
|
|
36
|
+
* The link itself stays: shell commands (a skill's own scripts among them)
|
|
37
|
+
* run in the workspace and resolve `.stigmer/…` through it.
|
|
38
|
+
*/
|
|
39
|
+
import { CompositeBackend, FilesystemBackend } from "deepagents";
|
|
40
|
+
import type { AnyBackendProtocol, DeleteResult, EditResult, FileUploadResponse, LsResult, WriteResult } from "deepagents";
|
|
41
|
+
/** The route prefix, with the trailing slash `CompositeBackend` needs to match `/.stigmer/x` but never `/.stigmerx`. */
|
|
42
|
+
export declare const PLATFORM_ROUTE_PREFIX = "/.stigmer/";
|
|
43
|
+
/** The platform dir, virtual-rooted like every native backend, refusing every mutation. */
|
|
44
|
+
export declare class PlatformContentBackend extends FilesystemBackend {
|
|
45
|
+
constructor(platformDir: string);
|
|
46
|
+
write(filePath: string): Promise<WriteResult>;
|
|
47
|
+
edit(filePath: string): Promise<EditResult>;
|
|
48
|
+
delete(filePath: string): Promise<DeleteResult>;
|
|
49
|
+
uploadFiles(files: Array<[string, Uint8Array]>): Promise<FileUploadResponse[]>;
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* The workspace backend with the platform mounted at {@link PLATFORM_ROUTE_PREFIX}.
|
|
53
|
+
*
|
|
54
|
+
* One behaviour differs from the stock router: listing `/`. The composite
|
|
55
|
+
* adds each route to the root listing, and the workspace backend already
|
|
56
|
+
* lists `.stigmer/` by following the link, so the stock listing names the
|
|
57
|
+
* same directory twice; the root listing is de-duplicated by path.
|
|
58
|
+
*/
|
|
59
|
+
export declare class PlatformRoutedBackend extends CompositeBackend {
|
|
60
|
+
ls(path: string): Promise<LsResult>;
|
|
61
|
+
}
|
|
62
|
+
export interface PlatformRouteOptions {
|
|
63
|
+
/** The workspace root the backend is rooted at (where the link lives). */
|
|
64
|
+
readonly workspaceDir: string;
|
|
65
|
+
/** The session's platform dir; absent when the session has none. */
|
|
66
|
+
readonly platformDir: string | undefined;
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* Mount the platform route over `backend` when this turn exposes platform
|
|
70
|
+
* content; otherwise hand `backend` back unchanged. `execute` and the
|
|
71
|
+
* sandbox identity stay the workspace backend's (`CompositeBackend` delegates
|
|
72
|
+
* both to its default), so a shell-capable graph keeps its `execute` tool and
|
|
73
|
+
* a plan-mode graph stays without one.
|
|
74
|
+
*/
|
|
75
|
+
export declare function mountPlatformRoute(backend: AnyBackendProtocol, options: PlatformRouteOptions): Promise<AnyBackendProtocol>;
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The platform's read-only `.stigmer/` mount inside the native agent's
|
|
3
|
+
* virtual filesystem.
|
|
4
|
+
*
|
|
5
|
+
* WHY A ROUTE, NOT THE SYMLINK
|
|
6
|
+
* ----------------------------
|
|
7
|
+
* Platform content — resolved skills, attached inputs, the approved plan —
|
|
8
|
+
* lives in the session's platform dir, outside the workspace, and reaches the
|
|
9
|
+
* agent at `.stigmer/…` (`shared/workspace/stigmer-link.ts`). The Cursor SDK
|
|
10
|
+
* and the shell follow the workspace's `.stigmer` symlink to it. The native
|
|
11
|
+
* file tools cannot: deepagents (since 1.14) resolves every path of a
|
|
12
|
+
* `virtualMode` backend to its REAL location and refuses one that lands
|
|
13
|
+
* outside the root ("Path '…' resolves outside root directory",
|
|
14
|
+
* `FilesystemBackend.assertRealPathWithinRoot`), and every backend the native
|
|
15
|
+
* harness builds is virtual-rooted (`cas-capture-backend.ts`, issue #754).
|
|
16
|
+
* Turning that confinement off would reopen the escape it closes, so the
|
|
17
|
+
* platform dir is mounted instead through deepagents' own router,
|
|
18
|
+
* `CompositeBackend`, at exactly the prefix the prompts name.
|
|
19
|
+
*
|
|
20
|
+
* WHY READ-ONLY
|
|
21
|
+
* -------------
|
|
22
|
+
* Nothing legitimately writes platform content from a turn: inputs are
|
|
23
|
+
* presented as read-only and plan mode denies every write. A writable mount
|
|
24
|
+
* would also be dangerous and unreviewed: `CompositeBackend.delete` fans a
|
|
25
|
+
* delete out to every route beneath its target, so a delete of `/` or of
|
|
26
|
+
* `/.stigmer` would empty the platform dir, and a routed write would reach
|
|
27
|
+
* the platform dir without passing the CAS observer that file review reads.
|
|
28
|
+
* Every mutation through the mount therefore fails, which also makes the
|
|
29
|
+
* composite refuse any fan-out that touches it.
|
|
30
|
+
*
|
|
31
|
+
* WHEN IT IS MOUNTED
|
|
32
|
+
* ------------------
|
|
33
|
+
* On the turns where the workspace link points at the platform dir — the
|
|
34
|
+
* turns whose skill or attachment phase made it — so what the agent can
|
|
35
|
+
* reach is exactly what the link exposes to the shell on the same turn.
|
|
36
|
+
* The link itself stays: shell commands (a skill's own scripts among them)
|
|
37
|
+
* run in the workspace and resolve `.stigmer/…` through it.
|
|
38
|
+
*/
|
|
39
|
+
import { CompositeBackend, FilesystemBackend } from "deepagents";
|
|
40
|
+
import { STIGMER_LOCAL_STATE_DIR, stigmerSymlinkPointsAt } from "../../shared/workspace/stigmer-link.js";
|
|
41
|
+
/** The route prefix, with the trailing slash `CompositeBackend` needs to match `/.stigmer/x` but never `/.stigmerx`. */
|
|
42
|
+
export const PLATFORM_ROUTE_PREFIX = `/${STIGMER_LOCAL_STATE_DIR}/`;
|
|
43
|
+
function readOnly(routedPath) {
|
|
44
|
+
const agentPath = `${PLATFORM_ROUTE_PREFIX.slice(0, -1)}${routedPath}`;
|
|
45
|
+
return (`Error: '${agentPath}' is platform content (skills, attached inputs, the approved plan) ` +
|
|
46
|
+
"and is read-only; write your own files in the workspace");
|
|
47
|
+
}
|
|
48
|
+
/** The platform dir, virtual-rooted like every native backend, refusing every mutation. */
|
|
49
|
+
export class PlatformContentBackend extends FilesystemBackend {
|
|
50
|
+
constructor(platformDir) {
|
|
51
|
+
super({ rootDir: platformDir, virtualMode: true });
|
|
52
|
+
}
|
|
53
|
+
async write(filePath) {
|
|
54
|
+
return { error: readOnly(filePath) };
|
|
55
|
+
}
|
|
56
|
+
async edit(filePath) {
|
|
57
|
+
return { error: readOnly(filePath) };
|
|
58
|
+
}
|
|
59
|
+
async delete(filePath) {
|
|
60
|
+
return { error: readOnly(filePath) };
|
|
61
|
+
}
|
|
62
|
+
async uploadFiles(files) {
|
|
63
|
+
return files.map(([path]) => ({ path, error: "permission_denied" }));
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
/**
|
|
67
|
+
* The workspace backend with the platform mounted at {@link PLATFORM_ROUTE_PREFIX}.
|
|
68
|
+
*
|
|
69
|
+
* One behaviour differs from the stock router: listing `/`. The composite
|
|
70
|
+
* adds each route to the root listing, and the workspace backend already
|
|
71
|
+
* lists `.stigmer/` by following the link, so the stock listing names the
|
|
72
|
+
* same directory twice; the root listing is de-duplicated by path.
|
|
73
|
+
*/
|
|
74
|
+
export class PlatformRoutedBackend extends CompositeBackend {
|
|
75
|
+
async ls(path) {
|
|
76
|
+
const result = await super.ls(path);
|
|
77
|
+
if (path !== "/" || !result.files)
|
|
78
|
+
return result;
|
|
79
|
+
const seen = new Set();
|
|
80
|
+
return {
|
|
81
|
+
...result,
|
|
82
|
+
files: result.files.filter((entry) => {
|
|
83
|
+
if (seen.has(entry.path))
|
|
84
|
+
return false;
|
|
85
|
+
seen.add(entry.path);
|
|
86
|
+
return true;
|
|
87
|
+
}),
|
|
88
|
+
};
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
/**
|
|
92
|
+
* Mount the platform route over `backend` when this turn exposes platform
|
|
93
|
+
* content; otherwise hand `backend` back unchanged. `execute` and the
|
|
94
|
+
* sandbox identity stay the workspace backend's (`CompositeBackend` delegates
|
|
95
|
+
* both to its default), so a shell-capable graph keeps its `execute` tool and
|
|
96
|
+
* a plan-mode graph stays without one.
|
|
97
|
+
*/
|
|
98
|
+
export async function mountPlatformRoute(backend, options) {
|
|
99
|
+
const { workspaceDir, platformDir } = options;
|
|
100
|
+
if (platformDir === undefined || !(await stigmerSymlinkPointsAt(workspaceDir, platformDir))) {
|
|
101
|
+
return backend;
|
|
102
|
+
}
|
|
103
|
+
return new PlatformRoutedBackend(backend, {
|
|
104
|
+
[PLATFORM_ROUTE_PREFIX]: new PlatformContentBackend(platformDir),
|
|
105
|
+
});
|
|
106
|
+
}
|
|
107
|
+
//# sourceMappingURL=platform-route.js.map
|
|
@@ -0,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alGate?: ApprovalGateConfig | null;
|
|
191
191
|
readonly parentModelName: string;
|
|
192
192
|
readonly workspaceRootDir: string;
|
|
193
|
+
/** The session's platform dir, mounted read-only at `.stigmer/` (`platform-route.ts`). */
|
|
194
|
+
readonly platformDir?: string;
|
|
193
195
|
/** Shared CAS observer (capture mode only); see {@link SubagentTransformOptions.casObserver}. */
|
|
194
196
|
readonly casObserver?: CasCaptureObserver;
|
|
195
197
|
readonly modelFactory?: (modelName: string) => Promise<BaseChatModel>;
|
|
@@ -23,6 +23,7 @@
|
|
|
23
23
|
*/
|
|
24
24
|
import { createDeepAgent, FilesystemBackend, LocalShellBackend, DEFAULT_GENERAL_PURPOSE_DESCRIPTION, DEFAULT_SUBAGENT_PROMPT } from "deepagents";
|
|
25
25
|
import { createCasCaptureBackend } from "./cas-capture-backend.js";
|
|
26
|
+
import { mountPlatformRoute } from "./platform-route.js";
|
|
26
27
|
import { createThinkTool, createWebFetchTool } from "../../tools/index.js";
|
|
27
28
|
import { buildSubAgentMiddleware } from "./subagent-wiring.js";
|
|
28
29
|
import { SubAgentGate } from "../../shared/subagent-gate.js";
|
|
@@ -301,9 +302,17 @@ export function modelHasNativeThinking(modelId) {
|
|
|
301
302
|
*
|
|
302
303
|
* Every variant is virtual-rooted (`virtualMode: true`) like the parent's —
|
|
303
304
|
* see the cas-capture-backend.ts header (issue #754): workspace confinement
|
|
304
|
-
* is structural on every graph, sub-agents included.
|
|
305
|
+
* is structural on every graph, sub-agents included. Every variant also gets
|
|
306
|
+
* the parent's read-only `.stigmer/` platform mount (`platform-route.ts`), so
|
|
307
|
+
* a sub-agent reads its skills where its prompt says they are.
|
|
305
308
|
*/
|
|
306
309
|
async function buildSubagentBackend(opts) {
|
|
310
|
+
return mountPlatformRoute(await buildSubagentWorkspaceBackend(opts), {
|
|
311
|
+
workspaceDir: opts.workspaceRootDir,
|
|
312
|
+
platformDir: opts.platformDir,
|
|
313
|
+
});
|
|
314
|
+
}
|
|
315
|
+
async function buildSubagentWorkspaceBackend(opts) {
|
|
307
316
|
if (opts.casObserver) {
|
|
308
317
|
return createCasCaptureBackend({
|
|
309
318
|
rootDir: opts.workspaceRootDir,
|
|
@@ -445,11 +454,25 @@ export async function transformAndCompileSubagents(options) {
|
|
|
445
454
|
console.error(`[subagent-transformer] Failed to transform sub-agent '${subAgent.name}': ${err}`);
|
|
446
455
|
}
|
|
447
456
|
}
|
|
448
|
-
// Step 3: Merge built-ins with transformed (proto overrides take precedence)
|
|
449
|
-
|
|
457
|
+
// Step 3: Merge built-ins with transformed (proto overrides take precedence).
|
|
458
|
+
// Names are unique by the time deepagents sees them: since 1.14 it refuses
|
|
459
|
+
// a duplicate sub-agent name and fails the turn, where it used to let the
|
|
460
|
+
// later one win. Nothing upstream of the runner validates the names, so the
|
|
461
|
+
// runner keeps the behaviour agents were written against — a later
|
|
462
|
+
// declaration overrides an earlier one of the same name, as a proto
|
|
463
|
+
// definition overrides a built-in.
|
|
464
|
+
const declared = new Map();
|
|
465
|
+
for (const spec of transformed) {
|
|
466
|
+
if (declared.has(spec.name)) {
|
|
467
|
+
console.warn(`[subagent-transformer] Sub-agent name '${spec.name}' is declared more than once. ` +
|
|
468
|
+
"The later declaration overrides the earlier one.");
|
|
469
|
+
declared.delete(spec.name);
|
|
470
|
+
}
|
|
471
|
+
declared.set(spec.name, spec);
|
|
472
|
+
}
|
|
450
473
|
const allSpecs = [
|
|
451
|
-
...builtins.filter((b) => !
|
|
452
|
-
...
|
|
474
|
+
...builtins.filter((b) => !declared.has(b.name)),
|
|
475
|
+
...declared.values(),
|
|
453
476
|
];
|
|
454
477
|
if (allSpecs.length === 0) {
|
|
455
478
|
console.warn("[subagent-transformer] No valid subagents after transformation");
|
|
@@ -461,6 +484,7 @@ export async function transformAndCompileSubagents(options) {
|
|
|
461
484
|
approvalGate,
|
|
462
485
|
parentModelName,
|
|
463
486
|
workspaceRootDir: workspaceBackend.rootDir,
|
|
487
|
+
platformDir: workspaceBackend.platformDir,
|
|
464
488
|
casObserver,
|
|
465
489
|
modelFactory,
|
|
466
490
|
shellEnv,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"subagent-transformer.js","sourceRoot":"","sources":["../../../src/activities/execute-deep-agent/subagent-transformer.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAEH,OAAO,EAAE,eAAe,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,mCAAmC,EAAE,uBAAuB,EAAE,MAAM,YAAY,CAAC;AAUjJ,OAAO,EAAE,uBAAuB,EAAE,MAAM,0BAA0B,CAAC;AAGnE,OAAO,EAAE,eAAe,EAAE,kBAAkB,EAAqB,MAAM,sBAAsB,CAAC;AAC9F,OAAO,EAAE,uBAAuB,EAAE,MAAM,sBAAsB,CAAC;AAC/D,OAAO,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;AAC7D,OAAO,EAAE,iBAAiB,EAAE,MAAM,gCAAgC,CAAC;AAEnE,OAAO,EAAE,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AAE1D,4EAA4E;AAC5E,sCAAsC;AACtC,4EAA4E;AAE5E,MAAM,CAAC,MAAM,sBAAsB,GAAwB,IAAI,GAAG,CAAC;IACjE,SAAS;IACT,OAAO;IACP,iBAAiB;CAClB,CAAC,CAAC;AAEH,MAAM,qBAAqB,GAAG;;;;;;;;;;;;yBAYL,CAAC;AAE1B,MAAM,mBAAmB,GAAG;;;;;;;;;;;;yBAYH,CAAC;AAE1B,MAAM,oBAAoB,GAAgC,IAAI,GAAG,CAAC;IAChE,CAAC,SAAS,EAAE,CACV,gEAAgE;YAChE,qEAAqE;YACrE,yCAAyC,CAC1C,CAAC;IACF,CAAC,OAAO,EAAE,CACR,gEAAgE;YAChE,mEAAmE,CACpE,CAAC;CACH,CAAC,CAAC;AAEH,MAAM,eAAe,GAAgC,IAAI,GAAG,CAAC;IAC3D,CAAC,SAAS,EAAE,qBAAqB,CAAC;IAClC,CAAC,OAAO,EAAE,mBA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AC,GAAG,CACT,gDAAgD,QAAQ,CAAC,MAAM,eAAe,CAC/E,CAAC;IACF,OAAO,QAAQ,CAAC;AAClB,CAAC;AAED,4EAA4E;AAC5E,kBAAkB;AAClB,4EAA4E;AAE5E;;;;;;;GAOG;AACH,KAAK,UAAU,sBAAsB,CAAC,OAAe;IACnD,MAAM,KAAK,GAAG,OAAO,CAAC,WAAW,EAAE,CAAC;IAEpC,IAAI,KAAK,CAAC,QAAQ,CAAC,OAAO,CAAC;QAAE,OAAO,KAAK,CAAC;IAC1C,IAAI,KAAK,CAAC,QAAQ,CAAC,aAAa,CAAC;QAAE,OAAO,KAAK,CAAC;IAEhD,IAAI,KAAK,CAAC,QAAQ,CAAC,QAAQ,CAAC,IAAI,CAC9B,KAAK,CAAC,QAAQ,CAAC,QAAQ,CAAC,IAAI,KAAK,CAAC,QAAQ,CAAC,MAAM,CAAC,CACnD;QAAE,OAAO,IAAI,CAAC;IAEf,IAAI,KAAK,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,KAAK,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,KAAK,CAAC,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC;QACzE,OAAO,IAAI,CAAC;IACd,CAAC;IAED,OAAO,KAAK,CAAC;AACf,CAAC"}
|
|
@@ -2,12 +2,10 @@
|
|
|
2
2
|
* Sub-agent middleware composition for ExecuteDeepAgent.
|
|
3
3
|
*
|
|
4
4
|
* Each sub-agent gets its own middleware stack with:
|
|
5
|
-
* - Path normalization (issue #429), FIRST
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
* same `permissions` option it bakes into the graph, keeping the rules
|
|
10
|
-
* and their normalization shim coupled.
|
|
5
|
+
* - Path normalization (issue #429), FIRST, on every graph since issue #754
|
|
6
|
+
* — workspace-relative paths are rewritten to the virtual root's dialect
|
|
7
|
+
* before deepagents' permission validation and the backend see them,
|
|
8
|
+
* exactly as on the parent (`compileSubagents` always passes it).
|
|
11
9
|
* - Fresh loop detection (independent cycle tracking)
|
|
12
10
|
* - Tool intent (issue #276) — the shell tool's bind-time schema gains the
|
|
13
11
|
* optional model-authored `description`, so sub-agent shell rows carry
|
|
@@ -75,7 +73,7 @@ export interface SubAgentMiddlewareOptions {
|
|
|
75
73
|
* workspace-absolute paths (matching the parent). The gate sits before the
|
|
76
74
|
* cost-cap view so an approval pause happens before budget accounting, and
|
|
77
75
|
* error hints come after the gate — both matching the parent order
|
|
78
|
-
* (…→ truncation →
|
|
76
|
+
* (…→ truncation → approval gate → cost cap → error hints …),
|
|
79
77
|
* which keeps the gate's HITL interrupt outside the hints' try/catch.
|
|
80
78
|
*/
|
|
81
79
|
export declare function buildSubAgentMiddleware(options?: SubAgentMiddlewareOptions): StigmerMiddleware[];
|
|
@@ -2,12 +2,10 @@
|
|
|
2
2
|
* Sub-agent middleware composition for ExecuteDeepAgent.
|
|
3
3
|
*
|
|
4
4
|
* Each sub-agent gets its own middleware stack with:
|
|
5
|
-
* - Path normalization (issue #429), FIRST
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
* same `permissions` option it bakes into the graph, keeping the rules
|
|
10
|
-
* and their normalization shim coupled.
|
|
5
|
+
* - Path normalization (issue #429), FIRST, on every graph since issue #754
|
|
6
|
+
* — workspace-relative paths are rewritten to the virtual root's dialect
|
|
7
|
+
* before deepagents' permission validation and the backend see them,
|
|
8
|
+
* exactly as on the parent (`compileSubagents` always passes it).
|
|
11
9
|
* - Fresh loop detection (independent cycle tracking)
|
|
12
10
|
* - Tool intent (issue #276) — the shell tool's bind-time schema gains the
|
|
13
11
|
* optional model-authored `description`, so sub-agent shell rows carry
|
|
@@ -55,7 +53,7 @@ const SUB_AGENT_MAX_ADVISORIES = 4;
|
|
|
55
53
|
* workspace-absolute paths (matching the parent). The gate sits before the
|
|
56
54
|
* cost-cap view so an approval pause happens before budget accounting, and
|
|
57
55
|
* error hints come after the gate — both matching the parent order
|
|
58
|
-
* (…→ truncation →
|
|
56
|
+
* (…→ truncation → approval gate → cost cap → error hints …),
|
|
59
57
|
* which keeps the gate's HITL interrupt outside the hints' try/catch.
|
|
60
58
|
*/
|
|
61
59
|
export function buildSubAgentMiddleware(options = {}) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"subagent-wiring.js","sourceRoot":"","sources":["../../../src/activities/execute-deep-agent/subagent-wiring.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"subagent-wiring.js","sourceRoot":"","sources":["../../../src/activities/execute-deep-agent/subagent-wiring.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkCG;AAQH,OAAO,EAAE,iCAAiC,EAAE,MAAM,wCAAwC,CAAC;AAC3F,OAAO,EAAE,6BAA6B,EAAE,MAAM,oCAAoC,CAAC;AACnF,OAAO,EAAE,8BAA8B,EAAE,MAAM,qCAAqC,CAAC;AACrF,OAAO,EAAE,+BAA+B,EAAE,MAAM,sCAAsC,CAAC;AACvF,OAAO,EAAE,0BAA0B,EAAE,MAAM,iCAAiC,CAAC;AAC7E,OAAO,EACL,4BAA4B,GAE7B,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EAAE,0BAA0B,EAAE,MAAM,iCAAiC,CAAC;AAE7E,MAAM,2BAA2B,GAAG,EAAE,CAAC;AACvC,MAAM,wBAAwB,GAAG,CAAC,CAAC;AA6BnC;;;;;;;;;;;;;GAaG;AACH,MAAM,UAAU,uBAAuB,CACrC,UAAqC,EAAE;IAEvC,MAAM,KAAK,GAAwB,EAAE,CAAC;IAEtC,IAAI,OAAO,CAAC,iBAAiB,EAAE,CAAC;QAC9B,KAAK,CAAC,IAAI,CAAC,iCAAiC,CAAC,OAAO,CAAC,iBAAiB,CAAC,CAAC,CAAC;IAC3E,CAAC;IAED,KAAK,CAAC,IAAI,CAAC,6BAA6B,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC;IAE7D,KAAK,CAAC,IAAI,CAAC,+BAA+B,CAAC;QACzC,eAAe,EAAE,2BAA2B;QAC5C,WAAW,EAAE,wBAAwB;KACtC,CAAC,CAAC,CAAC;IAEJ,0EAA0E;IAC1E,4DAA4D;IAC5D,KAAK,CAAC,IAAI,CAAC,0BAA0B,EAAE,CAAC,CAAC;IAEzC,KAAK,CAAC,IAAI,CAAC,8BAA8B,CAAC,OAAO,CAAC,cAAc,CAAC,CAAC,CAAC;IAEnE,IAAI,OAAO,CAAC,YAAY,EAAE,CAAC;QACzB,2EAA2E;QAC3E,yEAAyE;QACzE,gEAAgE;QAChE,uEAAuE;QACvE,2EAA2E;QAC3E,0EAA0E;QAC1E,yEAAyE;QACzE,2EAA2E;QAC3E,mEAAmE;QACnE,yEAAyE;QACzE,sCAAsC;QACtC,KAAK,CAAC,IAAI,CAAC,4BAA4B,CACrC,OAAO,CAAC,cAAc;YACpB,CAAC,CAAC,OAAO,CAAC,YAAY;YACtB,CAAC,CAAC;gBACE,GAAG,OAAO,CAAC,YAAY;gBACvB,cAAc,EAAE,KAAK;gBACrB,mBAAmB,EAAE,SAAS;gBAC9B,mBAAmB,EAAE,SAAS;aAC/B,CACN,CAAC,CAAC;IACL,CAAC;IAED,IAAI,OAAO,CAAC,YAAY,EAAE,CAAC;QACzB,KAAK,CAAC,IAAI,CAAC,OAAO,CAAC,YAAY,CAAC,WAAW,EAAE,CAAC,CAAC;IACjD,CAAC;IAED,KAAK,CAAC,IAAI,CAAC,0BAA0B,EAAE,CAAC,CAAC;IAEzC,OAAO,KAAK,CAAC;AACf,CAAC"}
|
|
@@ -39,8 +39,12 @@
|
|
|
39
39
|
* sub-agent's rows carry none on either harness today (#1133), and one
|
|
40
40
|
* handler set would otherwise stamp them as a side effect.
|
|
41
41
|
*
|
|
42
|
-
* The scope, in LangGraph
|
|
43
|
-
*
|
|
42
|
+
* The scope, in LangGraph's v3 grammar (read at @langchain/langgraph 1.3.2,
|
|
43
|
+
* and unchanged at 1.4.18 — the delegation, to-do, tool-call, structured-
|
|
44
|
+
* output and approval-resume streams were recorded on both and compared;
|
|
45
|
+
* deepagents' own `createSubagentTransformer`, which this once mirrored, left
|
|
46
|
+
* with deepagents 1.14 and langchain's `createAgent` registers its
|
|
47
|
+
* successor): the root's model events arrive under
|
|
44
48
|
* `["model_request:<uuid>"]` and its tool events under `["tools:<uuid>"]`
|
|
45
49
|
* (one segment); a `task` tool start at that depth opens a sub-agent, and
|
|
46
50
|
* the segment it arrived under is the prefix every event of that sub-agent's
|