@namzu/sdk 58.1.1 → 60.0.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 +124 -0
- package/dist/account/binding.d.ts +20 -0
- package/dist/account/binding.d.ts.map +1 -0
- package/dist/account/binding.js +27 -0
- package/dist/account/binding.js.map +1 -0
- package/dist/account/index.d.ts +9 -0
- package/dist/account/index.d.ts.map +1 -0
- package/dist/account/index.js +5 -0
- package/dist/account/index.js.map +1 -0
- package/dist/account/lock.d.ts +33 -0
- package/dist/account/lock.d.ts.map +1 -0
- package/dist/account/lock.js +170 -0
- package/dist/account/lock.js.map +1 -0
- package/dist/account/registry.d.ts +21 -0
- package/dist/account/registry.d.ts.map +1 -0
- package/dist/account/registry.js +340 -0
- package/dist/account/registry.js.map +1 -0
- package/dist/account/types.d.ts +124 -0
- package/dist/account/types.d.ts.map +1 -0
- package/dist/account/types.js +35 -0
- package/dist/account/types.js.map +1 -0
- package/dist/compaction/context-window.d.ts +53 -0
- package/dist/compaction/context-window.d.ts.map +1 -1
- package/dist/compaction/context-window.js +141 -2
- package/dist/compaction/context-window.js.map +1 -1
- package/dist/execution/workflow/index.d.ts +3 -1
- package/dist/execution/workflow/index.d.ts.map +1 -1
- package/dist/execution/workflow/index.js +2 -1
- package/dist/execution/workflow/index.js.map +1 -1
- package/dist/execution/workflow/journal.d.ts +24 -4
- package/dist/execution/workflow/journal.d.ts.map +1 -1
- package/dist/execution/workflow/journal.js +131 -9
- package/dist/execution/workflow/journal.js.map +1 -1
- package/dist/execution/workflow/prelude.d.ts +2 -0
- package/dist/execution/workflow/prelude.d.ts.map +1 -1
- package/dist/execution/workflow/prelude.js +49 -8
- package/dist/execution/workflow/prelude.js.map +1 -1
- package/dist/execution/workflow/resume.d.ts +59 -0
- package/dist/execution/workflow/resume.d.ts.map +1 -0
- package/dist/execution/workflow/resume.js +273 -0
- package/dist/execution/workflow/resume.js.map +1 -0
- package/dist/execution/workflow/runtime.d.ts.map +1 -1
- package/dist/execution/workflow/runtime.js +112 -8
- package/dist/execution/workflow/runtime.js.map +1 -1
- package/dist/execution/workflow/types.d.ts +105 -1
- package/dist/execution/workflow/types.d.ts.map +1 -1
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4 -0
- package/dist/index.js.map +1 -1
- package/dist/pals/communication/ingress-schema.d.ts +38 -38
- package/dist/peers/record.d.ts +98 -0
- package/dist/peers/record.d.ts.map +1 -1
- package/dist/peers/record.js +17 -0
- package/dist/peers/record.js.map +1 -1
- package/dist/peers/registry.d.ts.map +1 -1
- package/dist/peers/registry.js +2 -2
- package/dist/peers/registry.js.map +1 -1
- package/dist/plugin/compat.d.ts +24 -0
- package/dist/plugin/compat.d.ts.map +1 -0
- package/dist/plugin/compat.js +149 -0
- package/dist/plugin/compat.js.map +1 -0
- package/dist/plugin/loader.d.ts +2 -1
- package/dist/plugin/loader.d.ts.map +1 -1
- package/dist/plugin/loader.js +6 -0
- package/dist/plugin/loader.js.map +1 -1
- package/dist/pricing/index.d.ts.map +1 -1
- package/dist/pricing/index.js +2 -1
- package/dist/pricing/index.js.map +1 -1
- package/dist/process/kill-tree.d.ts +44 -0
- package/dist/process/kill-tree.d.ts.map +1 -1
- package/dist/process/kill-tree.js +102 -4
- package/dist/process/kill-tree.js.map +1 -1
- package/dist/prompt/coding-agent-doctrine.d.ts +1 -1
- package/dist/prompt/coding-agent-doctrine.d.ts.map +1 -1
- package/dist/prompt/coding-agent-doctrine.js +9 -1
- package/dist/prompt/coding-agent-doctrine.js.map +1 -1
- package/dist/provider/errors.d.ts.map +1 -1
- package/dist/provider/errors.js +25 -2
- package/dist/provider/errors.js.map +1 -1
- package/dist/provider/model-window-suffix.d.ts +18 -0
- package/dist/provider/model-window-suffix.d.ts.map +1 -0
- package/dist/provider/model-window-suffix.js +77 -0
- package/dist/provider/model-window-suffix.js.map +1 -0
- package/dist/provider/token-budget.d.ts.map +1 -1
- package/dist/provider/token-budget.js +9 -1
- package/dist/provider/token-budget.js.map +1 -1
- package/dist/public-runtime.d.ts +6 -3
- package/dist/public-runtime.d.ts.map +1 -1
- package/dist/public-runtime.js +6 -4
- package/dist/public-runtime.js.map +1 -1
- package/dist/public-types.d.ts +3 -0
- package/dist/public-types.d.ts.map +1 -1
- package/dist/registry/command/kernel-commands.d.ts +1 -4
- package/dist/registry/command/kernel-commands.d.ts.map +1 -1
- package/dist/registry/command/kernel-commands.js +0 -28
- package/dist/registry/command/kernel-commands.js.map +1 -1
- package/dist/runtime/jobs/awaited-jobs.d.ts +6 -0
- package/dist/runtime/jobs/awaited-jobs.d.ts.map +1 -1
- package/dist/runtime/jobs/awaited-jobs.js +11 -0
- package/dist/runtime/jobs/awaited-jobs.js.map +1 -1
- package/dist/runtime/jobs/host-exit-finalizer.d.ts +20 -0
- package/dist/runtime/jobs/host-exit-finalizer.d.ts.map +1 -0
- package/dist/runtime/jobs/host-exit-finalizer.js +57 -0
- package/dist/runtime/jobs/host-exit-finalizer.js.map +1 -0
- package/dist/runtime/jobs/liveness.d.ts +67 -0
- package/dist/runtime/jobs/liveness.d.ts.map +1 -0
- package/dist/runtime/jobs/liveness.js +94 -0
- package/dist/runtime/jobs/liveness.js.map +1 -0
- package/dist/runtime/jobs/registry.d.ts +21 -0
- package/dist/runtime/jobs/registry.d.ts.map +1 -1
- package/dist/runtime/jobs/registry.js +104 -2
- package/dist/runtime/jobs/registry.js.map +1 -1
- package/dist/runtime/jobs/wake-budget.d.ts +35 -0
- package/dist/runtime/jobs/wake-budget.d.ts.map +1 -0
- package/dist/runtime/jobs/wake-budget.js +48 -0
- package/dist/runtime/jobs/wake-budget.js.map +1 -0
- package/dist/runtime/query/detached-calls.d.ts +65 -0
- package/dist/runtime/query/detached-calls.d.ts.map +1 -0
- package/dist/runtime/query/detached-calls.js +116 -0
- package/dist/runtime/query/detached-calls.js.map +1 -0
- package/dist/runtime/query/executor.d.ts +11 -3
- package/dist/runtime/query/executor.d.ts.map +1 -1
- package/dist/runtime/query/executor.js +100 -8
- package/dist/runtime/query/executor.js.map +1 -1
- package/dist/runtime/query/index.d.ts +20 -0
- package/dist/runtime/query/index.d.ts.map +1 -1
- package/dist/runtime/query/index.js +31 -5
- package/dist/runtime/query/index.js.map +1 -1
- package/dist/runtime/query/iteration/outstanding-work.d.ts.map +1 -1
- package/dist/runtime/query/iteration/outstanding-work.js +11 -3
- package/dist/runtime/query/iteration/outstanding-work.js.map +1 -1
- package/dist/runtime/query/iteration/phases/context.d.ts +7 -0
- package/dist/runtime/query/iteration/phases/context.d.ts.map +1 -1
- package/dist/runtime/query/iteration/phases/context.js.map +1 -1
- package/dist/runtime/query/iteration/phases/tool-review.d.ts.map +1 -1
- package/dist/runtime/query/iteration/phases/tool-review.js +63 -1
- package/dist/runtime/query/iteration/phases/tool-review.js.map +1 -1
- package/dist/runtime/query/session-storage.d.ts.map +1 -1
- package/dist/runtime/query/session-storage.js +8 -3
- package/dist/runtime/query/session-storage.js.map +1 -1
- package/dist/runtime/query/steering.d.ts +29 -3
- package/dist/runtime/query/steering.d.ts.map +1 -1
- package/dist/runtime/query/steering.js +58 -3
- package/dist/runtime/query/steering.js.map +1 -1
- package/dist/runtime/query/tooling.d.ts +1 -0
- package/dist/runtime/query/tooling.d.ts.map +1 -1
- package/dist/runtime/query/tooling.js +1 -0
- package/dist/runtime/query/tooling.js.map +1 -1
- package/dist/runtime/system-events.d.ts +5 -0
- package/dist/runtime/system-events.d.ts.map +1 -1
- package/dist/runtime/system-events.js +7 -1
- package/dist/runtime/system-events.js.map +1 -1
- package/dist/sandbox/denial.d.ts +11 -0
- package/dist/sandbox/denial.d.ts.map +1 -0
- package/dist/sandbox/denial.js +61 -0
- package/dist/sandbox/denial.js.map +1 -0
- package/dist/sandbox/file-walk-program.d.ts.map +1 -1
- package/dist/sandbox/file-walk-program.js +31 -13
- package/dist/sandbox/file-walk-program.js.map +1 -1
- package/dist/sandbox/file-walk.d.ts +2 -0
- package/dist/sandbox/file-walk.d.ts.map +1 -1
- package/dist/sandbox/file-walk.js +64 -13
- package/dist/sandbox/file-walk.js.map +1 -1
- package/dist/sandbox/ignore-matcher.d.ts +30 -0
- package/dist/sandbox/ignore-matcher.d.ts.map +1 -0
- package/dist/sandbox/ignore-matcher.js +11 -0
- package/dist/sandbox/ignore-matcher.js.map +1 -0
- package/dist/sandbox/ignore-source.d.ts +26 -0
- package/dist/sandbox/ignore-source.d.ts.map +1 -0
- package/dist/sandbox/ignore-source.js +221 -0
- package/dist/sandbox/ignore-source.js.map +1 -0
- package/dist/sandbox/provider/local.d.ts.map +1 -1
- package/dist/sandbox/provider/local.js +11 -1
- package/dist/sandbox/provider/local.js.map +1 -1
- package/dist/scheduler/completion-inbox.d.ts.map +1 -1
- package/dist/scheduler/completion-inbox.js +1 -0
- package/dist/scheduler/completion-inbox.js.map +1 -1
- package/dist/session/log-hash.d.ts.map +1 -1
- package/dist/session/log-hash.js +18 -1
- package/dist/session/log-hash.js.map +1 -1
- package/dist/store/session-index/sqlite.d.ts.map +1 -1
- package/dist/store/session-index/sqlite.js +169 -16
- package/dist/store/session-index/sqlite.js.map +1 -1
- package/dist/tools/builtins/bash.d.ts.map +1 -1
- package/dist/tools/builtins/bash.js +10 -4
- package/dist/tools/builtins/bash.js.map +1 -1
- package/dist/tools/builtins/computer-use.d.ts +35 -0
- package/dist/tools/builtins/computer-use.d.ts.map +1 -1
- package/dist/tools/builtins/computer-use.js +512 -67
- package/dist/tools/builtins/computer-use.js.map +1 -1
- package/dist/tools/builtins/glob.d.ts +1 -0
- package/dist/tools/builtins/glob.d.ts.map +1 -1
- package/dist/tools/builtins/glob.js +65 -28
- package/dist/tools/builtins/glob.js.map +1 -1
- package/dist/tools/builtins/grep.d.ts +2 -0
- package/dist/tools/builtins/grep.d.ts.map +1 -1
- package/dist/tools/builtins/grep.js +94 -40
- package/dist/tools/builtins/grep.js.map +1 -1
- package/dist/tools/builtins/job.d.ts +1 -1
- package/dist/tools/builtins/job.d.ts.map +1 -1
- package/dist/tools/builtins/job.js +34 -7
- package/dist/tools/builtins/job.js.map +1 -1
- package/dist/tools/builtins/search-support.d.ts +44 -0
- package/dist/tools/builtins/search-support.d.ts.map +1 -0
- package/dist/tools/builtins/search-support.js +89 -0
- package/dist/tools/builtins/search-support.js.map +1 -0
- package/dist/tools/builtins/wait-for-job-bounds.d.ts +2 -0
- package/dist/tools/builtins/wait-for-job-bounds.d.ts.map +1 -1
- package/dist/tools/builtins/wait-for-job-bounds.js +3 -1
- package/dist/tools/builtins/wait-for-job-bounds.js.map +1 -1
- package/dist/tools/builtins/wait-for-job.d.ts +1 -1
- package/dist/tools/builtins/wait-for-job.d.ts.map +1 -1
- package/dist/tools/builtins/wait-for-job.js +13 -2
- package/dist/tools/builtins/wait-for-job.js.map +1 -1
- package/dist/tools/command-shell.d.ts.map +1 -1
- package/dist/tools/command-shell.js +14 -5
- package/dist/tools/command-shell.js.map +1 -1
- package/dist/types/computer-use/index.d.ts +129 -13
- package/dist/types/computer-use/index.d.ts.map +1 -1
- package/dist/types/computer-use/index.js.map +1 -1
- package/dist/types/errors/catalog.d.ts.map +1 -1
- package/dist/types/errors/catalog.js +6 -0
- package/dist/types/errors/catalog.js.map +1 -1
- package/dist/types/plugin/index.d.ts +24 -0
- package/dist/types/plugin/index.d.ts.map +1 -1
- package/dist/types/plugin/index.js +4 -0
- package/dist/types/plugin/index.js.map +1 -1
- package/dist/types/provider/errors.d.ts +7 -0
- package/dist/types/provider/errors.d.ts.map +1 -1
- package/dist/types/provider/errors.js +27 -3
- package/dist/types/provider/errors.js.map +1 -1
- package/dist/types/sandbox/index.d.ts +38 -1
- package/dist/types/sandbox/index.d.ts.map +1 -1
- package/dist/types/sandbox/index.js.map +1 -1
- package/dist/types/session/records.d.ts +479 -1
- package/dist/types/session/records.d.ts.map +1 -1
- package/dist/types/session/records.js +45 -1
- package/dist/types/session/records.js.map +1 -1
- package/dist/types/tool/index.d.ts +30 -0
- package/dist/types/tool/index.d.ts.map +1 -1
- package/dist/types/tool/index.js.map +1 -1
- package/dist/types/tool/presentation.d.ts +8 -0
- package/dist/types/tool/presentation.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/account/binding.ts +43 -0
- package/src/account/index.ts +32 -0
- package/src/account/lock.ts +184 -0
- package/src/account/registry.ts +413 -0
- package/src/account/types.ts +137 -0
- package/src/compaction/context-window.ts +163 -2
- package/src/execution/workflow/index.ts +14 -1
- package/src/execution/workflow/journal.ts +161 -11
- package/src/execution/workflow/prelude.ts +51 -8
- package/src/execution/workflow/resume.ts +313 -0
- package/src/execution/workflow/runtime.ts +127 -9
- package/src/execution/workflow/types.ts +109 -1
- package/src/index.ts +17 -0
- package/src/peers/record.ts +18 -0
- package/src/peers/registry.ts +2 -2
- package/src/plugin/compat.ts +173 -0
- package/src/plugin/loader.ts +7 -1
- package/src/pricing/index.ts +2 -1
- package/src/process/kill-tree.ts +106 -4
- package/src/prompt/coding-agent-doctrine.ts +9 -1
- package/src/provider/errors.ts +27 -1
- package/src/provider/model-window-suffix.ts +84 -0
- package/src/provider/token-budget.ts +9 -3
- package/src/public-runtime.ts +38 -2
- package/src/public-types.ts +16 -0
- package/src/registry/command/kernel-commands.ts +1 -32
- package/src/runtime/jobs/awaited-jobs.ts +11 -0
- package/src/runtime/jobs/host-exit-finalizer.ts +67 -0
- package/src/runtime/jobs/liveness.ts +144 -0
- package/src/runtime/jobs/registry.ts +114 -2
- package/src/runtime/jobs/wake-budget.ts +55 -0
- package/src/runtime/query/detached-calls.ts +135 -0
- package/src/runtime/query/executor.ts +102 -12
- package/src/runtime/query/index.ts +50 -7
- package/src/runtime/query/iteration/outstanding-work.ts +12 -3
- package/src/runtime/query/iteration/phases/context.ts +7 -0
- package/src/runtime/query/iteration/phases/tool-review.ts +73 -8
- package/src/runtime/query/session-storage.ts +8 -3
- package/src/runtime/query/steering.ts +77 -6
- package/src/runtime/query/tooling.ts +2 -0
- package/src/runtime/system-events.ts +12 -1
- package/src/sandbox/denial.ts +79 -0
- package/src/sandbox/file-walk-program.ts +32 -13
- package/src/sandbox/file-walk.ts +75 -12
- package/src/sandbox/ignore-matcher.ts +46 -0
- package/src/sandbox/ignore-source.ts +220 -0
- package/src/sandbox/provider/local.ts +11 -1
- package/src/scheduler/completion-inbox.ts +1 -0
- package/src/session/log-hash.ts +21 -0
- package/src/store/session-index/sqlite.ts +171 -16
- package/src/tools/builtins/bash.ts +11 -4
- package/src/tools/builtins/computer-use.ts +593 -68
- package/src/tools/builtins/glob.ts +79 -32
- package/src/tools/builtins/grep.ts +107 -43
- package/src/tools/builtins/job.ts +42 -12
- package/src/tools/builtins/search-support.ts +107 -0
- package/src/tools/builtins/wait-for-job-bounds.ts +5 -1
- package/src/tools/builtins/wait-for-job.ts +14 -2
- package/src/tools/command-shell.ts +13 -5
- package/src/types/computer-use/index.ts +157 -15
- package/src/types/errors/catalog.ts +6 -0
- package/src/types/plugin/index.ts +8 -0
- package/src/types/provider/errors.ts +40 -3
- package/src/types/sandbox/index.ts +40 -1
- package/src/types/session/records.ts +52 -2
- package/src/types/tool/index.ts +30 -0
- package/src/types/tool/presentation.ts +8 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"registry.js","sourceRoot":"","sources":["../../src/peers/registry.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAA;AACzC,OAAO,EACN,SAAS,EACT,SAAS,EACT,SAAS,EACT,QAAQ,EACR,YAAY,EACZ,WAAW,EACX,UAAU,EACV,UAAU,EACV,SAAS,GACT,MAAM,SAAS,CAAA;AAChB,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAA;AACnD,OAAO,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAA;AAC/C,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAA;AACtC,OAAO,EAAmB,gBAAgB,EAAE,MAAM,aAAa,CAAA;
|
|
1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CAAC;QACD,gBAAgB,CAAC,OAAO,CAAC,WAAW,EAAE,MAAM,CAAC,SAAS,EAAE,OAAO,CAAC,GAAG,CAAC,CAAA;QACpE,wBAAwB,CAAC,MAAM,CAAC,OAAO,EAAE,OAAO,CAAC,GAAG,CAAC,CAAA;IACtD,CAAC,CAAC,CACF,CAAA;IACD,OAAO,IAAI,CAAA;AACZ,CAAC"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import type { PluginManifest } from '../types/plugin/index.js';
|
|
2
|
+
/**
|
|
3
|
+
* Whether `version` satisfies `range`. Supports space-separated comparators
|
|
4
|
+
* that must all hold, `||` between alternatives, and the operators `>=`, `>`,
|
|
5
|
+
* `<=`, `<`, `=`, `^` and `~`. Returns undefined when the range cannot be read.
|
|
6
|
+
*/
|
|
7
|
+
export declare function versionSatisfies(versionText: string, range: string): boolean | undefined;
|
|
8
|
+
export interface PluginHostFacts {
|
|
9
|
+
/** The operating system, as `process.platform` names it. Default: this process. */
|
|
10
|
+
readonly platform?: string;
|
|
11
|
+
/** The Namzu runtime version. Default: this package's own version. */
|
|
12
|
+
readonly namzuVersion?: string;
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* Refuse a plugin that declares it does not support this platform or this
|
|
16
|
+
* Namzu version. The reason names the plugin, what it declares and what this
|
|
17
|
+
* machine is, so a person can act on it without reading the manifest.
|
|
18
|
+
*
|
|
19
|
+
* A runtime whose own version is unknown (`0.0.0`, the placeholder a bundle
|
|
20
|
+
* reports when it cannot read its package file) is not held against the range:
|
|
21
|
+
* refusing every plugin on a guess would be worse than admitting one.
|
|
22
|
+
*/
|
|
23
|
+
export declare function assertCompatible(manifest: PluginManifest, host: Required<PluginHostFacts>): void;
|
|
24
|
+
//# sourceMappingURL=compat.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"compat.d.ts","sourceRoot":"","sources":["../../src/plugin/compat.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAA;AAmG9D;;;;GAIG;AACH,wBAAgB,gBAAgB,CAAC,WAAW,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,OAAO,GAAG,SAAS,CA8BxF;AAED,MAAM,WAAW,eAAe;IAC/B,mFAAmF;IACnF,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAA;IAC1B,sEAAsE;IACtE,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,CAAA;CAC9B;AAED;;;;;;;;GAQG;AACH,wBAAgB,gBAAgB,CAAC,QAAQ,EAAE,cAAc,EAAE,IAAI,EAAE,QAAQ,CAAC,eAAe,CAAC,GAAG,IAAI,CAoBhG"}
|
|
@@ -0,0 +1,149 @@
|
|
|
1
|
+
const VERSION_PATTERN = /^v?(\d+)(?:\.(\d+|x|\*))?(?:\.(\d+|x|\*))?(?:-([0-9A-Za-z.-]+))?(?:\+.*)?$/i;
|
|
2
|
+
function parseVersion(text) {
|
|
3
|
+
const match = VERSION_PATTERN.exec(text.trim());
|
|
4
|
+
if (!match)
|
|
5
|
+
return undefined;
|
|
6
|
+
const part = (value) => value === undefined || value === 'x' || value === '*' ? 0 : Number(value);
|
|
7
|
+
const written = [match[1], match[2], match[3]].filter((p) => p !== undefined && p !== 'x' && p !== '*').length;
|
|
8
|
+
return {
|
|
9
|
+
triple: [Number(match[1]), part(match[2]), part(match[3])],
|
|
10
|
+
pre: match[4],
|
|
11
|
+
written,
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
function compareTriples(a, b) {
|
|
15
|
+
for (let i = 0; i < 3; i++) {
|
|
16
|
+
const diff = a[i] - b[i];
|
|
17
|
+
if (diff !== 0)
|
|
18
|
+
return diff;
|
|
19
|
+
}
|
|
20
|
+
return 0;
|
|
21
|
+
}
|
|
22
|
+
/** Full precedence: a release is above any prerelease of the same numbers. */
|
|
23
|
+
function compare(a, b) {
|
|
24
|
+
const order = compareTriples(a.triple, b.triple);
|
|
25
|
+
if (order !== 0)
|
|
26
|
+
return order;
|
|
27
|
+
if (a.pre === b.pre)
|
|
28
|
+
return 0;
|
|
29
|
+
if (a.pre === undefined)
|
|
30
|
+
return 1;
|
|
31
|
+
if (b.pre === undefined)
|
|
32
|
+
return -1;
|
|
33
|
+
return a.pre < b.pre ? -1 : 1;
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* The first version a `^` or `~` range excludes, from how many parts were
|
|
37
|
+
* written. `^1` and `~1` stop below 2.0.0; `~1.4` and `~1.4.2` below 1.5.0;
|
|
38
|
+
* `^0` below 1.0.0, `^0.2` below 0.3.0, `^0.0.3` below 0.0.4.
|
|
39
|
+
*/
|
|
40
|
+
function upperBound(operator, target) {
|
|
41
|
+
const [major, minor, patch] = target.triple;
|
|
42
|
+
if (operator === '~')
|
|
43
|
+
return target.written <= 1 ? [major + 1, 0, 0] : [major, minor + 1, 0];
|
|
44
|
+
if (major > 0 || target.written <= 1)
|
|
45
|
+
return [major + 1, 0, 0];
|
|
46
|
+
if (minor > 0 || target.written === 2)
|
|
47
|
+
return [0, minor + 1, 0];
|
|
48
|
+
return [0, 0, patch + 1];
|
|
49
|
+
}
|
|
50
|
+
/** One comparator such as `>=1.2.0`, `^2`, `~1.4` or `3.1.0`; undefined when unreadable. */
|
|
51
|
+
function satisfiesComparator(version, token) {
|
|
52
|
+
const op = /^(>=|<=|>|<|=|\^|~)?\s*(.+)$/.exec(token);
|
|
53
|
+
if (!op)
|
|
54
|
+
return undefined;
|
|
55
|
+
const operator = op[1] ?? '=';
|
|
56
|
+
const target = parseVersion(op[2]);
|
|
57
|
+
if (!target)
|
|
58
|
+
return undefined;
|
|
59
|
+
const order = compare(version, target);
|
|
60
|
+
switch (operator) {
|
|
61
|
+
case '>=':
|
|
62
|
+
return order >= 0;
|
|
63
|
+
case '<=':
|
|
64
|
+
return order <= 0;
|
|
65
|
+
case '>':
|
|
66
|
+
return order > 0;
|
|
67
|
+
case '<':
|
|
68
|
+
return order < 0;
|
|
69
|
+
case '^':
|
|
70
|
+
case '~':
|
|
71
|
+
// The upper bound is compared on the numbers alone, so a prerelease of the
|
|
72
|
+
// next major (`2.0.0-rc.1`) is not inside `^1`.
|
|
73
|
+
return order >= 0 && compareTriples(version.triple, upperBound(operator, target)) < 0;
|
|
74
|
+
default: {
|
|
75
|
+
// A bare `1` or `1.4` names a whole major or minor.
|
|
76
|
+
if (version.pre !== target.pre)
|
|
77
|
+
return false;
|
|
78
|
+
const written = op[2].replace(/^v/i, '').split(/[-+]/)[0];
|
|
79
|
+
const parts = written.split('.').filter((p) => p !== 'x' && p !== '*');
|
|
80
|
+
return parts.every((p, i) => Number(p) === version.triple[i]);
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
/**
|
|
85
|
+
* Whether `version` satisfies `range`. Supports space-separated comparators
|
|
86
|
+
* that must all hold, `||` between alternatives, and the operators `>=`, `>`,
|
|
87
|
+
* `<=`, `<`, `=`, `^` and `~`. Returns undefined when the range cannot be read.
|
|
88
|
+
*/
|
|
89
|
+
export function versionSatisfies(versionText, range) {
|
|
90
|
+
const version = parseVersion(versionText);
|
|
91
|
+
if (!version)
|
|
92
|
+
return undefined;
|
|
93
|
+
let readable = true;
|
|
94
|
+
let any = false;
|
|
95
|
+
for (const alternative of range.split('||')) {
|
|
96
|
+
// Join an operator written apart from its number (">= 1.2") first.
|
|
97
|
+
const tokens = alternative
|
|
98
|
+
.trim()
|
|
99
|
+
.replace(/(>=|<=|>|<|=|\^|~)\s+/g, '$1')
|
|
100
|
+
.split(/\s+/)
|
|
101
|
+
.filter(Boolean);
|
|
102
|
+
if (tokens.length === 0) {
|
|
103
|
+
readable = false;
|
|
104
|
+
continue;
|
|
105
|
+
}
|
|
106
|
+
let all = true;
|
|
107
|
+
for (const token of tokens) {
|
|
108
|
+
const ok = satisfiesComparator(version, token);
|
|
109
|
+
if (ok === undefined) {
|
|
110
|
+
readable = false;
|
|
111
|
+
all = false;
|
|
112
|
+
break;
|
|
113
|
+
}
|
|
114
|
+
if (!ok)
|
|
115
|
+
all = false;
|
|
116
|
+
}
|
|
117
|
+
if (all)
|
|
118
|
+
any = true;
|
|
119
|
+
}
|
|
120
|
+
if (any)
|
|
121
|
+
return true;
|
|
122
|
+
return readable ? false : undefined;
|
|
123
|
+
}
|
|
124
|
+
/**
|
|
125
|
+
* Refuse a plugin that declares it does not support this platform or this
|
|
126
|
+
* Namzu version. The reason names the plugin, what it declares and what this
|
|
127
|
+
* machine is, so a person can act on it without reading the manifest.
|
|
128
|
+
*
|
|
129
|
+
* A runtime whose own version is unknown (`0.0.0`, the placeholder a bundle
|
|
130
|
+
* reports when it cannot read its package file) is not held against the range:
|
|
131
|
+
* refusing every plugin on a guess would be worse than admitting one.
|
|
132
|
+
*/
|
|
133
|
+
export function assertCompatible(manifest, host) {
|
|
134
|
+
const platforms = manifest.platforms;
|
|
135
|
+
if (platforms && platforms.length > 0 && !platforms.includes(host.platform)) {
|
|
136
|
+
throw new Error(`Plugin "${manifest.name}" supports only ${platforms.join(', ')}, and this machine runs ${host.platform}, so it was not loaded.`);
|
|
137
|
+
}
|
|
138
|
+
const range = manifest.engines?.namzu;
|
|
139
|
+
if (range === undefined || host.namzuVersion === '0.0.0')
|
|
140
|
+
return;
|
|
141
|
+
const ok = versionSatisfies(host.namzuVersion, range);
|
|
142
|
+
if (ok === undefined) {
|
|
143
|
+
throw new Error(`Plugin "${manifest.name}" declares the Namzu version range "${range}", which cannot be read, so it was not loaded. Write it like ">=60.0.0" or "^60.1.0".`);
|
|
144
|
+
}
|
|
145
|
+
if (!ok) {
|
|
146
|
+
throw new Error(`Plugin "${manifest.name}" needs Namzu ${range}, and this is Namzu ${host.namzuVersion}, so it was not loaded. Update Namzu or use a plugin version made for this one.`);
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
//# sourceMappingURL=compat.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"compat.js","sourceRoot":"","s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@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { type PluginManifest } from '../types/plugin/index.js';
|
|
2
2
|
import { type Logger } from '../utils/logger.js';
|
|
3
|
+
import { type PluginHostFacts } from './compat.js';
|
|
3
4
|
/**
|
|
4
5
|
* Scans a directory for subdirectories containing a plugin manifest.
|
|
5
6
|
* Returns an array of absolute paths to plugin directories.
|
|
@@ -24,7 +25,7 @@ export declare function loadPluginManifest(pluginDir: string, capabilities?: Plu
|
|
|
24
25
|
* through host configuration; what does not exist is the manifest path
|
|
25
26
|
* into them. Naming the types is what makes that actionable.
|
|
26
27
|
*/
|
|
27
|
-
export interface PluginEnablementCapabilities {
|
|
28
|
+
export interface PluginEnablementCapabilities extends PluginHostFacts {
|
|
28
29
|
/**
|
|
29
30
|
* Whether the host wired a `SkillRegistry`.
|
|
30
31
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"loader.d.ts","sourceRoot":"","sources":["../../src/plugin/loader.ts"],"names":[],"mappings":"AASA,OAAO,EAAE,KAAK,cAAc,EAAwB,MAAM,0BAA0B,CAAA;AAGpF,OAAO,EAAE,KAAK,MAAM,EAAiB,MAAM,oBAAoB,CAAA;AAE/D;;;GAGG;AACH,wBAAsB,eAAe,CAAC,SAAS,EAAE,MAAM,EAAE,GAAG,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC,CA2DxF;AAED;;;GAGG;AACH,wBAAsB,kBAAkB,CACvC,SAAS,EAAE,MAAM,EACjB,YAAY,GAAE,4BAAiC,GAC7C,OAAO,CAAC,cAAc,CAAC,CAezB;AAgDD;;;;;;;;;;;;;GAaG;AACH,MAAM,WAAW,
|
|
1
|
+
{"version":3,"file":"loader.d.ts","sourceRoot":"","sources":["../../src/plugin/loader.ts"],"names":[],"mappings":"AASA,OAAO,EAAE,KAAK,cAAc,EAAwB,MAAM,0BAA0B,CAAA;AAGpF,OAAO,EAAE,KAAK,MAAM,EAAiB,MAAM,oBAAoB,CAA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AAC,CAwChD"}
|
package/dist/plugin/loader.js
CHANGED
|
@@ -7,6 +7,8 @@ import { PluginManifestSchema } from '../types/plugin/index.js';
|
|
|
7
7
|
import { toErrorMessage } from '../utils/error.js';
|
|
8
8
|
import { SCOPE_ATTRIBUTE } from '../utils/log/types.js';
|
|
9
9
|
import { resolveLogger } from '../utils/logger.js';
|
|
10
|
+
import { VERSION } from '../version.js';
|
|
11
|
+
import { assertCompatible } from './compat.js';
|
|
10
12
|
/**
|
|
11
13
|
* Scans a directory for subdirectories containing a plugin manifest.
|
|
12
14
|
* Returns an array of absolute paths to plugin directories.
|
|
@@ -133,6 +135,10 @@ async function discoverScopedPlugins(authorityRoot, relativePluginDir, scope, lo
|
|
|
133
135
|
*/
|
|
134
136
|
const REGISTRY_BACKED_CONTRIBUTIONS = ['skills'];
|
|
135
137
|
export function assertEnableable(manifest, capabilities = {}) {
|
|
138
|
+
assertCompatible(manifest, {
|
|
139
|
+
platform: capabilities.platform ?? platform(),
|
|
140
|
+
namzuVersion: capabilities.namzuVersion ?? VERSION,
|
|
141
|
+
});
|
|
136
142
|
const record = manifest;
|
|
137
143
|
// One ordered pass over all three rather than two group filters
|
|
138
144
|
// concatenated, so the message keeps naming them in the order the
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"loader.js","sourceRoot":"","sources":["../../src/plugin/loader.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAA;AACrE,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAA;AAC3C,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,WAAW,CAAA;AACzC,OAAO,EACN,wBAAwB,EACxB,kBAAkB,EAClB,eAAe,GACf,MAAM,8BAA8B,CAAA;AACrC,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAA;AACrD,OAAO,EAAuB,oBAAoB,EAA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OAAO,EAAE,IAAI,EAAE,CAAA;AACzB,CAAC;AAED;;;;;;;;;GASG;AACH,KAAK,UAAU,qBAAqB,CAAC,IAAY,EAAE,KAAa;IAC/D,MAAM,SAAS,GAAG,KAAK,EAAE,IAAY,EAAmB,EAAE;QACzD,IAAI,KAAa,CAAA;QACjB,IAAI,CAAC;YACJ,KAAK,GAAG,MAAM,QAAQ,CAAC,IAAI,CAAC,CAAA;QAC7B,CAAC;QAAC,MAAM,CAAC;YACR,KAAK,GAAG,OAAO,CAAC,IAAI,CAAC,CAAA;QACtB,CAAC;QACD,OAAO,QAAQ,EAAE,KAAK,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC,iBAAiB,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,KAAK,CAAA;IACzE,CAAC,CAAA;IACD,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC,CAAC,SAAS,CAAC,IAAI,CAAC,EAAE,SAAS,CAAC,KAAK,CAAC,CAAC,CAAC,CAAA;IACrE,OAAO,CAAC,KAAK,CAAC,CAAA;AACf,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/pricing/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/pricing/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAGH,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAA;AACpD,OAAO,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAEvD,YAAY,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAA;AAC3D,OAAO,EAAE,YAAY,EAAE,CAAA;AAevB,4EAA4E;AAC5E,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAEtD;AAED;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,wBAAgB,mBAAmB,CAClC,UAAU,EAAE,MAAM,EAClB,KAAK,EAAE,MAAM,GAAG,SAAS,GACvB,YAAY,GAAG,SAAS,CAW1B"}
|
package/dist/pricing/index.js
CHANGED
|
@@ -13,6 +13,7 @@
|
|
|
13
13
|
* `scripts/generate-model-prices.mjs` for why the source is reviewed rather
|
|
14
14
|
* than refreshed, and `rates.source.json` for the rates themselves.
|
|
15
15
|
*/
|
|
16
|
+
import { stripModelWindowSuffix } from '../compaction/context-window.js';
|
|
16
17
|
import { VENDOR_RATES } from './catalogue.generated.js';
|
|
17
18
|
export { VENDOR_RATES };
|
|
18
19
|
/** A driver that bills nothing per token resolves to this. */
|
|
@@ -27,7 +28,7 @@ const BY_PROVIDER = new Map(VENDOR_RATES.map((vendor) => [vendor.providerId, ven
|
|
|
27
28
|
const SNAPSHOT_SUFFIX = /[-@]\d{8}$/;
|
|
28
29
|
/** Lowercase, snapshot suffix removed. Exported because tests assert it. */
|
|
29
30
|
export function normaliseModelId(model) {
|
|
30
|
-
return model.toLowerCase().replace(SNAPSHOT_SUFFIX, '');
|
|
31
|
+
return stripModelWindowSuffix(model).toLowerCase().replace(SNAPSHOT_SUFFIX, '');
|
|
31
32
|
}
|
|
32
33
|
/**
|
|
33
34
|
* The rate card for a model, or `undefined` when nobody here has one.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/pricing/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/pricing/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAE,sBAAsB,EAAE,MAAM,iCAAiC,CAAA;AAExE,OAAO,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAGvD,OAAO,EAAE,YAAY,EAAE,CAAA;AAEvB,8DAA8D;AAC9D,MAAM,SAAS,GAAiB,EAAE,cAAc,EAAE,CAAC,EAAE,eAAe,EAAE,CAAC,EAAE,CAAA;AAEzE,MAAM,WAAW,GAAG,IAAI,GAAG,CAAC,YAAY,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,MAAM,CAAC,UAAU,EAAE,MAAM,CAAC,CAAC,CAAC,CAAA;AAEtF;;;;;GAKG;AACH,MAAM,eAAe,GAAG,YAAY,CAAA;AAEpC,4EAA4E;AAC5E,MAAM,UAAU,gBAAgB,CAAC,KAAa;IAC7C,OAAO,sBAAsB,CAAC,KAAK,CAAC,CAAC,WAAW,EAAE,CAAC,OAAO,CAAC,eAAe,EAAE,EAAE,CAAC,CAAA;AAChF,CAAC;AAED;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,MAAM,UAAU,mBAAmB,CAClC,UAAkB,EAClB,KAAyB;IAEzB,MAAM,MAAM,GAAG,WAAW,CAAC,GAAG,CAAC,UAAU,CAAC,CAAA;IAC1C,IAAI,MAAM,KAAK,SAAS;QAAE,OAAO,SAAS,CAAA;IAC1C,uEAAuE;IACvE,uEAAuE;IACvE,2EAA2E;IAC3E,wEAAwE;IACxE,qEAAqE;IACrE,IAAI,MAAM,CAAC,SAAS;QAAE,OAAO,SAAS,CAAA;IACtC,IAAI,KAAK,KAAK,SAAS;QAAE,OAAO,SAAS,CAAA;IACzC,OAAO,MAAM,CAAC,MAAM,CAAC,GAAG,CAAC,gBAAgB,CAAC,KAAK,CAAC,CAAC,CAAA;AAClD,CAAC"}
|
|
@@ -1,8 +1,44 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Whether a pid may be signalled, or addressed as a group with `-pid`.
|
|
3
|
+
*
|
|
4
|
+
* `kill(-1, sig)` signals every process the user may signal and `kill(0, sig)`
|
|
5
|
+
* signals the caller's own process group, so a recorded pid of 1, 0, a negative
|
|
6
|
+
* or a fractional number (a test double, a corrupt record, `NaN`) would take
|
|
7
|
+
* down the host's whole session. Only an integer above 1 that is not this
|
|
8
|
+
* process is a real, separate process. A refused pid is treated as already gone.
|
|
9
|
+
*/
|
|
10
|
+
export declare function isSignalablePid(pid: unknown): pid is number;
|
|
1
11
|
/** Remember how to find every process a Git Bash child started. Called by the spawn. */
|
|
2
12
|
export declare function registerMsysShell(child: object, shell: {
|
|
3
13
|
bash: string;
|
|
4
14
|
tag: string;
|
|
5
15
|
}): void;
|
|
16
|
+
/**
|
|
17
|
+
* Remember the tag a POSIX child's environment carries, so a kill can also find
|
|
18
|
+
* a descendant that left the child's process group (`setsid`, a double fork
|
|
19
|
+
* that starts its own session). Such a process has no group to signal, but it
|
|
20
|
+
* inherited the environment, and the tag is how it is found again.
|
|
21
|
+
*
|
|
22
|
+
* The limit is the same as the group's own: a process that clears its
|
|
23
|
+
* environment before it forks escapes this too.
|
|
24
|
+
*/
|
|
25
|
+
export declare function registerProcessTag(child: object, tag: string): void;
|
|
26
|
+
/**
|
|
27
|
+
* Signal every process of this user whose environment carries one of the tags,
|
|
28
|
+
* by reading `/proc/<pid>/environ`. Linux only: other POSIX systems have no
|
|
29
|
+
* `/proc`, and there the process group is all a kill can reach. A process whose
|
|
30
|
+
* environment cannot be read (another user's, or one that has just ended) is
|
|
31
|
+
* skipped without further work.
|
|
32
|
+
*
|
|
33
|
+
* Several tags are looked for in one pass, so stopping many jobs at once reads
|
|
34
|
+
* each environment once, not once per job. The scan is synchronous and its cost
|
|
35
|
+
* grows with the number of processes on the machine. There is also a window
|
|
36
|
+
* between reading an environment and signalling its pid in which the pid could
|
|
37
|
+
* be reused by an unrelated process of the same user; the window is the length
|
|
38
|
+
* of one read, and the signal goes only to a pid whose environment carried the
|
|
39
|
+
* tag a moment before.
|
|
40
|
+
*/
|
|
41
|
+
export declare function signalTagged(tags: string | readonly string[], signal: NodeJS.Signals): number;
|
|
6
42
|
/** The environment variable that carries the tag. */
|
|
7
43
|
export declare const MSYS_TAG_VARIABLE = "NAMZU_SHELL_TAG";
|
|
8
44
|
/**
|
|
@@ -43,4 +79,12 @@ export declare const MSYS_TAG_VARIABLE = "NAMZU_SHELL_TAG";
|
|
|
43
79
|
export declare function killTree(child: {
|
|
44
80
|
readonly pid?: number | undefined;
|
|
45
81
|
}, signal: NodeJS.Signals): void;
|
|
82
|
+
/**
|
|
83
|
+
* `killTree` for several children at once: each child's group is signalled, then
|
|
84
|
+
* the environment scan runs once for all their tags. Used where the number of
|
|
85
|
+
* kills is unbounded and cannot wait, such as the host's exit.
|
|
86
|
+
*/
|
|
87
|
+
export declare function killTrees(children: readonly {
|
|
88
|
+
readonly pid?: number | undefined;
|
|
89
|
+
}[], signal: NodeJS.Signals): void;
|
|
46
90
|
//# sourceMappingURL=kill-tree.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"kill-tree.d.ts","sourceRoot":"","sources":["../../src/process/kill-tree.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"kill-tree.d.ts","sourceRoot":"","sources":["../../src/process/kill-tree.ts"],"names":[],"mappings":"AAgBA;;;;;;;;GAQG;AACH,wBAAgB,eAAe,CAAC,GAAG,EAAE,OAAO,GAAG,GAAG,IAAI,MAAM,CAE3D;AAED,wFAAwF;AACxF,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,GAAG,EAAE,MAAM,CAAA;CAAE,GAAG,IAAI,CAE3F;AAED;;;;;;;;GAQG;AACH,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,GAAG,IAAI,CAEnE;AAED;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,YAAY,CAAC,IAAI,EAAE,MAAM,GAAG,SAAS,MAAM,EAAE,EAAE,MAAM,EAAE,MAAM,CAAC,OAAO,GAAG,MAAM,CA0B7F;AAED,qDAAqD;AACrD,eAAO,MAAM,iBAAiB,oBAAoB,CAAA;AA4BlD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkCG;AACH,wBAAgB,QAAQ,CACvB,KAAK,EAAE;IAAE,QAAQ,CAAC,GAAG,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;CAAE,EAC5C,MAAM,EAAE,MAAM,CAAC,OAAO,GACpB,IAAI,CAEN;AAED;;;;GAIG;AACH,wBAAgB,SAAS,CACxB,QAAQ,EAAE,SAAS;IAAE,QAAQ,CAAC,GAAG,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;CAAE,EAAE,EAC1D,MAAM,EAAE,MAAM,CAAC,OAAO,GACpB,IAAI,CAON"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { execFileSync } from 'node:child_process';
|
|
2
|
+
import { readFileSync, readdirSync } from 'node:fs';
|
|
2
3
|
/**
|
|
3
4
|
* Git Bash children that the Windows process tree cannot reach.
|
|
4
5
|
*
|
|
@@ -11,10 +12,80 @@ import { execFileSync } from 'node:child_process';
|
|
|
11
12
|
* the tag is how the tree is found again.
|
|
12
13
|
*/
|
|
13
14
|
const MSYS_SHELLS = new WeakMap();
|
|
15
|
+
/**
|
|
16
|
+
* Whether a pid may be signalled, or addressed as a group with `-pid`.
|
|
17
|
+
*
|
|
18
|
+
* `kill(-1, sig)` signals every process the user may signal and `kill(0, sig)`
|
|
19
|
+
* signals the caller's own process group, so a recorded pid of 1, 0, a negative
|
|
20
|
+
* or a fractional number (a test double, a corrupt record, `NaN`) would take
|
|
21
|
+
* down the host's whole session. Only an integer above 1 that is not this
|
|
22
|
+
* process is a real, separate process. A refused pid is treated as already gone.
|
|
23
|
+
*/
|
|
24
|
+
export function isSignalablePid(pid) {
|
|
25
|
+
return typeof pid === 'number' && Number.isInteger(pid) && pid > 1 && pid !== process.pid;
|
|
26
|
+
}
|
|
14
27
|
/** Remember how to find every process a Git Bash child started. Called by the spawn. */
|
|
15
28
|
export function registerMsysShell(child, shell) {
|
|
16
29
|
MSYS_SHELLS.set(child, shell);
|
|
17
30
|
}
|
|
31
|
+
/**
|
|
32
|
+
* Remember the tag a POSIX child's environment carries, so a kill can also find
|
|
33
|
+
* a descendant that left the child's process group (`setsid`, a double fork
|
|
34
|
+
* that starts its own session). Such a process has no group to signal, but it
|
|
35
|
+
* inherited the environment, and the tag is how it is found again.
|
|
36
|
+
*
|
|
37
|
+
* The limit is the same as the group's own: a process that clears its
|
|
38
|
+
* environment before it forks escapes this too.
|
|
39
|
+
*/
|
|
40
|
+
export function registerProcessTag(child, tag) {
|
|
41
|
+
MSYS_SHELLS.set(child, { tag });
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* Signal every process of this user whose environment carries one of the tags,
|
|
45
|
+
* by reading `/proc/<pid>/environ`. Linux only: other POSIX systems have no
|
|
46
|
+
* `/proc`, and there the process group is all a kill can reach. A process whose
|
|
47
|
+
* environment cannot be read (another user's, or one that has just ended) is
|
|
48
|
+
* skipped without further work.
|
|
49
|
+
*
|
|
50
|
+
* Several tags are looked for in one pass, so stopping many jobs at once reads
|
|
51
|
+
* each environment once, not once per job. The scan is synchronous and its cost
|
|
52
|
+
* grows with the number of processes on the machine. There is also a window
|
|
53
|
+
* between reading an environment and signalling its pid in which the pid could
|
|
54
|
+
* be reused by an unrelated process of the same user; the window is the length
|
|
55
|
+
* of one read, and the signal goes only to a pid whose environment carried the
|
|
56
|
+
* tag a moment before.
|
|
57
|
+
*/
|
|
58
|
+
export function signalTagged(tags, signal) {
|
|
59
|
+
const needles = (typeof tags === 'string' ? [tags] : tags).map((tag) => `${MSYS_TAG_VARIABLE}=${tag}\0`);
|
|
60
|
+
if (needles.length === 0)
|
|
61
|
+
return 0;
|
|
62
|
+
let entries;
|
|
63
|
+
try {
|
|
64
|
+
entries = readdirSync('/proc');
|
|
65
|
+
}
|
|
66
|
+
catch {
|
|
67
|
+
return 0;
|
|
68
|
+
}
|
|
69
|
+
let signalled = 0;
|
|
70
|
+
for (const entry of entries) {
|
|
71
|
+
if (!/^\d+$/.test(entry))
|
|
72
|
+
continue;
|
|
73
|
+
const pid = Number(entry);
|
|
74
|
+
if (!isSignalablePid(pid))
|
|
75
|
+
continue;
|
|
76
|
+
try {
|
|
77
|
+
const environ = readFileSync(`/proc/${entry}/environ`, 'latin1');
|
|
78
|
+
if (!needles.some((needle) => environ.includes(needle)))
|
|
79
|
+
continue;
|
|
80
|
+
process.kill(pid, signal);
|
|
81
|
+
signalled++;
|
|
82
|
+
}
|
|
83
|
+
catch {
|
|
84
|
+
// Not ours to read, or gone since the listing.
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
return signalled;
|
|
88
|
+
}
|
|
18
89
|
/** The environment variable that carries the tag. */
|
|
19
90
|
export const MSYS_TAG_VARIABLE = 'NAMZU_SHELL_TAG';
|
|
20
91
|
/** Kill every process whose environment carries the tag, from inside the msys runtime. */
|
|
@@ -78,20 +149,47 @@ function taskkillPath() {
|
|
|
78
149
|
* POSIX SIGKILL that follows a SIGTERM which already worked.
|
|
79
150
|
*/
|
|
80
151
|
export function killTree(child, signal) {
|
|
81
|
-
|
|
152
|
+
killTrees([child], signal);
|
|
153
|
+
}
|
|
154
|
+
/**
|
|
155
|
+
* `killTree` for several children at once: each child's group is signalled, then
|
|
156
|
+
* the environment scan runs once for all their tags. Used where the number of
|
|
157
|
+
* kills is unbounded and cannot wait, such as the host's exit.
|
|
158
|
+
*/
|
|
159
|
+
export function killTrees(children, signal) {
|
|
160
|
+
const tags = [];
|
|
161
|
+
for (const child of children) {
|
|
162
|
+
if (!isSignalablePid(child.pid))
|
|
163
|
+
continue;
|
|
164
|
+
killOne(child, signal, tags);
|
|
165
|
+
}
|
|
166
|
+
if (tags.length > 0 && process.platform === 'linux')
|
|
167
|
+
signalTagged(tags, signal);
|
|
168
|
+
}
|
|
169
|
+
function killOne(child, signal, tags) {
|
|
170
|
+
if (!isSignalablePid(child.pid))
|
|
82
171
|
return;
|
|
83
172
|
try {
|
|
84
173
|
if (process.platform === 'win32') {
|
|
85
174
|
const msys = MSYS_SHELLS.get(child);
|
|
86
|
-
if (msys !== undefined)
|
|
87
|
-
killMsysTagged(msys);
|
|
175
|
+
if (msys?.bash !== undefined)
|
|
176
|
+
killMsysTagged({ bash: msys.bash, tag: msys.tag });
|
|
88
177
|
execFileSync(taskkillPath(), ['/pid', String(child.pid), '/t', '/f'], {
|
|
89
178
|
stdio: 'ignore',
|
|
90
179
|
windowsHide: true,
|
|
91
180
|
});
|
|
92
181
|
}
|
|
93
182
|
else {
|
|
94
|
-
|
|
183
|
+
try {
|
|
184
|
+
process.kill(-child.pid, signal);
|
|
185
|
+
}
|
|
186
|
+
finally {
|
|
187
|
+
// After the group, which is cheap and exact: what is left is only
|
|
188
|
+
// what started its own session. Also when the group is already gone.
|
|
189
|
+
const tagged = MSYS_SHELLS.get(child);
|
|
190
|
+
if (tagged !== undefined)
|
|
191
|
+
tags.push(tagged.tag);
|
|
192
|
+
}
|
|
95
193
|
}
|
|
96
194
|
}
|
|
97
195
|
catch {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"kill-tree.js","sourceRoot":"","sources":["../../src/process/kill-tree.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAA;
|
|
1
|
+
{"version":3,"file":"kill-tree.js","sourceRoot":"","sources":["../../src/process/kill-tree.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAA;AACjD,OAAO,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,SAAS,CAAA;AAEnD;;;;;;;;;;GAUG;AACH,MAAM,WAAW,GAAG,IAAI,OAAO,EAA4D,CAAA;AAE3F;;;;;;;;GAQG;AACH,MAAM,UAAU,eAAe,CAAC,GAAY;IAC3C,OAAO,OAAO,GAAG,KAAK,QAAQ,IAAI,MAAM,CAAC,SAAS,CAAC,GAAG,CAAC,IAAI,GAAG,GAAG,CAAC,IAAI,GAAG,KAAK,OAAO,CAAC,GAAG,CAAA;AAC1F,CAAC;AAED,wFAAwF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rC,IAAI,MAAM,KAAK,SAAS;oBAAE,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,CAAA;YAChD,CAAC;QACF,CAAC;IACF,CAAC;IAAC,MAAM,CAAC;QACR,+BAA+B;IAChC,CAAC;AACF,CAAC"}
|
|
@@ -37,7 +37,7 @@ export declare const CODING_AGENT_WORKING_DOCTRINE = "## How you work\n\n### Del
|
|
|
37
37
|
* Parent-only: rules about `task_create` / `task_update` and `Agent`, which a
|
|
38
38
|
* delegated sub-agent does not have. See the module comment for the split.
|
|
39
39
|
*/
|
|
40
|
-
export declare const CODING_AGENT_DELEGATION_DOCTRINE = "### Planning and delegating\n- For work of three or more steps \u2014 several files, several distinct stages, anything you would write a checklist for \u2014 open a task list with `task_create` and keep it current with `task_update`, marking each step done when it is done rather than at the end. Skip it for a single inspect-edit-test cycle or a two-step job: the list is for the user to follow, and a list of one or two items tells them nothing.\n- When the `Agent` tool is available, delegate independent work through it and give each delegation a short, specific description; the user watches those descriptions, not the prompts. Brief each sub-agent with four things: the objective; what is out of bounds; which tools and sources to use; and the shape of the reply you want, such as a short summary with a file path for anything long. A fresh sub-agent starts with none of your context and returns what you ask for.\n- When the `Agent` tool lists a `fork` type, use `subagent_type: \"fork\"` when a side task would fill your context with output you will not need again, such as an open-ended survey. A fork starts from this conversation under your own instructions, so its prompt is only the directive: what to do and where its scope ends, without the background. Never write or guess what a fork will find before its report arrives. A fork cannot start forks of its own.\n- When delegated agents finish, tell the user what each one found in your next message. Their results reach you and not the user, so a result you do not pass on stays unseen.\n- Delegate lookups \u2014 where something is defined, which files reference it, how a module works \u2014 with `subagent_type: \"explore\"`: it has reading and searching tools only and never interrupts the user for permission. Reserve the default sub-agent for work that changes files or runs commands.";
|
|
40
|
+
export declare const CODING_AGENT_DELEGATION_DOCTRINE = "### Planning and delegating\n- For work of three or more steps \u2014 several files, several distinct stages, anything you would write a checklist for \u2014 open a task list with `task_create` and keep it current with `task_update`, marking each step done when it is done rather than at the end. Skip it for a single inspect-edit-test cycle or a two-step job: the list is for the user to follow, and a list of one or two items tells them nothing.\n- When the `Agent` tool is available, delegate independent work through it and give each delegation a short, specific description; the user watches those descriptions, not the prompts. Brief each sub-agent with four things: the objective; what is out of bounds; which tools and sources to use; and the shape of the reply you want, such as a short summary with a file path for anything long. A fresh sub-agent starts with none of your context and returns what you ask for.\n- When the `Agent` tool lists a `fork` type, use `subagent_type: \"fork\"` when a side task would fill your context with output you will not need again, such as an open-ended survey. A fork starts from this conversation under your own instructions, so its prompt is only the directive: what to do and where its scope ends, without the background. Never write or guess what a fork will find before its report arrives. A fork cannot start forks of its own.\n- When delegated agents finish, tell the user what each one found in your next message. Their results reach you and not the user, so a result you do not pass on stays unseen.\n- Delegate lookups \u2014 where something is defined, which files reference it, how a module works \u2014 with `subagent_type: \"explore\"`: it has reading and searching tools only and never interrupts the user for permission. Reserve the default sub-agent for work that changes files or runs commands.\n\n### Answering how work is going\n- When asked how things stand while background work runs, read the note about running work on your request first if the host gives you one, and add one status read from the tool that started an item only when the note does not say enough. The answer needs no waiting or polling and leaves the work running, because stopping or restarting an item to answer would lose what it has done.\n- Give each item the state you were given for it (progressing, waiting, stalled or dead) and how long ago it last moved, so the person can judge it for themselves. Stalled means only quiet for a while, not stuck.\n- Group the answer as finished (with its result), running (and where it is), queued, and needing a decision. Lead with the outcome, keep it short, and write in the language the person used, states included.\n- Name each item by what it is doing, not by its id: an id means nothing to the person, so give one only when they ask for it or need it for a command.\n- A result exists only once its completion message has arrived, so for an unfinished item say it is still running; a predicted result reads as a fact and may be wrong.\n- For an item reported dead, say it ended without a result and offer to run it again; starting the same work again unasked could repeat what it already did.";
|
|
41
41
|
/**
|
|
42
42
|
* For a session whose permission layer refuses every mutation. Says what that
|
|
43
43
|
* layer will enforce anyway, so the model plans instead of discovering the
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"coding-agent-doctrine.d.ts","sourceRoot":"","sources":["../../src/prompt/coding-agent-doctrine.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgCG;AAEH,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAA;AAE5D,eAAO,MAAM,6BAA6B,u2MAqCgD,CAAA;AAE1F;;;GAGG;AACH,eAAO,MAAM,gCAAgC,
|
|
1
|
+
{"version":3,"file":"coding-agent-doctrine.d.ts","sourceRoot":"","sources":["../../src/prompt/coding-agent-doctrine.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgCG;AAEH,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAA;AAE5D,eAAO,MAAM,6BAA6B,u2MAqCgD,CAAA;AAE1F;;;GAGG;AACH,eAAO,MAAM,gCAAgC,gnGAagH,CAAA;AAE7J;;;;GAIG;AACH,eAAO,MAAM,kBAAkB,2nBAI8S,CAAA;AAE7U;;;;;;;GAOG;AACH,eAAO,MAAM,+BAA+B,oqBACimB,CAAA;AAE7oB;;;GAGG;AACH,eAAO,MAAM,iCAAiC,oqBAAkC,CAAA;AAEhF,eAAO,MAAM,qCAAqC,gCAAgC,CAAA;AAElF,MAAM,WAAW,0BAA0B;IAC1C;;;;OAIG;IACH,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB;;;;;;;;;OASG;IACH,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB;;;;OAIG;IACH,WAAW,CAAC,EAAE,OAAO,CAAA;CACrB;AAED;;;;;GAKG;AACH,wBAAgB,+BAA+B,CAC9C,OAAO,GAAE,0BAA+B,GACtC,kBAAkB,CAepB"}
|
|
@@ -78,7 +78,15 @@ export const CODING_AGENT_DELEGATION_DOCTRINE = `### Planning and delegating
|
|
|
78
78
|
- When the \`Agent\` tool is available, delegate independent work through it and give each delegation a short, specific description; the user watches those descriptions, not the prompts. Brief each sub-agent with four things: the objective; what is out of bounds; which tools and sources to use; and the shape of the reply you want, such as a short summary with a file path for anything long. A fresh sub-agent starts with none of your context and returns what you ask for.
|
|
79
79
|
- When the \`Agent\` tool lists a \`fork\` type, use \`subagent_type: "fork"\` when a side task would fill your context with output you will not need again, such as an open-ended survey. A fork starts from this conversation under your own instructions, so its prompt is only the directive: what to do and where its scope ends, without the background. Never write or guess what a fork will find before its report arrives. A fork cannot start forks of its own.
|
|
80
80
|
- When delegated agents finish, tell the user what each one found in your next message. Their results reach you and not the user, so a result you do not pass on stays unseen.
|
|
81
|
-
- Delegate lookups — where something is defined, which files reference it, how a module works — with \`subagent_type: "explore"\`: it has reading and searching tools only and never interrupts the user for permission. Reserve the default sub-agent for work that changes files or runs commands
|
|
81
|
+
- Delegate lookups — where something is defined, which files reference it, how a module works — with \`subagent_type: "explore"\`: it has reading and searching tools only and never interrupts the user for permission. Reserve the default sub-agent for work that changes files or runs commands.
|
|
82
|
+
|
|
83
|
+
### Answering how work is going
|
|
84
|
+
- When asked how things stand while background work runs, read the note about running work on your request first if the host gives you one, and add one status read from the tool that started an item only when the note does not say enough. The answer needs no waiting or polling and leaves the work running, because stopping or restarting an item to answer would lose what it has done.
|
|
85
|
+
- Give each item the state you were given for it (progressing, waiting, stalled or dead) and how long ago it last moved, so the person can judge it for themselves. Stalled means only quiet for a while, not stuck.
|
|
86
|
+
- Group the answer as finished (with its result), running (and where it is), queued, and needing a decision. Lead with the outcome, keep it short, and write in the language the person used, states included.
|
|
87
|
+
- Name each item by what it is doing, not by its id: an id means nothing to the person, so give one only when they ask for it or need it for a command.
|
|
88
|
+
- A result exists only once its completion message has arrived, so for an unfinished item say it is still running; a predicted result reads as a fact and may be wrong.
|
|
89
|
+
- For an item reported dead, say it ended without a result and offer to run it again; starting the same work again unasked could repeat what it already did.`;
|
|
82
90
|
/**
|
|
83
91
|
* For a session whose permission layer refuses every mutation. Says what that
|
|
84
92
|
* layer will enforce anyway, so the model plans instead of discovering the
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"coding-agent-doctrine.js","sourceRoot":"","sources":["../../src/prompt/coding-agent-doctrine.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgCG;AAIH,MAAM,CAAC,MAAM,6BAA6B,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;0FAqC6C,CAAA;AAE1F;;;GAGG;AACH,MAAM,CAAC,MAAM,gCAAgC,GAAG
|
|
1
|
+
{"version":3,"file":"coding-agent-doctrine.js","sourceRoot":"","sources":["../../src/prompt/coding-agent-doctrine.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgCG;AAIH,MAAM,CAAC,MAAM,6BAA6B,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;0FAqC6C,CAAA;AAE1F;;;GAGG;AACH,MAAM,CAAC,MAAM,gCAAgC,GAAG;;;;;;;;;;;;;6JAa6G,CAAA;AAE7J;;;;GAIG;AACH,MAAM,CAAC,MAAM,kBAAkB,GAAG;;;;6UAI2S,CAAA;AAE7U;;;;;;;GAOG;AACH,MAAM,CAAC,MAAM,+BAA+B,GAAG;6oBAC8lB,CAAA;AAE7oB;;;GAGG;AACH,MAAM,CAAC,MAAM,iCAAiC,GAAG,+BAA+B,CAAA;AAEhF,MAAM,CAAC,MAAM,qCAAqC,GAAG,6BAA6B,CAAA;AA4BlF;;;;;GAKG;AACH,MAAM,UAAU,+BAA+B,CAC9C,UAAsC,EAAE;IAExC,MAAM,IAAI,GAAG;QACZ,6BAA6B;QAC7B,OAAO,CAAC,UAAU,KAAK,KAAK,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,gCAAgC;QAC3E,OAAO,CAAC,UAAU,KAAK,KAAK,IAAI,CAAC,OAAO,CAAC,SAAS,IAAI,OAAO,CAAC,WAAW,CAAC;YACzE,CAAC,CAAC,+BAA+B;YACjC,CAAC,CAAC,SAAS;KACZ;SACC,MAAM,CAAC,CAAC,IAAI,EAAkB,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;SAC/C,IAAI,CAAC,MAAM,CAAC,CAAA;IACd,OAAO;QACN,EAAE,EAAE,qCAAqC;QACzC,SAAS,EAAE,QAAQ;QACnB,MAAM,EAAE,GAAG,EAAE,CAAC,IAAI;KAClB,CAAA;AACF,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../../src/provider/errors.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AAGH,OAAO,KAAK,EAAE,iBAAiB,EAAE,wBAAwB,EAAE,MAAM,4BAA4B,CAAA;AAC7F,OAAO,EACN,KAAK,cAAc,
|
|
1
|
+
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../../src/provider/errors.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AAGH,OAAO,KAAK,EAAE,iBAAiB,EAAE,wBAAwB,EAAE,MAAM,4BAA4B,CAAA;AAC7F,OAAO,EACN,KAAK,cAAc,EAInB,MAAM,6BAA6B,CAAA;AACpC,YAAY,EACX,iBAAiB,EACjB,iBAAiB,EACjB,wBAAwB,GACxB,MAAM,4BAA4B,CAAA;AAWnC;;;;;;;GAOG;AACH,qBAAa,oBAAqB,SAAQ,KAAK;IAC9C,SAAgB,IAAI,EAAE,iBAAiB,CAAA;IACvC,SAAgB,UAAU,EAAE,MAAM,CAAA;IAClC,SAAgB,YAAY,CAAC,EAAE,MAAM,CAAA;IACrC,SAAgB,MAAM,CAAC,EAAE,MAAM,CAAA;IAC/B,SAAgB,YAAY,CAAC,EAAE,MAAM,CAAA;IACrC;;;;;;;;;;;;;;OAcG;IACH,SAAgB,MAAM,CAAC,EAAE,MAAM,CAAA;IAC/B,mHAAmH;IACnH,SAAgB,WAAW,CAAC,EAAE,OAAO,CAAA;IACrC,uHAAuH;IACvH,SAAgB,SAAS,CAAC,EAAE,cAAc,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