@robota-sdk/agent-product 3.2.3 → 3.3.2
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 +40 -0
- package/README.md +22 -11
- package/dist/capability-pack/index.cjs +1 -0
- package/dist/capability-pack/index.d.cts +2 -0
- package/dist/capability-pack/index.d.ts +2 -0
- package/dist/capability-pack/index.js +1 -0
- package/dist/capability-pack-D389p-Cv.js +2 -0
- package/dist/capability-pack-D389p-Cv.js.map +1 -0
- package/dist/capability-pack-Dc6eJ76H.cjs +1 -0
- package/dist/coding/index.cjs +1 -0
- package/dist/coding/index.d.cts +75 -0
- package/dist/coding/index.d.cts.map +1 -0
- package/dist/coding/index.d.ts +75 -0
- package/dist/coding/index.d.ts.map +1 -0
- package/dist/coding/index.js +2 -0
- package/dist/coding/index.js.map +1 -0
- package/dist/command/index.cjs +1 -0
- package/dist/command/index.d.cts +948 -0
- package/dist/command/index.d.cts.map +1 -0
- package/dist/command/index.d.ts +948 -0
- package/dist/command/index.d.ts.map +1 -0
- package/dist/command/index.js +1 -0
- package/dist/command/node.cjs +1 -0
- package/dist/command/node.d.cts +100 -0
- package/dist/command/node.d.cts.map +1 -0
- package/dist/command/node.d.ts +100 -0
- package/dist/command/node.d.ts.map +1 -0
- package/dist/command/node.js +1 -0
- package/dist/command-DZUsxxG3.cjs +120 -0
- package/dist/command-DynprfoA.js +121 -0
- package/dist/command-DynprfoA.js.map +1 -0
- package/dist/index-BNDTmhmd.d.cts +109 -0
- package/dist/index-BNDTmhmd.d.cts.map +1 -0
- package/dist/index-BNDTmhmd.d.ts +109 -0
- package/dist/index-BNDTmhmd.d.ts.map +1 -0
- package/dist/index-Cz8aDRO3.d.cts +156 -0
- package/dist/index-Cz8aDRO3.d.cts.map +1 -0
- package/dist/index-jksIH551.d.ts +156 -0
- package/dist/index-jksIH551.d.ts.map +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.d.cts +6 -5
- package/dist/index.d.cts.map +1 -1
- package/dist/index.d.ts +6 -5
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/keybindings-command-module-CcA9-Xqi.d.cts +126 -0
- package/dist/keybindings-command-module-CcA9-Xqi.d.cts.map +1 -0
- package/dist/keybindings-command-module-CcA9-Xqi.d.ts +126 -0
- package/dist/keybindings-command-module-CcA9-Xqi.d.ts.map +1 -0
- package/dist/load-external-presets-CJeFbxNF.js +5 -0
- package/dist/load-external-presets-CJeFbxNF.js.map +1 -0
- package/dist/load-external-presets-DCY3HJ8d.d.cts +107 -0
- package/dist/load-external-presets-DCY3HJ8d.d.cts.map +1 -0
- package/dist/load-external-presets-DCY3HJ8d.d.ts +107 -0
- package/dist/load-external-presets-DCY3HJ8d.d.ts.map +1 -0
- package/dist/load-external-presets-DyoUUA3V.cjs +4 -0
- package/dist/node-BgupUyg0.cjs +1 -0
- package/dist/node-Cw2VT1HG.js +2 -0
- package/dist/node-Cw2VT1HG.js.map +1 -0
- package/dist/preset/index.cjs +1 -0
- package/dist/preset/index.d.cts +3 -0
- package/dist/preset/index.d.ts +3 -0
- package/dist/preset/index.js +1 -0
- package/dist/preset/node.cjs +1 -0
- package/dist/preset/node.d.cts +13 -0
- package/dist/preset/node.d.cts.map +1 -0
- package/dist/preset/node.d.ts +13 -0
- package/dist/preset/node.d.ts.map +1 -0
- package/dist/preset/node.js +2 -0
- package/dist/preset/node.js.map +1 -0
- package/dist/preset-nuw37AF-.js +4 -0
- package/dist/preset-nuw37AF-.js.map +1 -0
- package/dist/preset-tH5pgRIC.cjs +3 -0
- package/dist/theme-command-module-DYJhjKuI.cjs +2 -0
- package/dist/theme-command-module-GyqgVqV9.js +3 -0
- package/dist/theme-command-module-GyqgVqV9.js.map +1 -0
- package/package.json +78 -8
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,45 @@
|
|
|
1
1
|
# @robota-sdk/agent-product
|
|
2
2
|
|
|
3
|
+
## 3.3.2
|
|
4
|
+
### Patch Changes
|
|
5
|
+
|
|
6
|
+
- Refresh the package README so the npm page shows the current package layout, install steps and environment variable names.
|
|
7
|
+
- Updated dependencies
|
|
8
|
+
- @robota-sdk/agent-core@3.3.1
|
|
9
|
+
- @robota-sdk/agent-framework@3.3.1
|
|
10
|
+
- @robota-sdk/agent-interface@3.3.1
|
|
11
|
+
- @robota-sdk/agent-tools@3.3.2
|
|
12
|
+
|
|
13
|
+
## 3.3.1
|
|
14
|
+
### Patch Changes
|
|
15
|
+
|
|
16
|
+
- The previous version of this package was tagged but never published to npm, because `main` moved past its release commit first. This version carries the same consolidated package set from the current `main`, with comment and test-name cleanups and no behavior change.
|
|
17
|
+
- Updated dependencies
|
|
18
|
+
- @robota-sdk/agent-tools@3.3.1
|
|
19
|
+
- @robota-sdk/agent-framework@3.2.5
|
|
20
|
+
|
|
21
|
+
## 3.3.0
|
|
22
|
+
### Minor Changes
|
|
23
|
+
|
|
24
|
+
- 02619fa: The product-assembly packages are now one package, `@robota-sdk/agent-product`. Its root export is unchanged; the rest are subpaths: `capability-pack` (was `@robota-sdk/agent-capability-pack`), `preset` and `preset/node` (was `@robota-sdk/agent-preset` and its `./node`), `command` and `command/node` (was `@robota-sdk/agent-command` and its `./node`) and `coding` (was `@robota-sdk/pack-coding`). Import the subpath you use (`@robota-sdk/agent-product/preset`). The root, `capability-pack`, `preset` and `command` stay platform-neutral; `preset/node`, `command/node` and `coding` are Node only and map `browser: null`. The exported names and signatures are unchanged, and a consumer's install does not grow: every package the merged manifest names is already installed with `@robota-sdk/agent-framework`, which each of the old packages required. `@robota-sdk/agent-capability-pack`, `@robota-sdk/agent-preset`, `@robota-sdk/agent-command` and `@robota-sdk/pack-coding` no longer receive releases.
|
|
25
|
+
|
|
26
|
+
### Patch Changes
|
|
27
|
+
|
|
28
|
+
- 327999e: The contract packages are now one package, `@robota-sdk/agent-interface`, with one subpath per family: `session` (and `session/testing`), `session-mobility`, `command`, `execution`, `analytics`, `transport` (and `transport/testing`) and `tui`. Import the subpath of the family you use (`@robota-sdk/agent-interface/session`); there is no root export. `@robota-sdk/agent-core` is now an optional peer dependency: `analytics` and `tui` need nothing, and a project that imports another family installs `agent-core` itself (the SDK packages that import those families declare it). The exported names and signatures are unchanged. `@robota-sdk/agent-interface-session`, `-session-mobility`, `-command`, `-execution`, `-analytics`, `-transport` and `-tui` no longer receive releases. The SDK packages that import a contract depend on `@robota-sdk/agent-interface`.
|
|
29
|
+
- Updated dependencies [1f900da]
|
|
30
|
+
- Updated dependencies [86fc3d4]
|
|
31
|
+
- Updated dependencies [327999e]
|
|
32
|
+
- Updated dependencies [913d334]
|
|
33
|
+
- Updated dependencies [589df44]
|
|
34
|
+
- Updated dependencies [87449a3]
|
|
35
|
+
- Updated dependencies [16795cb]
|
|
36
|
+
- Updated dependencies [bf901d7]
|
|
37
|
+
- Updated dependencies [f377a57]
|
|
38
|
+
- @robota-sdk/agent-core@3.2.3
|
|
39
|
+
- @robota-sdk/agent-framework@3.2.4
|
|
40
|
+
- @robota-sdk/agent-interface@3.3.0
|
|
41
|
+
- @robota-sdk/agent-tools@3.3.0
|
|
42
|
+
|
|
3
43
|
## 3.2.3
|
|
4
44
|
### Patch Changes
|
|
5
45
|
|
package/README.md
CHANGED
|
@@ -1,15 +1,14 @@
|
|
|
1
1
|
# @robota-sdk/agent-product
|
|
2
2
|
|
|
3
|
-
> **Version:** Platform support and entries described here target SDK 3.1.0. Install that
|
|
4
|
-
> release after publication; published 3.0.7 packages may have different exports and behavior.
|
|
5
|
-
|
|
6
3
|
The **product-assembly kernel** for the Robota SDK.
|
|
7
4
|
|
|
8
5
|
`assembleProduct(profile)` is a **pure, deterministic, IO-free fold** over an `IProductProfile` — the
|
|
9
6
|
composition mechanism a third party imports to build their OWN product on Robota's published runtime.
|
|
10
7
|
Product identity and its runtime settings are supplied by the host; an external repo can define its own profile.
|
|
11
|
-
The
|
|
12
|
-
adapter
|
|
8
|
+
The root entry is platform-neutral: it runs in a browser, a Web Worker, Node, Deno and Bun, and has no
|
|
9
|
+
Node adapter. The pieces a product is assembled from are subpaths of the same package: the capability-pack
|
|
10
|
+
contract, presets, the slash-command modules and Robota's coding pack. The ones that need a Node host are
|
|
11
|
+
marked below.
|
|
13
12
|
|
|
14
13
|
## Installation
|
|
15
14
|
|
|
@@ -17,16 +16,28 @@ adapter, so it has no `./node` subpath.
|
|
|
17
16
|
npm install @robota-sdk/agent-product
|
|
18
17
|
```
|
|
19
18
|
|
|
19
|
+
## Entry points
|
|
20
|
+
|
|
21
|
+
| Import path | Environment | What it contains |
|
|
22
|
+
| ------------------------------------------- | ---------------- | ---------------------------------------------------------------------------------------------------- |
|
|
23
|
+
| `@robota-sdk/agent-product` | browser and Node | `assembleProduct`, `IProductProfile`, `IAssembledProduct` |
|
|
24
|
+
| `@robota-sdk/agent-product/capability-pack` | browser and Node | `ICapabilityPack`, `mergeCapabilityPacks` ([docs/capability-pack.md](docs/capability-pack.md)) |
|
|
25
|
+
| `@robota-sdk/agent-product/preset` | browser and Node | `IPreset`, the built-in presets and output styles, the registries ([docs/preset.md](docs/preset.md)) |
|
|
26
|
+
| `@robota-sdk/agent-product/preset/node` | Node only | `loadExternalPresetsFromDir` |
|
|
27
|
+
| `@robota-sdk/agent-product/command` | browser and Node | The slash-command modules, `createDefaultCommandModules` ([docs/command.md](docs/command.md)) |
|
|
28
|
+
| `@robota-sdk/agent-product/command/node` | Node only | The host commands (`/shell`, `/editor`) and the Node adapters the commands take by injection |
|
|
29
|
+
| `@robota-sdk/agent-product/coding` | Node only | `createCodingPack`, Robota's coding capability pack ([docs/coding.md](docs/coding.md)) |
|
|
30
|
+
|
|
20
31
|
## Usage
|
|
21
32
|
|
|
22
33
|
```ts
|
|
23
34
|
import { createNodeFrameworkHost } from '@robota-sdk/agent-framework/node';
|
|
24
35
|
import { assembleProduct } from '@robota-sdk/agent-product';
|
|
25
|
-
import { createDefaultTools } from '@robota-sdk/agent-
|
|
26
|
-
import type { ICapabilityPack } from '@robota-sdk/agent-capability-pack';
|
|
36
|
+
import { createDefaultTools } from '@robota-sdk/agent-tools/defaults';
|
|
37
|
+
import type { ICapabilityPack } from '@robota-sdk/agent-product/capability-pack';
|
|
27
38
|
import type { IProviderDefinition } from '@robota-sdk/agent-core';
|
|
28
39
|
|
|
29
|
-
declare const providerDefinitions: readonly IProviderDefinition[]; // e.g. agent-builtin
|
|
40
|
+
declare const providerDefinitions: readonly IProviderDefinition[]; // e.g. from @robota-sdk/agent-provider/builtin
|
|
30
41
|
declare const acmeJiraPack: ICapabilityPack;
|
|
31
42
|
declare const cwd: string;
|
|
32
43
|
|
|
@@ -71,9 +82,9 @@ construction** to `agent-framework`'s `buildRuntimeSession` seam
|
|
|
71
82
|
on top, for inspection), and `buildRuntime(input)`.
|
|
72
83
|
- `IBuildRuntimeInput` — the session options the shell resolves and passes to `buildRuntime`.
|
|
73
84
|
|
|
74
|
-
Capability packs come from [
|
|
75
|
-
[
|
|
76
|
-
|
|
85
|
+
Capability packs come from the [`capability-pack`](docs/capability-pack.md) subpath;
|
|
86
|
+
[`coding`](docs/coding.md) is Robota's coding pack. See [`docs/SPEC.md`](./docs/SPEC.md) for the full
|
|
87
|
+
contract.
|
|
77
88
|
|
|
78
89
|
## License
|
|
79
90
|
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../capability-pack-Dc6eJ76H.cjs");exports.mergeCapabilityPacks=e.t;
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import { a as IRejectedCapability, c as TCompositionFieldPolicy, i as IMergedCapabilities, n as ICapabilityPack, o as IRejectedCapabilityPack, r as ICapabilityPackMetadata, s as TCapabilityKind, t as mergeCapabilityPacks } from "../index-BNDTmhmd.cjs";
|
|
2
|
+
export { type ICapabilityPack, type ICapabilityPackMetadata, type IMergedCapabilities, type IRejectedCapability, type IRejectedCapabilityPack, type TCapabilityKind, type TCompositionFieldPolicy, mergeCapabilityPacks };
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import { a as IRejectedCapability, c as TCompositionFieldPolicy, i as IMergedCapabilities, n as ICapabilityPack, o as IRejectedCapabilityPack, r as ICapabilityPackMetadata, s as TCapabilityKind, t as mergeCapabilityPacks } from "../index-BNDTmhmd.js";
|
|
2
|
+
export { type ICapabilityPack, type ICapabilityPackMetadata, type IMergedCapabilities, type IRejectedCapability, type IRejectedCapabilityPack, type TCapabilityKind, type TCompositionFieldPolicy, mergeCapabilityPacks };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{t as e}from"../capability-pack-D389p-Cv.js";export{e as mergeCapabilityPacks};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
function e(e){return{id:e.id,...e.title===void 0?{}:{title:e.title},...e.description===void 0?{}:{description:e.description}}}function t(t){let n=new Set,r=[],i=[],a=[];for(let o of t){if(n.has(o.id)){a.push({packId:o.id,reason:`duplicate pack id`});continue}n.add(o.id),r.push(o),i.push(e(o))}return{accepted:r,acceptedPacks:i,rejectedPacks:a}}function n(e,n){let i=[],{accepted:a,acceptedPacks:o,rejectedPacks:s}=t(n);return{merged:{commandModules:r({kind:`commandModule`,base:e,packs:a,contributionsOf:e=>e.commandModules??[],idOf:e=>e.name,baseCollisionReason:`collides with base command module`,duplicateReason:`duplicate commandModule id`,rejected:i}),tools:r({kind:`tool`,base:[],packs:a,contributionsOf:e=>e.tools??[],idOf:e=>e.getName(),baseCollisionReason:`collides with base tool`,duplicateReason:`duplicate tool id`,rejected:i}),subagents:r({kind:`subagent`,base:[],packs:a,contributionsOf:e=>e.subagents??[],idOf:e=>e.name,baseCollisionReason:`collides with base subagent`,duplicateReason:`duplicate subagent id`,rejected:i})},acceptedPacks:o,rejected:i,rejectedPacks:s}}function r(e){let{kind:t,base:n,packs:r,contributionsOf:i,idOf:a,baseCollisionReason:o,duplicateReason:s,rejected:c}=e,l=new Set,u=new Set,d=[];for(let e of n){let t=a(e);l.add(t),u.add(t),d.push(e)}for(let e of r)for(let n of i(e)){let r=a(n);if(l.has(r)){c.push({packId:e.id,kind:t,id:r,reason:u.has(r)?o:s});continue}l.add(r),d.push(n)}return d}export{n as t};
|
|
2
|
+
//# sourceMappingURL=capability-pack-D389p-Cv.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"capability-pack-D389p-Cv.js","names":[],"sources":["../src/capability-pack/merge-capability-packs.ts"],"sourcesContent":["import type {\n ICapabilityPack,\n ICapabilityPackMetadata,\n IMergedCapabilities,\n IRejectedCapability,\n IRejectedCapabilityPack,\n TCapabilityKind,\n TCompositionFieldPolicy,\n} from './capability-pack-types.js';\nimport type { FunctionTool } from '@robota-sdk/agent-core';\nimport type { IAgentDefinition, ICommandModule } from '@robota-sdk/agent-framework';\n\nexport const CAPABILITY_PACK_FIELD_POLICIES = {\n id: 'consumed-and-surfaced',\n title: 'surfaced',\n description: 'surfaced',\n commandModules: 'consumed',\n tools: 'consumed',\n subagents: 'consumed',\n} as const satisfies Record<keyof ICapabilityPack, TCompositionFieldPolicy>;\n\nfunction toPackMetadata(pack: ICapabilityPack): ICapabilityPackMetadata {\n return {\n id: pack.id,\n ...(pack.title !== undefined ? { title: pack.title } : {}),\n ...(pack.description !== undefined ? { description: pack.description } : {}),\n };\n}\n\nfunction selectUniquePacks(packs: readonly ICapabilityPack[]): {\n accepted: readonly ICapabilityPack[];\n acceptedPacks: readonly ICapabilityPackMetadata[];\n rejectedPacks: readonly IRejectedCapabilityPack[];\n} {\n const claimedPackIds = new Set<string>();\n const accepted: ICapabilityPack[] = [];\n const acceptedPacks: ICapabilityPackMetadata[] = [];\n const rejectedPacks: IRejectedCapabilityPack[] = [];\n for (const pack of packs) {\n if (claimedPackIds.has(pack.id)) {\n rejectedPacks.push({ packId: pack.id, reason: 'duplicate pack id' });\n continue;\n }\n claimedPackIds.add(pack.id);\n accepted.push(pack);\n acceptedPacks.push(toPackMetadata(pack));\n }\n return { accepted, acceptedPacks, rejectedPacks };\n}\n\n/**\n * Merge capability packs additively into the product's base command modules.\n *\n * The additive analog of `resolvePreset` — a PURE, deterministic, IO-free fold. Given a product's\n * `baseCommandModules` and its `packs` (in profile order), it produces the `base ⊕ pack` superset and a\n * `{ merged, rejected }` result (mirroring `IPresetRegistrationResult`).\n *\n * **ONE precedence order, no silent override:** `baseCommandModules` < packs in profile order. A later\n * contribution whose id duplicates an already-claimed id is REJECTED and reported in `rejected` — never\n * silently overridden (mirrors `partitionExternalPresets`' \"the first one wins / report rejection\").\n * Ids are claimed per bucket: command modules by `ICommandModule.name`, tools by `FunctionTool.getName()`,\n * subagents by `IAgentDefinition.name`.\n *\n * This merger produces only the base ⊕ pack **superset**. A preset's\n * `enabledCommandModules`/`disabledCommandModules` delta is applied AFTER this merge by the product shell's\n * command-setup (as it does today) — the two compose (this widens, the preset delta filters), they do not\n * fight.\n *\n * Pure w.r.t. its arguments: it reads only its inputs and returns fresh arrays; it mutates neither\n * `baseCommandModules` nor any pack.\n */\nexport function mergeCapabilityPacks(\n baseCommandModules: readonly ICommandModule[],\n packs: readonly ICapabilityPack[],\n): IMergedCapabilities {\n const rejected: IRejectedCapability[] = [];\n const { accepted, acceptedPacks, rejectedPacks } = selectUniquePacks(packs);\n\n const commandModules = mergeBucket<ICommandModule>({\n kind: 'commandModule',\n base: baseCommandModules,\n packs: accepted,\n contributionsOf: (pack) => pack.commandModules ?? [],\n idOf: (module) => module.name,\n baseCollisionReason: 'collides with base command module',\n duplicateReason: 'duplicate commandModule id',\n rejected,\n });\n\n const tools = mergeBucket<FunctionTool>({\n kind: 'tool',\n base: [],\n packs: accepted,\n contributionsOf: (pack) => pack.tools ?? [],\n idOf: (tool) => tool.getName(),\n baseCollisionReason: 'collides with base tool',\n duplicateReason: 'duplicate tool id',\n rejected,\n });\n\n const subagents = mergeBucket<IAgentDefinition>({\n kind: 'subagent',\n base: [],\n packs: accepted,\n contributionsOf: (pack) => pack.subagents ?? [],\n idOf: (agent) => agent.name,\n baseCollisionReason: 'collides with base subagent',\n duplicateReason: 'duplicate subagent id',\n rejected,\n });\n\n return {\n merged: { commandModules, tools, subagents },\n acceptedPacks,\n rejected,\n rejectedPacks,\n };\n}\n\ninterface IMergeBucketArgs<T> {\n kind: TCapabilityKind;\n /** Already-present base entries (own the namespace first). */\n base: readonly T[];\n /** Accepted packs in profile order and the bucket projection for each pack. */\n packs: readonly ICapabilityPack[];\n contributionsOf: (pack: ICapabilityPack) => readonly T[];\n idOf: (entry: T) => string;\n baseCollisionReason: string;\n duplicateReason: string;\n rejected: IRejectedCapability[];\n}\n\n/**\n * Fold one capability bucket: base entries claim the namespace first, then each pack's contributions in\n * order. A contribution whose id is already claimed is pushed to `rejected` (base collision vs pack-vs-pack\n * duplicate carry distinct reasons) and dropped from the merged output. First registration always wins.\n */\nfunction mergeBucket<T>(args: IMergeBucketArgs<T>): readonly T[] {\n const {\n kind,\n base,\n packs,\n contributionsOf,\n idOf,\n baseCollisionReason,\n duplicateReason,\n rejected,\n } = args;\n const claimed = new Set<string>();\n const baseIds = new Set<string>();\n const merged: T[] = [];\n\n for (const entry of base) {\n const id = idOf(entry);\n claimed.add(id);\n baseIds.add(id);\n merged.push(entry);\n }\n\n for (const pack of packs) {\n for (const entry of contributionsOf(pack)) {\n const id = idOf(entry);\n if (claimed.has(id)) {\n rejected.push({\n packId: pack.id,\n kind,\n id,\n reason: baseIds.has(id) ? baseCollisionReason : duplicateReason,\n });\n continue;\n }\n claimed.add(id);\n merged.push(entry);\n }\n }\n\n return merged;\n}\n"],"mappings":"AAqBA,SAAS,EAAe,EAAgD,CACtE,MAAO,CACL,GAAI,EAAK,GACT,GAAI,EAAK,QAAU,IAAA,GAAoC,CAAC,EAAzB,CAAE,MAAO,EAAK,KAAM,EACnD,GAAI,EAAK,cAAgB,IAAA,GAAgD,CAAC,EAArC,CAAE,YAAa,EAAK,WAAY,CACvE,CACF,CAEA,SAAS,EAAkB,EAIzB,CACA,IAAM,EAAiB,IAAI,IACrB,EAA8B,CAAC,EAC/B,EAA2C,CAAC,EAC5C,EAA2C,CAAC,EAClD,IAAK,IAAM,KAAQ,EAAO,CACxB,GAAI,EAAe,IAAI,EAAK,EAAE,EAAG,CAC/B,EAAc,KAAK,CAAE,OAAQ,EAAK,GAAI,OAAQ,mBAAoB,CAAC,EACnE,QACF,CACA,EAAe,IAAI,EAAK,EAAE,EAC1B,EAAS,KAAK,CAAI,EAClB,EAAc,KAAK,EAAe,CAAI,CAAC,CACzC,CACA,MAAO,CAAE,WAAU,gBAAe,eAAc,CAClD,CAuBA,SAAgB,EACd,EACA,EACqB,CACrB,IAAM,EAAkC,CAAC,EACnC,CAAE,WAAU,gBAAe,iBAAkB,EAAkB,CAAK,EAmC1E,MAAO,CACL,OAAQ,CAAE,eAlCW,EAA4B,CACjD,KAAM,gBACN,KAAM,EACN,MAAO,EACP,gBAAkB,GAAS,EAAK,gBAAkB,CAAC,EACnD,KAAO,GAAW,EAAO,KACzB,oBAAqB,oCACrB,gBAAiB,6BACjB,UACF,CAyByB,EAAG,MAvBd,EAA0B,CACtC,KAAM,OACN,KAAM,CAAC,EACP,MAAO,EACP,gBAAkB,GAAS,EAAK,OAAS,CAAC,EAC1C,KAAO,GAAS,EAAK,QAAQ,EAC7B,oBAAqB,0BACrB,gBAAiB,oBACjB,UACF,CAcgC,EAAG,UAZjB,EAA8B,CAC9C,KAAM,WACN,KAAM,CAAC,EACP,MAAO,EACP,gBAAkB,GAAS,EAAK,WAAa,CAAC,EAC9C,KAAO,GAAU,EAAM,KACvB,oBAAqB,8BACrB,gBAAiB,wBACjB,UACF,CAG2C,CAAE,EAC3C,gBACA,WACA,eACF,CACF,CAoBA,SAAS,EAAe,EAAyC,CAC/D,GAAM,CACJ,OACA,OACA,QACA,kBACA,OACA,sBACA,kBACA,YACE,EACE,EAAU,IAAI,IACd,EAAU,IAAI,IACd,EAAc,CAAC,EAErB,IAAK,IAAM,KAAS,EAAM,CACxB,IAAM,EAAK,EAAK,CAAK,EACrB,EAAQ,IAAI,CAAE,EACd,EAAQ,IAAI,CAAE,EACd,EAAO,KAAK,CAAK,CACnB,CAEA,IAAK,IAAM,KAAQ,EACjB,IAAK,IAAM,KAAS,EAAgB,CAAI,EAAG,CACzC,IAAM,EAAK,EAAK,CAAK,EACrB,GAAI,EAAQ,IAAI,CAAE,EAAG,CACnB,EAAS,KAAK,CACZ,OAAQ,EAAK,GACb,OACA,KACA,OAAQ,EAAQ,IAAI,CAAE,EAAI,EAAsB,CAClD,CAAC,EACD,QACF,CACA,EAAQ,IAAI,CAAE,EACd,EAAO,KAAK,CAAK,CACnB,CAGF,OAAO,CACT"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
function e(e){return{id:e.id,...e.title===void 0?{}:{title:e.title},...e.description===void 0?{}:{description:e.description}}}function t(t){let n=new Set,r=[],i=[],a=[];for(let o of t){if(n.has(o.id)){a.push({packId:o.id,reason:`duplicate pack id`});continue}n.add(o.id),r.push(o),i.push(e(o))}return{accepted:r,acceptedPacks:i,rejectedPacks:a}}function n(e,n){let i=[],{accepted:a,acceptedPacks:o,rejectedPacks:s}=t(n);return{merged:{commandModules:r({kind:`commandModule`,base:e,packs:a,contributionsOf:e=>e.commandModules??[],idOf:e=>e.name,baseCollisionReason:`collides with base command module`,duplicateReason:`duplicate commandModule id`,rejected:i}),tools:r({kind:`tool`,base:[],packs:a,contributionsOf:e=>e.tools??[],idOf:e=>e.getName(),baseCollisionReason:`collides with base tool`,duplicateReason:`duplicate tool id`,rejected:i}),subagents:r({kind:`subagent`,base:[],packs:a,contributionsOf:e=>e.subagents??[],idOf:e=>e.name,baseCollisionReason:`collides with base subagent`,duplicateReason:`duplicate subagent id`,rejected:i})},acceptedPacks:o,rejected:i,rejectedPacks:s}}function r(e){let{kind:t,base:n,packs:r,contributionsOf:i,idOf:a,baseCollisionReason:o,duplicateReason:s,rejected:c}=e,l=new Set,u=new Set,d=[];for(let e of n){let t=a(e);l.add(t),u.add(t),d.push(e)}for(let e of r)for(let n of i(e)){let r=a(n);if(l.has(r)){c.push({packId:e.id,kind:t,id:r,reason:u.has(r)?o:s});continue}l.add(r),d.push(n)}return d}Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return n}});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../command-DZUsxxG3.cjs"),t=require("../node-BgupUyg0.cjs");let n=require("@robota-sdk/agent-framework"),r=require("@robota-sdk/agent-framework/node"),i=require("@robota-sdk/agent-tools/defaults");function a(a){return{id:`coding`,title:`Coding`,description:`Built-in coding capability: file/shell tools, /shell + /editor + /git commands, and the coding subagents.`,tools:(0,i.createDefaultTools)({cwd:a.cwd,httpUserAgent:a.httpUserAgent,...a.shellExecutable===void 0?{}:{shellExecutable:a.shellExecutable},...a.sandboxClient?{sandboxClient:a.sandboxClient}:{},...a.editorFiles?{editorFiles:a.editorFiles}:{}}),commandModules:[t.o(a.shellExecutable),t.f(a.editorTemporaryDirectoryPrefix,a.editorUnavailableMessage),e.En({port:(0,r.createGitProcess)()})],subagents:n.BUILT_IN_AGENTS}}exports.createCodingPack=a;
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
import { n as ICapabilityPack } from "../index-BNDTmhmd.cjs";
|
|
2
|
+
import { IEditorFileAccess, ISandboxClient } from "@robota-sdk/agent-tools";
|
|
3
|
+
//#region src/coding/coding-pack.d.ts
|
|
4
|
+
/**
|
|
5
|
+
* The session context agent's coding tools are bound to.
|
|
6
|
+
*
|
|
7
|
+
* `cwd` is **required, not optional** — and that is the whole point of this factory. `agent-tools`'
|
|
8
|
+
* `checkPathWithinCwd` USED TO BE a no-op when `cwd` was `undefined`, so file tools constructed with no
|
|
9
|
+
* options carried a DISARMED working-directory guard: their `Read` returned `/etc/hostname`. That was
|
|
10
|
+
* inert while the framework's own context-bound default tier always won a name
|
|
11
|
+
* collision. Once a product could hand the entire tool surface to its packs (`defaultTools: []`), a
|
|
12
|
+
* context-free pack became an unsandboxed `Read`/`Write`/`Edit`.
|
|
13
|
+
*
|
|
14
|
+
* The layer below is fixed too: the guard refuses when no root is configured, and the tool
|
|
15
|
+
* factories require `cwd` themselves. This requirement is therefore no longer load-bearing on its own —
|
|
16
|
+
* it stays because the scoping decision should be
|
|
17
|
+
* impossible to forget at every layer, not only the lowest one.
|
|
18
|
+
*/
|
|
19
|
+
interface ICodingPackOptions {
|
|
20
|
+
/** Product-host shell choice for tools and the interactive /shell command. */
|
|
21
|
+
shellExecutable?: string;
|
|
22
|
+
/** HTTP identity selected by the product host. */
|
|
23
|
+
httpUserAgent?: string;
|
|
24
|
+
/** Product-owned prefix for the interactive editor's temporary directory. */
|
|
25
|
+
editorTemporaryDirectoryPrefix?: string;
|
|
26
|
+
/** Keep the command visible but refuse a host editor that would persist a sensitive draft. */
|
|
27
|
+
editorUnavailableMessage?: string;
|
|
28
|
+
/**
|
|
29
|
+
* Working-directory root the host file tools (`Read`/`Write`/`Edit`) are restricted to. Required: see
|
|
30
|
+
* the interface note above. Pass the same value the session is assembled with.
|
|
31
|
+
*/
|
|
32
|
+
cwd: string;
|
|
33
|
+
/**
|
|
34
|
+
* Optional provider sandbox client. Shell commands always run through it; file tools do only when its
|
|
35
|
+
* filesystem is `separate` (then the sandbox is the isolation boundary and the host-only search tools
|
|
36
|
+
* are withheld). With a `shared` filesystem, file tools stay on the host under the path guard.
|
|
37
|
+
*/
|
|
38
|
+
sandboxClient?: ISandboxClient;
|
|
39
|
+
/**
|
|
40
|
+
* An editor that has the workspace open, asked at each call: the host file tools read and write
|
|
41
|
+
* through what it offers. Absent, or answering `undefined`, means the disk.
|
|
42
|
+
*/
|
|
43
|
+
editorFiles?: () => IEditorFileAccess | undefined;
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Build agent's coding capability as a single {@link ICapabilityPack}, bound to one session context.
|
|
47
|
+
*
|
|
48
|
+
* This is the additive-axis proof and agent's first capability pack: a pack can bundle
|
|
49
|
+
* agent's real coding capability (tools + command modules + subagents) and be composed additively by
|
|
50
|
+
* `assembleProduct` on top of any product's base — and can OWN the product's tool surface
|
|
51
|
+
* outright when the profile suppresses the framework tier with `defaultTools: []`.
|
|
52
|
+
*
|
|
53
|
+
* - **tools** — `createDefaultTools()` from `@robota-sdk/agent-tools/defaults`, CONSUMED rather than
|
|
54
|
+
* mirrored. That set is shell/bash/read/write/edit/glob/grep/webFetch/askUserQuestion,
|
|
55
|
+
* all tools that need no adapter, credential or external service. The list used to be rebuilt
|
|
56
|
+
* here from the `@robota-sdk/agent-tools` factories and held to the defaults by a NAME-equality test
|
|
57
|
+
* — a pin that could not fail, because comparing names
|
|
58
|
+
* cannot distinguish a pack-composed surface from an imported-default one when the two are pinned.
|
|
59
|
+
* The relationship is structural now, so there is no drift left to pin.
|
|
60
|
+
* - **commandModules** — the coding command modules: `/shell`, `/editor` and `/git` (the capability-level
|
|
61
|
+
* command modules, distinct from product-shell/settings/provider command infrastructure).
|
|
62
|
+
* - **subagents** — agent's built-in coding subagents (`general-purpose`, `Explore`, `Plan`).
|
|
63
|
+
*
|
|
64
|
+
* This pack contributes only when a product profile lists it (opt-in); every contributed command/tool runs
|
|
65
|
+
* only through the permission-gated runtime at call time.
|
|
66
|
+
*
|
|
67
|
+
* **Per-call instances, deliberately.** Each call builds fresh tool and command-module objects bound to the
|
|
68
|
+
* supplied context, so two products assembled in one process get independently-scoped file tools. There is
|
|
69
|
+
* no module-level singleton: a shared constant could only ever be context-free, which is exactly the hazard
|
|
70
|
+
* this factory exists to remove.
|
|
71
|
+
*/
|
|
72
|
+
declare function createCodingPack(options: ICodingPackOptions): ICapabilityPack;
|
|
73
|
+
//#endregion
|
|
74
|
+
export { type ICodingPackOptions, createCodingPack };
|
|
75
|
+
//# sourceMappingURL=index.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.cts","names":[],"sources":["../../src/coding/coding-pack.ts"],"mappings":";;;;;;;;;;;;;;;;;;UA2BiB;;EAEf;;EAEA;;EAEA;;EAEA;;;;;EAKA;;;;;;EAMA,gBAAgB;;;;;EAKhB,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBA8BN,iBAAiB,SAAS,qBAAqB"}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
import { n as ICapabilityPack } from "../index-BNDTmhmd.js";
|
|
2
|
+
import { IEditorFileAccess, ISandboxClient } from "@robota-sdk/agent-tools";
|
|
3
|
+
//#region src/coding/coding-pack.d.ts
|
|
4
|
+
/**
|
|
5
|
+
* The session context agent's coding tools are bound to.
|
|
6
|
+
*
|
|
7
|
+
* `cwd` is **required, not optional** — and that is the whole point of this factory. `agent-tools`'
|
|
8
|
+
* `checkPathWithinCwd` USED TO BE a no-op when `cwd` was `undefined`, so file tools constructed with no
|
|
9
|
+
* options carried a DISARMED working-directory guard: their `Read` returned `/etc/hostname`. That was
|
|
10
|
+
* inert while the framework's own context-bound default tier always won a name
|
|
11
|
+
* collision. Once a product could hand the entire tool surface to its packs (`defaultTools: []`), a
|
|
12
|
+
* context-free pack became an unsandboxed `Read`/`Write`/`Edit`.
|
|
13
|
+
*
|
|
14
|
+
* The layer below is fixed too: the guard refuses when no root is configured, and the tool
|
|
15
|
+
* factories require `cwd` themselves. This requirement is therefore no longer load-bearing on its own —
|
|
16
|
+
* it stays because the scoping decision should be
|
|
17
|
+
* impossible to forget at every layer, not only the lowest one.
|
|
18
|
+
*/
|
|
19
|
+
interface ICodingPackOptions {
|
|
20
|
+
/** Product-host shell choice for tools and the interactive /shell command. */
|
|
21
|
+
shellExecutable?: string;
|
|
22
|
+
/** HTTP identity selected by the product host. */
|
|
23
|
+
httpUserAgent?: string;
|
|
24
|
+
/** Product-owned prefix for the interactive editor's temporary directory. */
|
|
25
|
+
editorTemporaryDirectoryPrefix?: string;
|
|
26
|
+
/** Keep the command visible but refuse a host editor that would persist a sensitive draft. */
|
|
27
|
+
editorUnavailableMessage?: string;
|
|
28
|
+
/**
|
|
29
|
+
* Working-directory root the host file tools (`Read`/`Write`/`Edit`) are restricted to. Required: see
|
|
30
|
+
* the interface note above. Pass the same value the session is assembled with.
|
|
31
|
+
*/
|
|
32
|
+
cwd: string;
|
|
33
|
+
/**
|
|
34
|
+
* Optional provider sandbox client. Shell commands always run through it; file tools do only when its
|
|
35
|
+
* filesystem is `separate` (then the sandbox is the isolation boundary and the host-only search tools
|
|
36
|
+
* are withheld). With a `shared` filesystem, file tools stay on the host under the path guard.
|
|
37
|
+
*/
|
|
38
|
+
sandboxClient?: ISandboxClient;
|
|
39
|
+
/**
|
|
40
|
+
* An editor that has the workspace open, asked at each call: the host file tools read and write
|
|
41
|
+
* through what it offers. Absent, or answering `undefined`, means the disk.
|
|
42
|
+
*/
|
|
43
|
+
editorFiles?: () => IEditorFileAccess | undefined;
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Build agent's coding capability as a single {@link ICapabilityPack}, bound to one session context.
|
|
47
|
+
*
|
|
48
|
+
* This is the additive-axis proof and agent's first capability pack: a pack can bundle
|
|
49
|
+
* agent's real coding capability (tools + command modules + subagents) and be composed additively by
|
|
50
|
+
* `assembleProduct` on top of any product's base — and can OWN the product's tool surface
|
|
51
|
+
* outright when the profile suppresses the framework tier with `defaultTools: []`.
|
|
52
|
+
*
|
|
53
|
+
* - **tools** — `createDefaultTools()` from `@robota-sdk/agent-tools/defaults`, CONSUMED rather than
|
|
54
|
+
* mirrored. That set is shell/bash/read/write/edit/glob/grep/webFetch/askUserQuestion,
|
|
55
|
+
* all tools that need no adapter, credential or external service. The list used to be rebuilt
|
|
56
|
+
* here from the `@robota-sdk/agent-tools` factories and held to the defaults by a NAME-equality test
|
|
57
|
+
* — a pin that could not fail, because comparing names
|
|
58
|
+
* cannot distinguish a pack-composed surface from an imported-default one when the two are pinned.
|
|
59
|
+
* The relationship is structural now, so there is no drift left to pin.
|
|
60
|
+
* - **commandModules** — the coding command modules: `/shell`, `/editor` and `/git` (the capability-level
|
|
61
|
+
* command modules, distinct from product-shell/settings/provider command infrastructure).
|
|
62
|
+
* - **subagents** — agent's built-in coding subagents (`general-purpose`, `Explore`, `Plan`).
|
|
63
|
+
*
|
|
64
|
+
* This pack contributes only when a product profile lists it (opt-in); every contributed command/tool runs
|
|
65
|
+
* only through the permission-gated runtime at call time.
|
|
66
|
+
*
|
|
67
|
+
* **Per-call instances, deliberately.** Each call builds fresh tool and command-module objects bound to the
|
|
68
|
+
* supplied context, so two products assembled in one process get independently-scoped file tools. There is
|
|
69
|
+
* no module-level singleton: a shared constant could only ever be context-free, which is exactly the hazard
|
|
70
|
+
* this factory exists to remove.
|
|
71
|
+
*/
|
|
72
|
+
declare function createCodingPack(options: ICodingPackOptions): ICapabilityPack;
|
|
73
|
+
//#endregion
|
|
74
|
+
export { type ICodingPackOptions, createCodingPack };
|
|
75
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","names":[],"sources":["../../src/coding/coding-pack.ts"],"mappings":";;;;;;;;;;;;;;;;;;UA2BiB;;EAEf;;EAEA;;EAEA;;EAEA;;;;;EAKA;;;;;;EAMA,gBAAgB;;;;;EAKhB,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBA8BN,iBAAiB,SAAS,qBAAqB"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{En as e}from"../command-DynprfoA.js";import{f as t,o as n}from"../node-Cw2VT1HG.js";import{BUILT_IN_AGENTS as r}from"@robota-sdk/agent-framework";import{createGitProcess as i}from"@robota-sdk/agent-framework/node";import{createDefaultTools as a}from"@robota-sdk/agent-tools/defaults";function o(o){return{id:`coding`,title:`Coding`,description:`Built-in coding capability: file/shell tools, /shell + /editor + /git commands, and the coding subagents.`,tools:a({cwd:o.cwd,httpUserAgent:o.httpUserAgent,...o.shellExecutable===void 0?{}:{shellExecutable:o.shellExecutable},...o.sandboxClient?{sandboxClient:o.sandboxClient}:{},...o.editorFiles?{editorFiles:o.editorFiles}:{}}),commandModules:[n(o.shellExecutable),t(o.editorTemporaryDirectoryPrefix,o.editorUnavailableMessage),e({port:i()})],subagents:r}}export{o as createCodingPack};
|
|
2
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../../src/coding/coding-pack.ts"],"sourcesContent":["import { createGitCommandModule } from '../command/index.js';\nimport {\n createEditorCommandModule,\n createShellCommandModule,\n} from '../command/node.js';\nimport { BUILT_IN_AGENTS } from '@robota-sdk/agent-framework';\nimport { createGitProcess } from '@robota-sdk/agent-framework/node';\nimport { createDefaultTools } from '@robota-sdk/agent-tools/defaults';\n\nimport type { ICapabilityPack } from '../capability-pack/index.js';\nimport type { IEditorFileAccess, ISandboxClient } from '@robota-sdk/agent-tools';\n\n/**\n * The session context agent's coding tools are bound to.\n *\n * `cwd` is **required, not optional** — and that is the whole point of this factory. `agent-tools`'\n * `checkPathWithinCwd` USED TO BE a no-op when `cwd` was `undefined`, so file tools constructed with no\n * options carried a DISARMED working-directory guard: their `Read` returned `/etc/hostname`. That was\n * inert while the framework's own context-bound default tier always won a name\n * collision. Once a product could hand the entire tool surface to its packs (`defaultTools: []`), a\n * context-free pack became an unsandboxed `Read`/`Write`/`Edit`.\n *\n * The layer below is fixed too: the guard refuses when no root is configured, and the tool\n * factories require `cwd` themselves. This requirement is therefore no longer load-bearing on its own —\n * it stays because the scoping decision should be\n * impossible to forget at every layer, not only the lowest one.\n */\nexport interface ICodingPackOptions {\n /** Product-host shell choice for tools and the interactive /shell command. */\n shellExecutable?: string;\n /** HTTP identity selected by the product host. */\n httpUserAgent?: string;\n /** Product-owned prefix for the interactive editor's temporary directory. */\n editorTemporaryDirectoryPrefix?: string;\n /** Keep the command visible but refuse a host editor that would persist a sensitive draft. */\n editorUnavailableMessage?: string;\n /**\n * Working-directory root the host file tools (`Read`/`Write`/`Edit`) are restricted to. Required: see\n * the interface note above. Pass the same value the session is assembled with.\n */\n cwd: string;\n /**\n * Optional provider sandbox client. Shell commands always run through it; file tools do only when its\n * filesystem is `separate` (then the sandbox is the isolation boundary and the host-only search tools\n * are withheld). With a `shared` filesystem, file tools stay on the host under the path guard.\n */\n sandboxClient?: ISandboxClient;\n /**\n * An editor that has the workspace open, asked at each call: the host file tools read and write\n * through what it offers. Absent, or answering `undefined`, means the disk.\n */\n editorFiles?: () => IEditorFileAccess | undefined;\n}\n\n/**\n * Build agent's coding capability as a single {@link ICapabilityPack}, bound to one session context.\n *\n * This is the additive-axis proof and agent's first capability pack: a pack can bundle\n * agent's real coding capability (tools + command modules + subagents) and be composed additively by\n * `assembleProduct` on top of any product's base — and can OWN the product's tool surface\n * outright when the profile suppresses the framework tier with `defaultTools: []`.\n *\n * - **tools** — `createDefaultTools()` from `@robota-sdk/agent-tools/defaults`, CONSUMED rather than\n * mirrored. That set is shell/bash/read/write/edit/glob/grep/webFetch/askUserQuestion,\n * all tools that need no adapter, credential or external service. The list used to be rebuilt\n * here from the `@robota-sdk/agent-tools` factories and held to the defaults by a NAME-equality test\n * — a pin that could not fail, because comparing names\n * cannot distinguish a pack-composed surface from an imported-default one when the two are pinned.\n * The relationship is structural now, so there is no drift left to pin.\n * - **commandModules** — the coding command modules: `/shell`, `/editor` and `/git` (the capability-level\n * command modules, distinct from product-shell/settings/provider command infrastructure).\n * - **subagents** — agent's built-in coding subagents (`general-purpose`, `Explore`, `Plan`).\n *\n * This pack contributes only when a product profile lists it (opt-in); every contributed command/tool runs\n * only through the permission-gated runtime at call time.\n *\n * **Per-call instances, deliberately.** Each call builds fresh tool and command-module objects bound to the\n * supplied context, so two products assembled in one process get independently-scoped file tools. There is\n * no module-level singleton: a shared constant could only ever be context-free, which is exactly the hazard\n * this factory exists to remove.\n */\nexport function createCodingPack(options: ICodingPackOptions): ICapabilityPack {\n const toolOptions = {\n cwd: options.cwd,\n httpUserAgent: options.httpUserAgent,\n ...(options.shellExecutable !== undefined ? { shellExecutable: options.shellExecutable } : {}),\n ...(options.sandboxClient ? { sandboxClient: options.sandboxClient } : {}),\n ...(options.editorFiles ? { editorFiles: options.editorFiles } : {}),\n };\n\n return {\n id: 'coding',\n title: 'Coding',\n description:\n 'Built-in coding capability: file/shell tools, /shell + /editor + /git commands, and the coding subagents.',\n // The always-present default set, consumed from its owner rather than rebuilt here.\n //\n // This list used to be hand-maintained, identical to `createDefaultTools()`'s always-present\n // tier, and the two were held together by a test asserting their NAMES matched. That pin is what\n // made it unable to fail: comparing tool names cannot tell a\n // pack-composed surface from an imported-default one when the pack is pinned to the defaults.\n // Consuming the set makes the relationship structural, so there is nothing left to drift.\n //\n // The default set holds no tool that needs an adapter, a credential or an external service, so\n // neither does this pack. The sandbox still holds — `cwd` is REQUIRED here, so the file-tool\n // guard cannot be disarmed by omission, and the leaf threads it into every tool it builds.\n tools: createDefaultTools(toolOptions),\n commandModules: [\n createShellCommandModule(options.shellExecutable),\n createEditorCommandModule(\n options.editorTemporaryDirectoryPrefix,\n options.editorUnavailableMessage,\n ),\n createGitCommandModule({ port: createGitProcess() }),\n ],\n subagents: BUILT_IN_AGENTS,\n };\n}\n"],"mappings":"mSAiFA,SAAgB,EAAiB,EAA8C,CAS7E,MAAO,CACL,GAAI,SACJ,MAAO,SACP,YACE,4GAYF,MAAO,EAAmB,CAvB1B,IAAK,EAAQ,IACb,cAAe,EAAQ,cACvB,GAAI,EAAQ,kBAAoB,IAAA,GAA2D,CAAC,EAAhD,CAAE,gBAAiB,EAAQ,eAAgB,EACvF,GAAI,EAAQ,cAAgB,CAAE,cAAe,EAAQ,aAAc,EAAI,CAAC,EACxE,GAAI,EAAQ,YAAc,CAAE,YAAa,EAAQ,WAAY,EAAI,CAAC,CAmB9B,CAAC,EACrC,eAAgB,CACd,EAAyB,EAAQ,eAAe,EAChD,EACE,EAAQ,+BACR,EAAQ,wBACV,EACA,EAAuB,CAAE,KAAM,EAAiB,CAAE,CAAC,CACrD,EACA,UAAW,CACb,CACF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require("../command-DZUsxxG3.cjs"),t=require("../theme-command-module-DYJhjKuI.cjs");exports.ADVISOR_SETTING_KEY=e.zn,exports.AdvisorCommandSource=e.In,exports.AgentCommandSource=e.pr,exports.BackgroundCommandSource=e.lr,exports.CLEAR_COMMAND_MESSAGE=e.A,exports.CompactCommandSource=e.ar,exports.ContextCommandSource=e.tr,exports.DoctorCommandSource=e.Vn,exports.EffortCommandSource=e.Mn,exports.ExitCommandSource=e.On,exports.GOAL_COMMAND_DESCRIPTION=e.Sn,exports.GitCommandSource=e.wn,exports.GoalCommandSource=e.yn,exports.HandoffCommandSource=e.hn,exports.HelpCommandSource=e.dn,exports.KeybindingsCommandSource=t.a,exports.LanguageCommandSource=e.on,exports.MCPActivationCommandSource=e.$t,exports.MemoryCommandSource=e.Yt,exports.ModeCommandSource=e.Wt,exports.ModelCommandSource=e.Bt,exports.OutputStyleCommandSource=e.jt,exports.PermissionsCommandSource=e.Ot,exports.PluginManagerCommandSource=e.xt,exports.PresetCommandSource=e._t,exports.ProviderCommandSource=e.rt,exports.RemoteControlCommandSource=e.Z,exports.RewindCommandSource=e.G,exports.SANDBOX_MODES=e.Lt,exports.SKILLS_COMMAND_DESCRIPTION=e.v,exports.STATUSLINE_USAGE=e.p,exports.STORAGE_REPAIR_ID=e.Kn,exports.SandboxCommandSource=e.Ft,exports.ScheduleCommandSource=e.I,exports.SessionCommandSource=e.C,exports.SettingsCommandSource=e.b,exports.SkillsCommandSource=e.h,exports.StatusLineCommandSource=e.u,exports.ThemeCommandSource=t.t,exports.USER_LOCAL_COMMAND_ARGUMENT_HINT=e.s,exports.USER_LOCAL_COMMAND_DESCRIPTION=e.c,exports.USER_LOCAL_COMMAND_USAGE=e.l,exports.UserLocalCommandSource=e.n,exports.applyDoctorRepair=e.qn,exports.buildDoctorReport=e.Wn,exports.collectSettingsSecrets=e.Zn,exports.createAdvisorCommandEntry=e.Ln,exports.createAdvisorCommandModule=e.Rn,exports.createAgentCommandEntry=e.mr,exports.createAgentCommandModule=e.hr,exports.createAgentSystemCommand=e.gr,exports.createBackgroundCommandEntry=e.ur,exports.createBackgroundCommandModule=e.dr,exports.createClearCommandEntry=e.w,exports.createCompactCommandEntry=e.or,exports.createCompactCommandModule=e.sr,exports.createContextCommandEntry=e.nr,exports.createContextCommandModule=e.rr,exports.createCostCommandEntry=e.T,exports.createDefaultCommandModules=e.t,exports.createDevicesCommandModule=e.er,exports.createDoctorCommandEntry=e.Hn,exports.createDoctorCommandModule=e.Un,exports.createEffortCommandEntry=e.Nn,exports.createEffortCommandModule=e.Pn,exports.createExitCommandEntry=e.kn,exports.createExitCommandModule=e.An,exports.createGitCommandEntry=e.Tn,exports.createGitCommandModule=e.En,exports.createGoalCommandEntry=e.bn,exports.createGoalCommandModule=e.xn,exports.createHandoffCommandEntry=e.gn,exports.createHandoffCommandModule=e._n,exports.createHelpCommandEntry=e.fn,exports.createHelpCommandModule=e.pn,exports.createKeyCustodyCommandModule=e.un,exports.createKeybindingsCommandEntry=t.o,exports.createKeybindingsCommandModule=t.s,exports.createLanguageCommandEntry=e.sn,exports.createLanguageCommandModule=e.cn,exports.createLoopCommandEntry=e.L,exports.createMCPActivationCommandEntry=e.en,exports.createMCPActivationCommandModule=e.tn,exports.createMemoryCommandEntry=e.Xt,exports.createMemoryCommandModule=e.Zt,exports.createModeCommandEntry=e.Gt,exports.createModeCommandModule=e.Kt,exports.createModelCommandEntry=e.Vt,exports.createModelCommandModule=e.Ht,exports.createMonitorCommandEntry=e.R,exports.createOutputStyleCommandEntry=e.Mt,exports.createOutputStyleCommandModule=e.Nt,exports.createPermissionsCommandEntry=e.kt,exports.createPermissionsCommandModule=e.At,exports.createPlanCommandModule=e.Dt,exports.createPluginCommandEntry=e.St,exports.createPluginCommandModule=e.Ct,exports.createPresetCommandEntry=e.vt,exports.createPresetCommandModule=e.yt,exports.createProviderCommandEntry=e.it,exports.createProviderCommandModule=e.at,exports.createProviderSetupFlow=e.st,exports.createReloadPluginsCommandEntry=e.wt,exports.createRemoteControlCommandEntry=e.Q,exports.createRemoteControlCommandModule=e.$,exports.createRenameCommandEntry=e.E,exports.createResetCommandEntry=e.J,exports.createResetCommandModule=e.Y,exports.createResumeCommandEntry=e.D,exports.createRewindCommandModule=e.K,exports.createSandboxCommandModule=e.It,exports.createScheduleCommandEntry=e.z,exports.createScheduleCommandModule=e.B,exports.createSessionCommandModule=e.O,exports.createSettingsCommandEntry=e.x,exports.createSettingsCommandModule=e.S,exports.createSkillsCommandEntry=e.g,exports.createSkillsCommandModule=e._,exports.createStatusLineCommandEntry=e.d,exports.createStatusLineCommandModule=e.f,exports.createThemeCommandEntry=t.n,exports.createThemeCommandModule=t.r,exports.createUserLocalCommandEntry=e.r,exports.createUserLocalCommandModule=e.i,exports.createValidateSessionCommandEntry=e.k,exports.doctorRepairAllowlist=e.Jn,exports.ensureProviderConfig=e.tt,exports.executeAdvisorCommand=e.Bn,exports.executeAgentCommand=e._r,exports.executeBackgroundCommand=e.fr,exports.executeClearCommand=e.j,exports.executeCompactCommand=e.cr,exports.executeContextCommand=e.ir,exports.executeCostCommand=e.M,exports.executeEffortCommand=e.Fn,exports.executeExitCommand=e.jn,exports.executeGitCommand=e.Dn,exports.executeGoalCommand=e.Cn,exports.executeHandoffCommand=e.vn,exports.executeHelpCommand=e.mn,exports.executeLanguageCommand=e.ln,exports.executeLoopCommand=e.W,exports.executeMCPActivationCommand=e.nn,exports.executeMemoryCommand=e.Qt,exports.executeModeCommand=e.qt,exports.executeModelCommand=e.Ut,exports.executeMonitorCommand=e.V,exports.executeOutputStyleCommand=e.Pt,exports.executePermissionsCommand=e.Jt,exports.executePluginCommand=e.Tt,exports.executePresetCommand=e.bt,exports.executeProviderCommand=e.ot,exports.executeReloadPluginsCommand=e.Et,exports.executeRemoteControlCommand=e.et,exports.executeRenameCommand=e.N,exports.executeResetCommand=e.X,exports.executeResumeCommand=e.P,exports.executeRewindCommand=e.q,exports.executeSandboxCommand=e.Rt,exports.executeScheduleCommand=e.H,exports.executeSkillsCommand=e.y,exports.executeStatusLineCommand=e.m,exports.executeThemeCommand=t.i,exports.executeUserLocalCommand=e.a,exports.executeUserLocalDirectCommand=e.o,exports.executeValidateSessionCommand=e.F,exports.formatProviderSetupChoiceLabel=e.ct,exports.formatProviderSetupHelpLinks=e.lt,exports.formatProviderSetupPromptLabel=e.ut,exports.formatProviderSetupSelectionPrompt=e.dt,exports.formatSandboxStatus=e.zt,exports.getProviderSetupStep=e.ft,exports.isDoctorRepairId=e.Yn,exports.mcpUnavailableServersNotice=e.rn,exports.mcpUserActionCommand=e.in,exports.mcpUserActionNotice=e.an,exports.parseScheduleSpec=e.U,exports.planDoctorRepair=e.Xn,exports.redactDiagnosticText=e.Qn,exports.renderDoctorReport=e.$n,exports.resolveProviderSetupSelection=e.pt,exports.runDoctor=e.Gn,exports.runProviderSetupPromptFlow=e.mt,exports.runProviderStartupSetup=e.nt,exports.submitProviderSetupValue=e.ht,exports.validateProviderSetupValue=e.gt;
|