@ckanner/flywheel 0.32.1 → 0.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/CHANGELOG.md +10 -1
- package/README.md +7 -0
- package/README.zh-CN.md +5 -0
- package/THIRD_PARTY_NOTICES.md +42 -0
- package/bin/runtime.js +25 -31
- package/cordis.patch.yml +5 -0
- package/dist/bridge.mjs +421 -0
- package/dist/claude-code-pro-bridge.mjs +82 -0
- package/dist/claude-code-pro-worker.mjs +5 -0
- package/dist/client.js +4078 -0
- package/dist/codex-pro-bridge.mjs +75 -0
- package/dist/codex-pro-worker.mjs +5 -0
- package/dist/console-read.mjs +51 -0
- package/dist/control.mjs +218 -0
- package/dist/index.mjs +185 -0
- package/dist/installation.mjs +56 -0
- package/dist/machine-worker.mjs +241 -0
- package/dist/policy.mjs +91 -0
- package/dist/prewarm.mjs +136 -0
- package/dist/protocol.mjs +260 -0
- package/dist/task-association.mjs +127 -0
- package/dist/worker.mjs +52 -0
- package/dist/workspaces.mjs +42 -0
- package/docs/README.md +1 -1
- package/docs/README.zh-CN.md +1 -1
- package/docs/design.md +7 -4
- package/docs/en/configuration.md +1 -1
- package/docs/en/contributing.md +5 -6
- package/docs/en/flow-console.md +1 -1
- package/docs/en/getting-started.md +9 -2
- package/docs/en/releasing.md +132 -174
- package/docs/validation/2026-11-13-release-0.32.1.md +83 -0
- package/docs/validation/2026-11-14-single-package.md +60 -0
- package/docs/validation/README.md +2 -0
- package/docs/zh-CN/configuration.md +1 -1
- package/docs/zh-CN/contributing.md +4 -5
- package/docs/zh-CN/flow-console.md +1 -1
- package/docs/zh-CN/getting-started.md +7 -3
- package/docs/zh-CN/releasing.md +97 -81
- package/native/darwin-amd64/flywheel +0 -0
- package/native/darwin-arm64/flywheel +0 -0
- package/native/linux-amd64/flywheel +0 -0
- package/native/linux-arm64/flywheel +0 -0
- package/native/manifest.json +22 -0
- package/node_modules/dsh-subagent-codex-pro/CHANGELOG.md +403 -0
- package/node_modules/dsh-subagent-codex-pro/LICENSE +21 -0
- package/node_modules/dsh-subagent-codex-pro/README.md +557 -0
- package/node_modules/dsh-subagent-codex-pro/cordis.patch.yml +30 -0
- package/node_modules/dsh-subagent-codex-pro/docs/README.zh.md +355 -0
- package/node_modules/dsh-subagent-codex-pro/docs/machine-lifecycle-validation.md +65 -0
- package/node_modules/dsh-subagent-codex-pro/docs/machine-lifecycle.md +144 -0
- package/node_modules/dsh-subagent-codex-pro/docs/machine-lifecycle.zh.md +98 -0
- package/node_modules/dsh-subagent-codex-pro/docs/machine.md +194 -0
- package/node_modules/dsh-subagent-codex-pro/docs/orchestration.zh.md +86 -0
- package/node_modules/dsh-subagent-codex-pro/lib/codex-exec.js +68 -0
- package/node_modules/dsh-subagent-codex-pro/lib/codex-exec.js.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/dsh-types.js +15 -0
- package/node_modules/dsh-subagent-codex-pro/lib/dsh-types.js.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/index.js +830 -0
- package/node_modules/dsh-subagent-codex-pro/lib/index.js.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/jobs.js +35 -0
- package/node_modules/dsh-subagent-codex-pro/lib/jobs.js.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/jsonrpc.js +229 -0
- package/node_modules/dsh-subagent-codex-pro/lib/jsonrpc.js.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/machine-cli.js +101 -0
- package/node_modules/dsh-subagent-codex-pro/lib/machine-cli.js.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/machine-local.js +122 -0
- package/node_modules/dsh-subagent-codex-pro/lib/machine-local.js.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/machine-recovery.js +167 -0
- package/node_modules/dsh-subagent-codex-pro/lib/machine-recovery.js.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/machine-supervision.js +141 -0
- package/node_modules/dsh-subagent-codex-pro/lib/machine-supervision.js.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/machine-supervisor.js +128 -0
- package/node_modules/dsh-subagent-codex-pro/lib/machine-supervisor.js.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/machine.js +104 -0
- package/node_modules/dsh-subagent-codex-pro/lib/machine.js.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/process-guardian.js +156 -0
- package/node_modules/dsh-subagent-codex-pro/lib/process-guardian.js.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/run.js +842 -0
- package/node_modules/dsh-subagent-codex-pro/lib/run.js.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/structured.js +329 -0
- package/node_modules/dsh-subagent-codex-pro/lib/structured.js.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/tool.js +295 -0
- package/node_modules/dsh-subagent-codex-pro/lib/tool.js.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/codex-exec.d.ts +88 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/codex-exec.d.ts.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/dsh-types.d.ts +179 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/dsh-types.d.ts.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/index.d.ts +266 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/index.d.ts.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/jobs.d.ts +34 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/jobs.d.ts.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/jsonrpc.d.ts +113 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/jsonrpc.d.ts.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/machine-cli.d.ts +3 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/machine-cli.d.ts.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/machine-local.d.ts +4 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/machine-local.d.ts.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/machine-recovery.d.ts +53 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/machine-recovery.d.ts.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/machine-supervision.d.ts +8 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/machine-supervision.d.ts.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/machine-supervisor.d.ts +2 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/machine-supervisor.d.ts.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/machine.d.ts +70 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/machine.d.ts.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/process-guardian.d.ts +22 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/process-guardian.d.ts.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/run.d.ts +386 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/run.d.ts.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/structured.d.ts +35 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/structured.d.ts.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/tool.d.ts +107 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/tool.d.ts.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/usage.d.ts +131 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/usage.d.ts.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/wire.d.ts +321 -0
- package/node_modules/dsh-subagent-codex-pro/lib/types/wire.d.ts.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/usage.js +356 -0
- package/node_modules/dsh-subagent-codex-pro/lib/usage.js.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/lib/wire.js +986 -0
- package/node_modules/dsh-subagent-codex-pro/lib/wire.js.map +1 -0
- package/node_modules/dsh-subagent-codex-pro/package.json +76 -0
- package/npm/install.js +59 -6
- package/package.json +74 -12
- package/plugins/dsh/LICENSE +21 -0
- package/plugins/dsh/PROTOCOL.md +607 -0
- package/plugins/dsh/README.en.md +4 -0
- package/plugins/dsh/README.md +342 -0
- package/plugins/dsh/README.zh-CN.md +279 -0
- package/plugins/dsh/THIRD_PARTY_NOTICES.md +42 -0
- package/plugins/dsh/vendor/README.md +17 -0
- package/plugins/dsh/vendor/codex-pro.json +16 -0
|
@@ -0,0 +1,295 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The model-facing delegation tool.
|
|
3
|
+
*
|
|
4
|
+
* `@deepseek-ai/dsh-tool-subagent` cannot give an external provider the model
|
|
5
|
+
* surface: a row may only carry `modelSelectionSettings: true` when the provider
|
|
6
|
+
* declares `agentOptions`, and enabling it on the Codex row inside a preset
|
|
7
|
+
* makes that row disappear — silently, with no tool and no error. The control
|
|
8
|
+
* row in those experiments (same provider, same row, flag off) did register, so
|
|
9
|
+
* the provider and the row shape are both fine.
|
|
10
|
+
*
|
|
11
|
+
* So this plugin registers the tool itself, the way the LCU plugin registers
|
|
12
|
+
* `js`: on `agent/created`, into that agent's own context. `model` and
|
|
13
|
+
* `reasoning_effort` appear while this plugin's modelSelection setting is
|
|
14
|
+
* enabled; that setting is independent of the Host LLM route picker.
|
|
15
|
+
*
|
|
16
|
+
* @module dsh-subagent-codex-pro/tool
|
|
17
|
+
*/
|
|
18
|
+
/**
|
|
19
|
+
* Permission modes a per-call override may select without changing the
|
|
20
|
+
* configured policy upward.
|
|
21
|
+
*
|
|
22
|
+
* The tool description and schema should not advertise a choice that the
|
|
23
|
+
* runtime's narrowing guard will reject. When no policy is supplied (direct
|
|
24
|
+
* tests or older callers), all modes remain visible for compatibility.
|
|
25
|
+
*/
|
|
26
|
+
export function allowedPermissionModes(configured) {
|
|
27
|
+
const modes = [
|
|
28
|
+
'read-only', 'workspace-write', 'never', 'approve-for-me', 'dangerously-bypass-approvals-and-sandbox',
|
|
29
|
+
];
|
|
30
|
+
if (configured === undefined)
|
|
31
|
+
return modes;
|
|
32
|
+
return modes.filter((mode) => mode === configured || mode === 'read-only'
|
|
33
|
+
|| (configured === 'dangerously-bypass-approvals-and-sandbox' && mode === 'workspace-write'));
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* Build the delegation tool definition.
|
|
37
|
+
*
|
|
38
|
+
* @param options - the delegating Agent's fixed choices, its runner, and its
|
|
39
|
+
* background starter.
|
|
40
|
+
* @returns a definition ready for `agent.ctx.tools.register`.
|
|
41
|
+
*/
|
|
42
|
+
export function createCodexTool(options) {
|
|
43
|
+
const permissionModes = allowedPermissionModes(options.permissionMode);
|
|
44
|
+
const effortHint = options.reasoningEffort === undefined
|
|
45
|
+
? ''
|
|
46
|
+
: ` Leave it unset to use the configured ${options.reasoningEffort}.`;
|
|
47
|
+
return {
|
|
48
|
+
name: 'subagent_codex',
|
|
49
|
+
description: 'Delegate one self-contained task to Codex and return its final message. Codex runs in this session\'s '
|
|
50
|
+
+ 'working directory with its own tools, so the prompt must be self-contained: it cannot see this '
|
|
51
|
+
+ 'conversation. Prefer one delegation per independent task, and start independent delegations together '
|
|
52
|
+
+ 'in one assistant message.'
|
|
53
|
+
+ (options.modelSelectionEnabled
|
|
54
|
+
? ' `model` and `reasoning_effort` choose this delegation\'s Codex model and thinking level; omit them'
|
|
55
|
+
+ ' to use the configured defaults.'
|
|
56
|
+
: '')
|
|
57
|
+
+ (options.backgroundEnabled
|
|
58
|
+
? ' A delegation typically takes a minute or more: set `run_in_background` unless your next action'
|
|
59
|
+
+ ' depends on the result.'
|
|
60
|
+
: '')
|
|
61
|
+
+ ' A delegation is cancelled if it exceeds the deadline the plugin is configured with, and the result says so.'
|
|
62
|
+
+ (options.threadControlEnabled
|
|
63
|
+
? ' A delegation runs in a Codex thread whose lifetime is `'
|
|
64
|
+
+ options.defaultThreadMode
|
|
65
|
+
+ '` by default. Set `thread_mode: "persistent"` when the user wants to see, reopen, or continue this'
|
|
66
|
+
+ ' work in Codex itself — such a thread appears in the Codex application under this workspace and'
|
|
67
|
+
+ ' its id is reported with the result. Set `thread_mode: "ephemeral"` for a run that must leave no'
|
|
68
|
+
+ ' trace. Pass `thread_id` to continue an earlier thread instead of starting one; supplied'
|
|
69
|
+
+ ' `model`, `cwd`, and `permission_mode` override that thread when present, and an explicit'
|
|
70
|
+
+ ' thread id is never silently replaced by a different thread.'
|
|
71
|
+
: ''),
|
|
72
|
+
// A whole JSON Schema object: the harness rejects anything that is not
|
|
73
|
+
// `type: "object"`.
|
|
74
|
+
parameters: {
|
|
75
|
+
type: 'object',
|
|
76
|
+
properties: {
|
|
77
|
+
description: {
|
|
78
|
+
type: 'string',
|
|
79
|
+
description: 'A short (3-5 word) description of the delegated task, for display.',
|
|
80
|
+
},
|
|
81
|
+
prompt: {
|
|
82
|
+
type: 'string',
|
|
83
|
+
description: 'The complete task for Codex, including everything it needs and cannot ask for.',
|
|
84
|
+
},
|
|
85
|
+
timeout_ms: {
|
|
86
|
+
type: 'integer',
|
|
87
|
+
description: 'Deadline for this delegation in milliseconds, overriding the configured default'
|
|
88
|
+
+ ' (which the plugin reports when it starts). Use it when the user asks for a longer or shorter'
|
|
89
|
+
+ ' run than usual — a release smoke test takes tens of minutes, where a quick lookup does not.'
|
|
90
|
+
+ ' `0` means no deadline at all. A run that passes the deadline is cancelled and says so.',
|
|
91
|
+
},
|
|
92
|
+
output_schema: {
|
|
93
|
+
type: 'object',
|
|
94
|
+
description: 'A JSON Schema (object-rooted) the final answer must conform to. Codex enforces it,'
|
|
95
|
+
+ ' so the result is JSON that conforms rather than prose to parse and hope about — use it'
|
|
96
|
+
+ ' whenever a later step reads the answer mechanically, such as a verdict or a list of'
|
|
97
|
+
+ ' failures. The answer still arrives as text; it is JSON text.',
|
|
98
|
+
},
|
|
99
|
+
images: {
|
|
100
|
+
type: 'array',
|
|
101
|
+
items: { type: 'string' },
|
|
102
|
+
description: 'Absolute paths of images to show Codex alongside the task — a screenshot it'
|
|
103
|
+
+ ' should look at, a design it should match. Each path must exist and be a readable image.'
|
|
104
|
+
+ ' Codex receives them as images, so it does not have to go and open the files itself.'
|
|
105
|
+
+ ' Prefer this over writing a path into `prompt`.',
|
|
106
|
+
},
|
|
107
|
+
cwd: {
|
|
108
|
+
type: 'string',
|
|
109
|
+
description: 'Absolute path to run the delegation in. Defaults to this session\'s working'
|
|
110
|
+
+ ' directory. Use it when the work belongs somewhere else — a scratch directory the run may'
|
|
111
|
+
+ ' write into, for instance. The path must exist and be a directory. Naming one starts a fresh'
|
|
112
|
+
+ ' Codex thread unless an explicit `thread_id` is supplied, in which case it is applied as a'
|
|
113
|
+
+ ' resume override.',
|
|
114
|
+
},
|
|
115
|
+
permission_mode: {
|
|
116
|
+
type: 'string',
|
|
117
|
+
enum: permissionModes,
|
|
118
|
+
description: 'Permission mode for this delegation. Only modes that cannot expand the configured'
|
|
119
|
+
+ ' policy are listed. `read-only` is the safe Review mode:'
|
|
120
|
+
+ ' approvalPolicy=never plus a read-only sandbox. `workspace-write` combines never with'
|
|
121
|
+
+ ' the workspace-write sandbox. Per-call overrides may only narrow the configured policy.'
|
|
122
|
+
+ ' `never` alone is not read-only. Omit to use'
|
|
123
|
+
+ ' the provider configuration; leave the configured write mode alone for implementation work.',
|
|
124
|
+
},
|
|
125
|
+
...options.modelSelectionEnabled
|
|
126
|
+
? {
|
|
127
|
+
model: {
|
|
128
|
+
type: 'string',
|
|
129
|
+
description: 'Codex model id for this delegation, exactly as the user named it. Omit to'
|
|
130
|
+
+ ' leave the choice to Codex\'s own configuration; Codex accepts ids this session cannot'
|
|
131
|
+
+ ' enumerate.',
|
|
132
|
+
},
|
|
133
|
+
reasoning_effort: {
|
|
134
|
+
type: 'string',
|
|
135
|
+
description: 'Codex thinking level for this delegation, such as `low`, `medium`, `high`, or'
|
|
136
|
+
+ ` \`xhigh\`.${effortHint}`,
|
|
137
|
+
},
|
|
138
|
+
}
|
|
139
|
+
: {},
|
|
140
|
+
...options.backgroundEnabled
|
|
141
|
+
? {
|
|
142
|
+
run_in_background: {
|
|
143
|
+
type: 'boolean',
|
|
144
|
+
description: 'Run as a background job and return its id (collect with `job_output`, stop with'
|
|
145
|
+
+ ' `job_kill`). Defaults to false; set it unless your next action depends on the result.',
|
|
146
|
+
},
|
|
147
|
+
}
|
|
148
|
+
: {},
|
|
149
|
+
...options.threadControlEnabled
|
|
150
|
+
? {
|
|
151
|
+
thread_mode: {
|
|
152
|
+
type: 'string',
|
|
153
|
+
enum: ['ephemeral', 'persistent'],
|
|
154
|
+
description: 'Lifetime of this delegation\'s Codex thread. `persistent` keeps the thread after'
|
|
155
|
+
+ ' the run: it appears in the Codex application under this workspace and can be continued'
|
|
156
|
+
+ ' later by passing its id as `thread_id`. It also keeps the prompt prefix stable, so later'
|
|
157
|
+
+ ' resumes read from the model\'s cache. `ephemeral` is a throwaway run that leaves nothing'
|
|
158
|
+
+ ' behind. Omit to use the configured default.',
|
|
159
|
+
},
|
|
160
|
+
thread_id: {
|
|
161
|
+
type: 'string',
|
|
162
|
+
description: 'Continue an existing Codex thread instead of creating one. Pass the id a previous'
|
|
163
|
+
+ ' delegation reported. Supplied `model`, `cwd`, and `permission_mode` are applied as'
|
|
164
|
+
+ ' resume overrides; `reasoning_effort` remains a per-turn setting. An explicit id always'
|
|
165
|
+
+ ' continues that thread: a failed resume is reported, never silently replaced.',
|
|
166
|
+
},
|
|
167
|
+
}
|
|
168
|
+
: {},
|
|
169
|
+
},
|
|
170
|
+
required: ['description', 'prompt'],
|
|
171
|
+
additionalProperties: false,
|
|
172
|
+
},
|
|
173
|
+
output: {
|
|
174
|
+
// A foreground call answers with content blocks, so an image the run
|
|
175
|
+
// produced reaches the model as an image rather than as a description of
|
|
176
|
+
// one. A background call answers with the job handle its reader collects.
|
|
177
|
+
schema: options.backgroundEnabled
|
|
178
|
+
? {
|
|
179
|
+
oneOf: [
|
|
180
|
+
{
|
|
181
|
+
type: 'object',
|
|
182
|
+
additionalProperties: false,
|
|
183
|
+
properties: { content: { type: 'array', items: {} } },
|
|
184
|
+
required: ['content'],
|
|
185
|
+
},
|
|
186
|
+
{
|
|
187
|
+
type: 'object',
|
|
188
|
+
additionalProperties: false,
|
|
189
|
+
properties: {
|
|
190
|
+
kind: { type: 'string', const: 'background' },
|
|
191
|
+
jobId: { type: 'string' },
|
|
192
|
+
},
|
|
193
|
+
required: ['kind', 'jobId'],
|
|
194
|
+
},
|
|
195
|
+
],
|
|
196
|
+
}
|
|
197
|
+
: {
|
|
198
|
+
type: 'object',
|
|
199
|
+
additionalProperties: false,
|
|
200
|
+
properties: { content: { type: 'array', items: {} } },
|
|
201
|
+
required: ['content'],
|
|
202
|
+
},
|
|
203
|
+
render: (_args, value) => {
|
|
204
|
+
if (isBackgroundHandle(value)) {
|
|
205
|
+
return [{
|
|
206
|
+
type: 'text',
|
|
207
|
+
text: `Started as background job ${value.jobId}. Collect its result with job_output.`,
|
|
208
|
+
}];
|
|
209
|
+
}
|
|
210
|
+
const content = isContentResult(value) ? value.content : [];
|
|
211
|
+
const text = content
|
|
212
|
+
.filter((block) => block.type === 'text' && typeof block.text === 'string')
|
|
213
|
+
.map((block) => block.text)
|
|
214
|
+
.join('\n\n');
|
|
215
|
+
// The text already names the images, because a background call has only
|
|
216
|
+
// the text to go on; repeating the count here would say it twice.
|
|
217
|
+
return [{
|
|
218
|
+
type: 'text',
|
|
219
|
+
text: text === '' ? '(the delegation produced no text)' : text,
|
|
220
|
+
}];
|
|
221
|
+
},
|
|
222
|
+
},
|
|
223
|
+
async execute(args, exec) {
|
|
224
|
+
const request = (typeof args === 'object' && args !== null ? args : {});
|
|
225
|
+
const prompt = typeof request.prompt === 'string' ? request.prompt : '';
|
|
226
|
+
if (prompt === '')
|
|
227
|
+
throw new Error('subagent_codex: `prompt` is required and must not be empty');
|
|
228
|
+
const model = typeof request.model === 'string' && request.model !== '' ? request.model : options.model;
|
|
229
|
+
const effort = typeof request.reasoning_effort === 'string' && request.reasoning_effort !== ''
|
|
230
|
+
? request.reasoning_effort
|
|
231
|
+
: options.reasoningEffort;
|
|
232
|
+
const label = typeof request.description === 'string' && request.description !== ''
|
|
233
|
+
? request.description
|
|
234
|
+
: 'Codex delegation';
|
|
235
|
+
const cwd = typeof request.cwd === 'string' && request.cwd !== '' ? request.cwd : undefined;
|
|
236
|
+
const timeoutMs = typeof request.timeout_ms === 'number' ? request.timeout_ms : undefined;
|
|
237
|
+
const outputSchema = typeof request.output_schema === 'object' && request.output_schema !== null
|
|
238
|
+
&& !Array.isArray(request.output_schema)
|
|
239
|
+
? request.output_schema
|
|
240
|
+
: undefined;
|
|
241
|
+
const permissionMode = request.permission_mode === 'read-only'
|
|
242
|
+
|| request.permission_mode === 'workspace-write'
|
|
243
|
+
|| request.permission_mode === 'never'
|
|
244
|
+
|| request.permission_mode === 'approve-for-me'
|
|
245
|
+
|| request.permission_mode === 'dangerously-bypass-approvals-and-sandbox'
|
|
246
|
+
? request.permission_mode
|
|
247
|
+
: undefined;
|
|
248
|
+
if (request.permission_mode !== undefined && permissionMode === undefined) {
|
|
249
|
+
throw new Error('subagent_codex: permission_mode must be one of read-only, workspace-write, never, '
|
|
250
|
+
+ 'approve-for-me, dangerously-bypass-approvals-and-sandbox');
|
|
251
|
+
}
|
|
252
|
+
const images = Array.isArray(request.images)
|
|
253
|
+
? request.images.filter((value) => typeof value === 'string' && value !== '')
|
|
254
|
+
: undefined;
|
|
255
|
+
const threadMode = request.thread_mode === 'ephemeral' || request.thread_mode === 'persistent'
|
|
256
|
+
? request.thread_mode
|
|
257
|
+
: undefined;
|
|
258
|
+
const threadId = typeof request.thread_id === 'string' && request.thread_id !== ''
|
|
259
|
+
? request.thread_id
|
|
260
|
+
: undefined;
|
|
261
|
+
const call = {
|
|
262
|
+
label,
|
|
263
|
+
prompt,
|
|
264
|
+
...(model === undefined ? {} : { model }),
|
|
265
|
+
...(effort === undefined ? {} : { reasoningEffort: effort }),
|
|
266
|
+
...(permissionMode === undefined ? {} : { permissionMode }),
|
|
267
|
+
...(threadMode === undefined ? {} : { threadMode }),
|
|
268
|
+
...(threadId === undefined ? {} : { threadId }),
|
|
269
|
+
...(cwd === undefined ? {} : { cwd }),
|
|
270
|
+
...(images === undefined || images.length === 0 ? {} : { images }),
|
|
271
|
+
...(outputSchema === undefined ? {} : { outputSchema }),
|
|
272
|
+
...(timeoutMs === undefined ? {} : { timeoutMs }),
|
|
273
|
+
};
|
|
274
|
+
if (options.backgroundEnabled && request.run_in_background === true) {
|
|
275
|
+
return { kind: 'background', jobId: options.startBackground(call) };
|
|
276
|
+
}
|
|
277
|
+
// The runner owns how a thread id reaches the model: it appends the marker
|
|
278
|
+
// to the text, so a background job's collected result carries the id too.
|
|
279
|
+
const { text, blocks } = await options.run({ ...call, signal: exec.signal });
|
|
280
|
+
return { content: blocks ?? [{ type: 'text', text }] };
|
|
281
|
+
},
|
|
282
|
+
};
|
|
283
|
+
}
|
|
284
|
+
/** Whether a tool result carries content blocks. */
|
|
285
|
+
function isContentResult(value) {
|
|
286
|
+
return typeof value === 'object' && value !== null
|
|
287
|
+
&& Array.isArray(value.content);
|
|
288
|
+
}
|
|
289
|
+
/** Whether a tool result is the background handle shape. */
|
|
290
|
+
function isBackgroundHandle(value) {
|
|
291
|
+
return typeof value === 'object' && value !== null
|
|
292
|
+
&& value.kind === 'background'
|
|
293
|
+
&& typeof value.jobId === 'string';
|
|
294
|
+
}
|
|
295
|
+
//# sourceMappingURL=tool.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tool.js","sourceRoot":"","sources":["../src/tool.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAyEH;;;;;;;GAOG;AACH,MAAM,UAAU,sBAAsB,CACpC,UAA2C;IAE3C,MAAM,KAAK,GAA0B;QACnC,WAAW,EAAE,iBAAiB,EAAE,OAAO,EAAE,gBAAgB,EAAE,0CAA0C;KACtG,CAAA;IACD,IAAI,U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,MAAM,EAAE,IAAI,EAAE,CAAC,EAAE,CAAA;QACxD,CAAC;KACF,CAAA;AACH,CAAC;AAED,oDAAoD;AACpD,SAAS,eAAe,CAAC,KAAc;IACrC,OAAO,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,KAAK,IAAI;WAC7C,KAAK,CAAC,OAAO,CAAE,KAA+B,CAAC,OAAO,CAAC,CAAA;AAC9D,CAAC;AAED,4DAA4D;AAC5D,SAAS,kBAAkB,CAAC,KAAc;IACxC,OAAO,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,KAAK,IAAI;WAC5C,KAA4B,CAAC,IAAI,KAAK,YAAY;WACnD,OAAQ,KAA6B,CAAC,KAAK,KAAK,QAAQ,CAAA;AAC/D,CAAC"}
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The `codex exec` command line, built and run.
|
|
3
|
+
*
|
|
4
|
+
* This module is deliberately free of harness types: the whole probe rests on
|
|
5
|
+
* whether a plugin can register a subagent provider at all, so the part that
|
|
6
|
+
* talks to Codex stays independently testable. It also keeps the plugin free of
|
|
7
|
+
* runtime dependencies — the failure mode we are looking for is the provider
|
|
8
|
+
* chain, not module resolution.
|
|
9
|
+
*
|
|
10
|
+
* @module dsh-subagent-codex-pro/codex-exec
|
|
11
|
+
*/
|
|
12
|
+
/** Sandbox levels this runner accepts, matching `codex exec --sandbox`. */
|
|
13
|
+
export type CodexSandboxMode = 'read-only' | 'workspace-write' | 'danger-full-access';
|
|
14
|
+
/** Everything one delegation needs. */
|
|
15
|
+
export interface CodexExecOptions {
|
|
16
|
+
/** Working directory for the child. */
|
|
17
|
+
readonly cwd: string;
|
|
18
|
+
/** The prompt, delivered on stdin. */
|
|
19
|
+
readonly prompt: string;
|
|
20
|
+
/** File `codex exec` writes its final message to. */
|
|
21
|
+
readonly outputFile: string;
|
|
22
|
+
/** Model id; omitted leaves the CLI's own configuration in charge. */
|
|
23
|
+
readonly model?: string;
|
|
24
|
+
/**
|
|
25
|
+
* Reasoning effort, passed as `model_reasoning_effort`.
|
|
26
|
+
*
|
|
27
|
+
* This is the whole point of the probe: the official provider cannot carry it,
|
|
28
|
+
* because it speaks the app-server protocol and never populates the field.
|
|
29
|
+
*/
|
|
30
|
+
readonly reasoningEffort?: string;
|
|
31
|
+
/** Sandbox mode; omitted leaves the CLI's own configuration in charge. */
|
|
32
|
+
readonly sandbox?: CodexSandboxMode;
|
|
33
|
+
/** Skip approvals and sandboxing entirely. Mutually exclusive with `sandbox` in practice. */
|
|
34
|
+
readonly bypassApprovals?: boolean;
|
|
35
|
+
/** Extra environment entries layered over the inherited environment. */
|
|
36
|
+
readonly env?: Readonly<Record<string, string>>;
|
|
37
|
+
}
|
|
38
|
+
/** What one run produced. */
|
|
39
|
+
export interface CodexExecOutcome {
|
|
40
|
+
/** The child's final message, or its standard output when no file was written. */
|
|
41
|
+
readonly text: string;
|
|
42
|
+
/** Exit status, for callers that want to distinguish failure from empty output. */
|
|
43
|
+
readonly code: number | null;
|
|
44
|
+
/** Standard error, kept for diagnostics. */
|
|
45
|
+
readonly stderr: string;
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* Build the argv for one run.
|
|
49
|
+
*
|
|
50
|
+
* The prompt goes on stdin (`-`) rather than argv: delegated prompts are long and
|
|
51
|
+
* routinely contain quotes, newlines, and shell metacharacters.
|
|
52
|
+
*
|
|
53
|
+
* @param options - the run's inputs.
|
|
54
|
+
* @returns the argv to spawn, without the program name.
|
|
55
|
+
*/
|
|
56
|
+
export declare function buildCodexExecArgv(options: CodexExecOptions): string[];
|
|
57
|
+
/** The slice of `node:child_process` this module needs, so tests can supply their own. */
|
|
58
|
+
export interface SpawnLike {
|
|
59
|
+
(command: string, args: readonly string[], options: {
|
|
60
|
+
cwd: string;
|
|
61
|
+
env: NodeJS.ProcessEnv;
|
|
62
|
+
stdio: readonly ['pipe', 'pipe', 'pipe'];
|
|
63
|
+
}): {
|
|
64
|
+
stdin: {
|
|
65
|
+
end(data: string): void;
|
|
66
|
+
} | null;
|
|
67
|
+
stdout: {
|
|
68
|
+
on(event: 'data', listener: (chunk: Buffer) => void): void;
|
|
69
|
+
} | null;
|
|
70
|
+
stderr: {
|
|
71
|
+
on(event: 'data', listener: (chunk: Buffer) => void): void;
|
|
72
|
+
} | null;
|
|
73
|
+
on(event: 'error', listener: (error: Error) => void): void;
|
|
74
|
+
on(event: 'close', listener: (code: number | null) => void): void;
|
|
75
|
+
kill(signal?: NodeJS.Signals): boolean;
|
|
76
|
+
};
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* Run one `codex exec` and collect its final message.
|
|
80
|
+
*
|
|
81
|
+
* @param command - the Codex executable.
|
|
82
|
+
* @param options - the run's inputs, plus the output file to read back.
|
|
83
|
+
* @param spawn - the spawn implementation to use.
|
|
84
|
+
* @param readOutput - reads the output file; returns `undefined` when absent.
|
|
85
|
+
* @returns the child's answer and status.
|
|
86
|
+
*/
|
|
87
|
+
export declare function runCodexExec(command: string, options: CodexExecOptions, spawn: SpawnLike, readOutput: (path: string) => string | undefined): Promise<CodexExecOutcome>;
|
|
88
|
+
//# sourceMappingURL=codex-exec.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"codex-exec.d.ts","sourceRoot":"","sources":["../../src/codex-exec.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,2EAA2E;AAC3E,MAAM,MAAM,gBAAgB,GAAG,WAAW,GAAG,iBAAiB,GAAG,oBAAoB,CAAA;AAErF,uCAAuC;AACvC,MAAM,WAAW,gBAAgB;IAC/B,uCAAuC;IACvC,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAA;IACpB,sCAAsC;IACtC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;IACvB,qDAAqD;IACrD,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAA;IAC3B,sEAAsE;IACtE,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAA;IAC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Q,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,GAAG,IAAI,CAAA;SAAE,GAAG,IAAI,CAAA;QAC7E,EAAE,CAAC,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI,GAAG,IAAI,CAAA;QAC1D,EAAE,CAAC,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,KAAK,IAAI,GAAG,IAAI,CAAA;QACjE,IAAI,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC,OAAO,GAAG,OAAO,CAAA;KACvC,CAAA;CACF;AAED;;;;;;;;GAQG;AACH,wBAAsB,YAAY,CAChC,OAAO,EAAE,MAAM,EACf,OAAO,EAAE,gBAAgB,EACzB,KAAK,EAAE,SAAS,EAChB,UAAU,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,MAAM,GAAG,SAAS,GAC/C,OAAO,CAAC,gBAAgB,CAAC,CAuB3B"}
|
|
@@ -0,0 +1,179 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The harness shapes this probe needs, declared locally.
|
|
3
|
+
*
|
|
4
|
+
* The plugin imports nothing from `@deepseek-ai/*` at runtime — that is a
|
|
5
|
+
* deliberate property, so a failure can only mean the wiring and never module
|
|
6
|
+
* resolution. These are structural types mirroring the harness contracts; they
|
|
7
|
+
* are erased at build time.
|
|
8
|
+
*
|
|
9
|
+
* The tool registration shape mirrors what the LCU plugin does, which is the
|
|
10
|
+
* proven path for a plugin that registers its own model-facing tools.
|
|
11
|
+
*
|
|
12
|
+
* @module dsh-subagent-codex-pro/dsh-types
|
|
13
|
+
*/
|
|
14
|
+
/** A content block on a delegated prompt. */
|
|
15
|
+
export interface TextBlock {
|
|
16
|
+
readonly type: 'text';
|
|
17
|
+
readonly text: string;
|
|
18
|
+
}
|
|
19
|
+
/** Anything else a prompt may carry; the probe only reads text. */
|
|
20
|
+
export interface OtherBlock {
|
|
21
|
+
readonly type: string;
|
|
22
|
+
}
|
|
23
|
+
/** The per-call choices the harness can hand a provider. */
|
|
24
|
+
export interface AgentOptionsLike {
|
|
25
|
+
readonly provider?: string;
|
|
26
|
+
readonly model?: string;
|
|
27
|
+
/** The field `@deepseek-ai/dsh-subagent-codex` has no way to forward. */
|
|
28
|
+
readonly reasoningEffort?: string;
|
|
29
|
+
readonly maxTokens?: number;
|
|
30
|
+
}
|
|
31
|
+
/** What one delegation asks for. */
|
|
32
|
+
export interface SubagentStartRequestLike {
|
|
33
|
+
readonly prompt: readonly (TextBlock | OtherBlock)[];
|
|
34
|
+
readonly parent: AgentLike;
|
|
35
|
+
readonly signal: AbortSignal;
|
|
36
|
+
/**
|
|
37
|
+
* A working directory the shared subagent service selected for this run, when
|
|
38
|
+
* it resolved one (DSH 0.2.1 and later). Older dispatches omit it, and the
|
|
39
|
+
* provider then falls back to the parent session's directory.
|
|
40
|
+
*/
|
|
41
|
+
readonly cwd?: string;
|
|
42
|
+
readonly agentOptions?: AgentOptionsLike;
|
|
43
|
+
/**
|
|
44
|
+
* A JSON Schema the child's answer must conform to, when the tool row carries
|
|
45
|
+
* one and this provider declared the capability for it.
|
|
46
|
+
*/
|
|
47
|
+
readonly outputSchema?: Record<string, unknown>;
|
|
48
|
+
}
|
|
49
|
+
/** What a finished run reports. */
|
|
50
|
+
export interface SubagentResultLike {
|
|
51
|
+
readonly output: readonly TextBlock[];
|
|
52
|
+
readonly structured?: unknown;
|
|
53
|
+
readonly diagnostic?: string;
|
|
54
|
+
readonly stopReason: 'completed' | 'aborted' | 'error' | 'max-tokens' | 'refusal';
|
|
55
|
+
}
|
|
56
|
+
/** The handle the registry publishes for one child. */
|
|
57
|
+
export interface SubagentRunLike {
|
|
58
|
+
readonly id: string;
|
|
59
|
+
readonly localAgent: undefined;
|
|
60
|
+
readonly result: Promise<SubagentResultLike>;
|
|
61
|
+
dispose(): Promise<void>;
|
|
62
|
+
}
|
|
63
|
+
/** The provider contract `ctx.subagents.registerProvider` accepts. */
|
|
64
|
+
export interface SubagentProviderLike {
|
|
65
|
+
readonly name: string;
|
|
66
|
+
readonly capabilities: {
|
|
67
|
+
readonly agentOptions: boolean;
|
|
68
|
+
readonly agentPreset: boolean;
|
|
69
|
+
readonly outputSchema: boolean;
|
|
70
|
+
readonly depthLimit: boolean;
|
|
71
|
+
};
|
|
72
|
+
readonly inheritsParentContext: boolean;
|
|
73
|
+
start(request: SubagentStartRequestLike): Promise<SubagentRunLike>;
|
|
74
|
+
}
|
|
75
|
+
/**
|
|
76
|
+
* A model-facing tool definition.
|
|
77
|
+
*
|
|
78
|
+
* `parameters` is a whole JSON Schema object (`type: "object"`); the harness
|
|
79
|
+
* rejects a descriptor map with `schema must be a JSON Schema of 'type:
|
|
80
|
+
* "object"'`.
|
|
81
|
+
*/
|
|
82
|
+
export interface ToolDefinitionLike {
|
|
83
|
+
readonly name: string;
|
|
84
|
+
readonly description: string;
|
|
85
|
+
readonly parameters: Record<string, unknown>;
|
|
86
|
+
readonly output: {
|
|
87
|
+
readonly schema: Record<string, unknown>;
|
|
88
|
+
render(args: unknown, value: unknown): readonly TextBlock[];
|
|
89
|
+
};
|
|
90
|
+
execute(args: unknown, exec: {
|
|
91
|
+
readonly signal: AbortSignal;
|
|
92
|
+
}): Promise<unknown>;
|
|
93
|
+
}
|
|
94
|
+
/** The Agent-side registration surface one delegation tool needs. */
|
|
95
|
+
export interface AgentLike {
|
|
96
|
+
readonly id: string;
|
|
97
|
+
readonly session: {
|
|
98
|
+
readonly header: {
|
|
99
|
+
readonly cwd?: string;
|
|
100
|
+
};
|
|
101
|
+
};
|
|
102
|
+
readonly ctx: {
|
|
103
|
+
readonly tools: {
|
|
104
|
+
register(definition: ToolDefinitionLike): () => void;
|
|
105
|
+
};
|
|
106
|
+
readonly systemPrompt: {
|
|
107
|
+
section(section: {
|
|
108
|
+
name: string;
|
|
109
|
+
order?: number;
|
|
110
|
+
text: string;
|
|
111
|
+
}): () => void;
|
|
112
|
+
};
|
|
113
|
+
};
|
|
114
|
+
}
|
|
115
|
+
import type { JobOutcomeLike } from './jobs.ts';
|
|
116
|
+
/**
|
|
117
|
+
* One background job's specification, as the jobs service accepts it.
|
|
118
|
+
*
|
|
119
|
+
* `run` is called once, when the job starts, and returns the two things the
|
|
120
|
+
* service needs: how to cancel the work, and a promise that settles when it is
|
|
121
|
+
* done. Whatever that promise resolves to becomes the job's output, which
|
|
122
|
+
* `job_output` then reads.
|
|
123
|
+
*/
|
|
124
|
+
export interface JobSpecLike {
|
|
125
|
+
/** A short category for display, such as `subagent`. */
|
|
126
|
+
readonly kind: string;
|
|
127
|
+
/** A human-readable label. */
|
|
128
|
+
readonly label: string;
|
|
129
|
+
/** The session that owns the job. */
|
|
130
|
+
readonly owner: string;
|
|
131
|
+
run(handle: {
|
|
132
|
+
/** Append one progress chunk to the job's output ring. */
|
|
133
|
+
append(text: string, options?: {
|
|
134
|
+
channel?: string;
|
|
135
|
+
}): void;
|
|
136
|
+
/** Replace the live progress line. */
|
|
137
|
+
updateProgress(line: string): void;
|
|
138
|
+
}): {
|
|
139
|
+
cancel(reason?: string): void;
|
|
140
|
+
/**
|
|
141
|
+
* Settles with a `JobOutcome` record — `{ status, detail?, result? }` — and
|
|
142
|
+
* must never reject. A bare value here fails validation on every read of the
|
|
143
|
+
* job, not just this one.
|
|
144
|
+
*/
|
|
145
|
+
done: Promise<JobOutcomeLike>;
|
|
146
|
+
};
|
|
147
|
+
}
|
|
148
|
+
/** The jobs service. */
|
|
149
|
+
export interface JobsServiceLike {
|
|
150
|
+
/**
|
|
151
|
+
* Start one background job.
|
|
152
|
+
*
|
|
153
|
+
* @param spec - the job's identity and its work.
|
|
154
|
+
* @returns the job id the model collects with `job_output`.
|
|
155
|
+
*/
|
|
156
|
+
start(spec: JobSpecLike): string;
|
|
157
|
+
}
|
|
158
|
+
/** The slice of the Cordis context this plugin uses. */
|
|
159
|
+
export interface Context {
|
|
160
|
+
/** Optional service lookup, as the harness itself uses it. */
|
|
161
|
+
get(service: string): unknown;
|
|
162
|
+
on(event: 'agent/created', listener: (payload: {
|
|
163
|
+
agent: AgentLike;
|
|
164
|
+
signal: AbortSignal;
|
|
165
|
+
}) => void): () => void;
|
|
166
|
+
on(event: 'agent-preset/selected', listener: (sessionId: string, presetId: string) => void): () => void;
|
|
167
|
+
readonly logger: {
|
|
168
|
+
info(message: string): void;
|
|
169
|
+
warn(message: string): void;
|
|
170
|
+
};
|
|
171
|
+
readonly subagents: {
|
|
172
|
+
registerProvider(provider: SubagentProviderLike): () => void;
|
|
173
|
+
/** Present in the service contract; used only by the plugin's diagnostics. */
|
|
174
|
+
list?(): string[];
|
|
175
|
+
/** Present in the service contract; used only by the plugin's diagnostics. */
|
|
176
|
+
getProvider?(name: string): unknown;
|
|
177
|
+
};
|
|
178
|
+
}
|
|
179
|
+
//# sourceMappingURL=dsh-types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dsh-types.d.ts","sourceRoot":"","sources":["../../src/dsh-types.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,6CAA6C;AAC7C,MAAM,WAAW,SAAS;IACxB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;IACrB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;CACtB;AAED,mEAAmE;AACnE,MAAM,WAAW,UAAU;IACzB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;CACtB;AAED,4DAA4D;AAC5D,MAAM,WAAW,gBAAgB;IAC/B,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAA;IAC1B,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAA;IACvB,yEAAyE;IACzE,QAAQ,CAAC,eAAe,CAAC,EAAE,MAAM,CAAA;IACjC,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAA;CAC5B;AAED,oCAAoC;AACpC,MAAM,WAAW,wBAAwB;IACvC,QAAQ,CAAC,MAAM,EAAE,S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