omp-fabric 1.25.7 → 1.25.8

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.
Files changed (68) hide show
  1. package/CHANGELOG.md +14 -0
  2. package/README.md +1 -1
  3. package/dist/audit/projection.d.ts.map +1 -1
  4. package/dist/chunks/{chunk-HAH64YUG.js → chunk-2C5YN36Y.js} +2 -2
  5. package/dist/chunks/chunk-2C5YN36Y.js.map +7 -0
  6. package/dist/chunks/{chunk-3BS4RMF4.js → chunk-AZBJNZS4.js} +2 -2
  7. package/dist/chunks/{chunk-EZRC24CX.js → chunk-BMSAIMFB.js} +2 -2
  8. package/dist/chunks/{chunk-63VIZJGS.js → chunk-BWLZ6VDQ.js} +2 -2
  9. package/dist/chunks/{chunk-BQG4LFAC.js → chunk-D55BFSFK.js} +2 -2
  10. package/dist/chunks/{chunk-WUPYPFAC.js → chunk-E3KTE736.js} +3 -3
  11. package/dist/chunks/{chunk-JBKYNJFN.js → chunk-FL4A542C.js} +2 -1
  12. package/dist/chunks/chunk-FL4A542C.js.map +7 -0
  13. package/dist/chunks/{chunk-REHGQCXU.js → chunk-J2BDKPO4.js} +4 -4
  14. package/dist/chunks/{chunk-3KORI7FQ.js → chunk-KLWNXXEI.js} +2 -2
  15. package/dist/chunks/{chunk-XLINRLLP.js → chunk-PIW2DEO2.js} +4 -4
  16. package/dist/chunks/{chunk-H3KRHDDF.js → chunk-QJKOPPW2.js} +2 -2
  17. package/dist/chunks/{chunk-MR5C7U5H.js → chunk-UKB5RJDP.js} +3 -3
  18. package/dist/chunks/chunk-UKB5RJDP.js.map +7 -0
  19. package/dist/chunks/{chunk-GPJV2FSP.js → chunk-WX6C7N3W.js} +2 -2
  20. package/dist/chunks/{chunk-ABBGHQVX.js → chunk-YAI5SCIE.js} +2 -2
  21. package/dist/chunks/{chunk-G3ELO3QC.js → chunk-Z6TTRT6Q.js} +2 -2
  22. package/dist/compaction/hook.js +3 -3
  23. package/dist/compaction/lcm-runtime.js +4 -4
  24. package/dist/core/action-registry.js +2 -2
  25. package/dist/core/system-guidance.d.ts.map +1 -1
  26. package/dist/entropy/index.js +5 -5
  27. package/dist/fabric-runtime-state.js +63 -27
  28. package/dist/fabric-runtime-state.js.map +2 -2
  29. package/dist/host-compatibility.d.ts +1 -1
  30. package/dist/index.js +17 -14
  31. package/dist/index.js.map +2 -2
  32. package/dist/memory/discovery.js +4 -4
  33. package/dist/memory/normalize.js +3 -3
  34. package/dist/memory/search.js +4 -4
  35. package/dist/providers/memory-provider.js +6 -6
  36. package/dist/providers/omp-tools-provider.d.ts.map +1 -1
  37. package/dist/residency/host.js +6 -6
  38. package/dist/residency/omp-entry.js +6 -6
  39. package/dist/runtime/core-override-guest-types.js +1 -1
  40. package/dist/runtime/guest-types.d.ts +2 -2
  41. package/dist/runtime/guest-types.d.ts.map +1 -1
  42. package/dist/runtime/guest-types.js +1 -1
  43. package/dist/runtime/node-process-runtime.js +1 -1
  44. package/dist/runtime/quickjs-runtime.d.ts +1 -1
  45. package/dist/runtime/quickjs-runtime.d.ts.map +1 -1
  46. package/dist/runtime/quickjs-runtime.js +1 -1
  47. package/dist/speculation/guest-args.d.ts.map +1 -1
  48. package/dist/speculation/scanner.js +2 -1
  49. package/dist/speculation/scanner.js.map +2 -2
  50. package/docs/audit-trace.md +1 -1
  51. package/docs/configuration.md +1 -1
  52. package/package.json +4 -4
  53. package/skills/fabric-exec/SKILL.md +4 -4
  54. package/dist/chunks/chunk-HAH64YUG.js.map +0 -7
  55. package/dist/chunks/chunk-JBKYNJFN.js.map +0 -7
  56. package/dist/chunks/chunk-MR5C7U5H.js.map +0 -7
  57. /package/dist/chunks/{chunk-3BS4RMF4.js.map → chunk-AZBJNZS4.js.map} +0 -0
  58. /package/dist/chunks/{chunk-EZRC24CX.js.map → chunk-BMSAIMFB.js.map} +0 -0
  59. /package/dist/chunks/{chunk-63VIZJGS.js.map → chunk-BWLZ6VDQ.js.map} +0 -0
  60. /package/dist/chunks/{chunk-BQG4LFAC.js.map → chunk-D55BFSFK.js.map} +0 -0
  61. /package/dist/chunks/{chunk-WUPYPFAC.js.map → chunk-E3KTE736.js.map} +0 -0
  62. /package/dist/chunks/{chunk-REHGQCXU.js.map → chunk-J2BDKPO4.js.map} +0 -0
  63. /package/dist/chunks/{chunk-3KORI7FQ.js.map → chunk-KLWNXXEI.js.map} +0 -0
  64. /package/dist/chunks/{chunk-XLINRLLP.js.map → chunk-PIW2DEO2.js.map} +0 -0
  65. /package/dist/chunks/{chunk-H3KRHDDF.js.map → chunk-QJKOPPW2.js.map} +0 -0
  66. /package/dist/chunks/{chunk-GPJV2FSP.js.map → chunk-WX6C7N3W.js.map} +0 -0
  67. /package/dist/chunks/{chunk-ABBGHQVX.js.map → chunk-YAI5SCIE.js.map} +0 -0
  68. /package/dist/chunks/{chunk-G3ELO3QC.js.map → chunk-Z6TTRT6Q.js.map} +0 -0
@@ -6,7 +6,7 @@ import {
6
6
  } from "./chunk-ZHDN5ESL.js";
7
7
  import {
8
8
  rawContextTokens
9
- } from "./chunk-BQG4LFAC.js";
9
+ } from "./chunk-D55BFSFK.js";
10
10
  import {
11
11
  compactionRequestBoundsError,
12
12
  encodeCompactionRequest
@@ -463,4 +463,4 @@ export {
463
463
  buildPeerCards,
464
464
  awaitPeerSettle
465
465
  };
466
- //# sourceMappingURL=chunk-H3KRHDDF.js.map
466
+ //# sourceMappingURL=chunk-QJKOPPW2.js.map
@@ -13,7 +13,7 @@ var OMP_CORE_NUMERIC_FIELDS = {
13
13
  bash: ["timeout"],
14
14
  edit: [],
15
15
  write: [],
16
- grep: ["context", "skip"],
16
+ grep: ["context", "skip", "limit"],
17
17
  find: ["limit"],
18
18
  ls: ["limit"]
19
19
  };
@@ -461,7 +461,7 @@ type OmpShellOptions = {
461
461
  pty?: boolean;
462
462
  };
463
463
  type OmpBashOptions = OmpShellOptions;
464
- type OmpGrepOptions = { path?: string; glob?: string; globPattern?: string; ignoreCase?: boolean; ic?: boolean; caseInsensitive?: boolean; literal?: boolean; context?: number; ctx?: number; skip?: number; gitignore?: boolean };
464
+ type OmpGrepOptions = { path?: string; glob?: string; globPattern?: string; ignoreCase?: boolean; ic?: boolean; caseInsensitive?: boolean; literal?: boolean; context?: number; ctx?: number; skip?: number; limit?: number; gitignore?: boolean };
465
465
  type OmpFindOptions = { path?: string; limit?: number; max?: number; gitignore?: boolean; hidden?: boolean };
466
466
  type OmpLsOptions = { limit?: number; max?: number };
467
467
  type OmpReadArgument = string | (OmpPathArgument & OmpReadOptions);
@@ -1555,4 +1555,4 @@ export {
1555
1555
  GUEST_TYPE_DECLARATIONS,
1556
1556
  guestTypeDeclarations
1557
1557
  };
1558
- //# sourceMappingURL=chunk-MR5C7U5H.js.map
1558
+ //# sourceMappingURL=chunk-UKB5RJDP.js.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/runtime/guest-types.ts"],
4
+ "sourcesContent": ["import type { FabricDynamicGuestDeclarations } from \"../protocol.js\";\n\n// These names and compatibility fields are the single source of truth for\n// generated core-override overloads. Keep them beside OmpToolsApi below so an\n// override extends the same guest contract rather than copying its signatures.\n// Numeric fields widen to `number | string` in generated overloads too,\n// mirroring built-in runtime normalization; a strict override schema still\n// rejects the string form at validation time, and the registry error wins.\nexport const OMP_CORE_COMPATIBILITY_ARGUMENT_TYPE_NAMES = {\n read: \"OmpReadCompatibilityArgument\",\n bash: \"OmpBashCompatibilityArgument\",\n edit: \"OmpEditCompatibilityArgument\",\n write: \"OmpWriteCompatibilityArgument\",\n grep: \"OmpGrepCompatibilityArgument\",\n find: \"OmpFindCompatibilityArgument\",\n ls: \"OmpLsCompatibilityArgument\",\n} as const;\n\nexport const OMP_CORE_NUMERIC_FIELDS = {\n read: [\"offset\", \"limit\"],\n bash: [\"timeout\"],\n edit: [],\n write: [],\n grep: [\"context\", \"skip\", \"limit\"],\n find: [\"limit\"],\n ls: [\"limit\"],\n} as const;\n\nexport const GUEST_TYPE_DECLARATIONS = `\ntype JsonPrimitive = string | number | boolean | null;\ntype JsonValue = JsonPrimitive | JsonValue[] | { [key: string]: JsonValue };\ntype FabricTransport = \"auto\" | \"process\" | \"tmux\" | \"screen\" | \"localterm\" | \"herdr\";\ntype FabricAgentRunner = \"omp\" | \"claude\" | \"veda\";\ntype FabricThinking = \"off\" | \"minimal\" | \"low\" | \"medium\" | \"high\" | \"xhigh\" | \"max\";\ninterface FabricActionEffect {\n kind: \"none\" | \"scoped\" | \"transactional\" | \"emission\";\n resources?: string[];\n ordering?: \"commutative\" | \"ordered\" | \"unknown\";\n}\ninterface FabricAction {\n ref: string;\n provider: string;\n name: string;\n description: string;\n inputSchema: Record<string, unknown>;\n outputSchema?: Record<string, unknown>;\n risk: \"read\" | \"write\" | \"execute\" | \"network\" | \"agent\";\n namespace?: string;\n effect?: FabricActionEffect;\n}\ninterface FabricImageContent {\n type: \"image\";\n data: string;\n mimeType: string;\n}\ninterface FabricAgentRequest {\n task: string;\n images?: FabricImageContent[];\n name?: string;\n runner?: FabricAgentRunner;\n transport?: FabricTransport;\n model?: string;\n persona?: string;\n thinking?: FabricThinking;\n tools?: string[];\n addTools?: string[];\n timeoutMs?: number;\n extensions?: boolean;\n recursive?: boolean;\n /** Filesystem execution directory; relative paths resolve from the parent agent cwd. */\n cwd?: string;\n worktree?: boolean;\n schema?: Record<string, unknown>;\n prompt?: string;\n instructions?: string;\n timeout_ms?: number;\n residency?: FabricParticipantResidency;\n}\ninterface FabricHandoffCall {\n readonly ref: string;\n}\ninterface FabricHandoffFacts {\n readonly calls: readonly FabricHandoffCall[];\n count(ref?: string | readonly string[]): number;\n}\ntype FabricHandoffPredicate = (facts: Readonly<FabricHandoffFacts>) => boolean;\ninterface FabricHandoffRequest {\n model: string;\n task?: string;\n when?: FabricHandoffPredicate;\n name?: string;\n transport?: FabricTransport;\n thinking?: FabricThinking;\n tools?: string[];\n timeoutMs?: number;\n extensions?: boolean;\n recursive?: boolean;\n schema?: Record<string, unknown>;\n prompt?: string;\n instructions?: string;\n timeout_ms?: number;\n}\ninterface FabricHandoffResult {\n scheduled: true;\n status: \"deferred\";\n boundary: \"fabric_exec_end\";\n}\ninterface FabricMainAgentInfo {\n id: string;\n name: \"Main\";\n kind: \"main\";\n status: \"idle\" | \"running\" | \"remote\";\n runner: \"omp\";\n transport: \"host\";\n cwd?: string;\n sessionId?: string;\n model?: string;\n thinking?: string;\n startedAt?: number;\n updatedAt: number;\n pendingMessages: boolean;\n local: boolean;\n}\ninterface FabricPeerInfo {\n id: string;\n name: string;\n kind: \"peer\";\n status: \"idle\" | \"running\";\n runner: \"omp\";\n transport: \"host\";\n cwd: string;\n sessionId: string;\n model?: string;\n thinking?: string;\n startedAt: number;\n updatedAt: number;\n pendingMessages: boolean;\n local: false;\n}\ntype FabricParticipantKind = \"root\" | \"agent\" | \"actor\";\ntype FabricParticipantResidency = \"session\" | \"durable\";\ntype FabricParticipantScope = \"local\" | \"lineage\" | \"project\";\ntype FabricParticipantCapability = \"steer\" | \"followUp\" | \"stop\" | \"ask\" | \"actor-bindings\" | \"attach\" | \"fabric\";\ninterface FabricParticipantInfo {\n format: 1;\n id: string;\n kind: FabricParticipantKind;\n rootId: string;\n ownerHostId: string;\n ownerIdentityId: string;\n parentId?: string;\n name: string;\n status: string;\n runner: FabricAgentRunner;\n transport: FabricTransport | \"host\";\n capabilities: FabricParticipantCapability[];\n cwd?: string;\n sessionId?: string;\n model?: string;\n thinking?: string;\n startedAt: number;\n updatedAt: number;\n finishedAt?: number;\n pendingMessages?: boolean;\n currentTool?: string;\n turns?: number;\n toolCalls?: number;\n usage?: { input: number; output: number; cacheRead: number; cacheWrite: number; cost: number };\n actorQueued?: number;\n actorMessages?: number;\n controlProtocol: \"v1\" | \"legacy\";\n residency: FabricParticipantResidency;\n local: boolean;\n stale: boolean;\n}\ntype FabricLifecycleEventType =\n | \"omp.input\"\n | \"omp.agent_start\"\n | \"omp.agent_end\"\n | \"omp.turn_end\"\n | \"omp.tool_error\"\n | \"omp.session_compact\"\n | \"run.completed\"\n | \"run.failed\"\n | \"run.stopped\"\n | \"run.timed_out\"\n | \"tokens.usage\"\n | \"component.state\";\ntype FabricLifecycleDelivery = \"steer\" | \"followUp\";\ninterface FabricLifecycleSource {\n id: string;\n name: string;\n kind: FabricParticipantKind;\n rootId: string;\n runner: FabricAgentRunner;\n ownerHostId?: string;\n ownerIdentityId?: string;\n}\ninterface FabricLifecycleEvent {\n version: 1;\n id: string;\n sequence: number;\n event: FabricLifecycleEventType;\n source: FabricLifecycleSource;\n occurredAt: number;\n publishedAt: number;\n runId?: string;\n status?: string;\n data?: unknown;\n}\ninterface FabricLifecycleSubscription {\n format: 1;\n id: string;\n from: string;\n events: FabricLifecycleEventType[];\n to: string;\n delivery: FabricLifecycleDelivery;\n triggerTurn: boolean;\n once: boolean;\n afterSequence: number;\n createdAt: number;\n updatedAt: number;\n createdBy: { id: string; name: string; kind: \"main\" | \"agent\" | \"actor\"; sessionId?: string };\n lastDeliveredAt?: number;\n lastEventId?: string;\n lastError?: string;\n}\ninterface FabricAgentHandle {\n id: string;\n name: string;\n status: string;\n runner: FabricAgentRunner;\n transport: FabricTransport;\n cwd: string;\n model?: string;\n thinking?: FabricThinking;\n actorId?: string;\n actorName?: string;\n sessionId?: string;\n runnerSessionId?: string;\n attachCommand?: string;\n branch?: string;\n worktree?: string;\n text?: string;\n value?: unknown;\n error?: string;\n logFile?: string;\n residency?: FabricParticipantResidency;\n}\ninterface FabricRemoteControlResult {\n queued: true;\n messageId: string;\n routed: \"mesh\";\n acknowledged: true;\n}\ninterface FabricAgentResult extends FabricAgentHandle {\n task: string;\n startedAt: number;\n finishedAt?: number;\n turns: number;\n toolCalls: number;\n text: string;\n value?: unknown;\n error?: string;\n usage: { input: number; output: number; cacheRead: number; cacheWrite: number; cost: number };\n pendingMessages?: { steering: string[]; followUp: string[] };\n}\ninterface FabricModelInfo {\n runner?: FabricAgentRunner;\n provider: string;\n id: string;\n name: string;\n key: string;\n value?: string;\n resolvedModel?: string;\n displayName?: string;\n description?: string;\n supportsEffort?: boolean;\n supportedEffortLevels?: string[];\n supportsAdaptiveThinking?: boolean;\n supportsFastMode?: boolean;\n supportsAutoMode?: boolean;\n}\ninterface FabricLogLine {\n index?: number;\n offset: number;\n raw: string;\n parsed?: unknown;\n}\ninterface FabricAgentLog {\n id: string;\n runDirectory: string;\n logFile: string;\n status?: FabricAgentResult;\n events: FabricLogLine[];\n hasMore: boolean;\n before?: number;\n}\ninterface FabricActorLog {\n actorId: string;\n actorName: string;\n sessionFile: string;\n logDir: string;\n session: FabricLogLine[];\n sessionHasMore: boolean;\n sessionBefore?: number;\n run?: {\n runId: string;\n eventsFile: string;\n status?: FabricAgentResult;\n events: FabricLogLine[];\n hasMore: boolean;\n before?: number;\n };\n retainedRuns: string[];\n}\ninterface FabricCapabilityActionHead {\n key: string;\n parentKey: string;\n ref: string;\n name: string;\n description: string;\n descriptorHash: string;\n risk: \"read\" | \"write\" | \"execute\" | \"network\" | \"agent\";\n namespace?: string;\n effect?: FabricActionEffect;\n}\ninterface FabricCapabilityProviderHead {\n key: string;\n parentKey: string;\n name: string;\n description: string;\n descriptorHash: string;\n actions: FabricCapabilityActionHead[];\n}\ninterface FabricCapabilityCatalog {\n kind: \"omp-fabric.capability-catalog\";\n version: 1;\n root: {\n key: \"capability:fabric\";\n name: \"Fabric capabilities\";\n description: string;\n descriptorHash: string;\n };\n providers: FabricCapabilityProviderHead[];\n totalActions: number;\n indexedActions: number;\n complete: boolean;\n reasons: string[];\n}\ninterface FabricToolsApi {\n providers(): Promise<Array<{ name: string; description: string }>>;\n catalog(args?: { provider?: string; limit?: number }): Promise<FabricCapabilityCatalog>;\n list(args?: { provider?: string; namespace?: string; query?: string; limit?: number }): Promise<FabricAction[]>;\n search(query: string): Promise<FabricAction[]>;\n search(args: { query: string; limit?: number }): Promise<FabricAction[]>;\n describe(args: { ref: string }): Promise<FabricAction>;\n call(args: { ref: string; args?: Record<string, unknown> }): Promise<unknown>;\n progress(args: { message: string }): Promise<void>;\n models(): Promise<FabricModelInfo[]>;\n}\ninterface FabricCapturedToolResult {\n content: Array<{ type: string; text?: string; [key: string]: unknown }>;\n text: string;\n details?: unknown;\n isError: boolean;\n terminate?: boolean;\n source: { path: string; source: string; scope: string; origin: string; baseDir?: string };\n}\ninterface FabricCapturedTool {\n (args?: Record<string, unknown>): Promise<FabricCapturedToolResult>;\n}\ntype FabricExtensionsApi = Record<string, FabricCapturedTool>;\n// String-primary tools (read/bash/grep/find/ls) accept a bare string; the\n// runtime proxy coerces it to { <primaryField>: string }. Lets the model write\n// the natural form (omp.bash(\"ls\")) instead of omp.bash({ command: \"ls\" }).\n// Return shapes differ by tool: read/grep/find/ls return their text as a bare\n// string (e.g. const src: string = await omp.read({ path })); shell/edit/write\n// return { ok, output, details } (e.g. const { output } = await omp.bash(...)).\n// Common alias keys (cmd\u2192command, query\u2192pattern, file\u2192path, dir\u2192path) and a\n// flat edit shape ({ path, oldText, newText }) are also accepted; the runtime\n// proxy normalizes them to the canonical form before the host validates args.\n// Bash timeout is measured in seconds; timeoutMs is converted from milliseconds.\n// Extended near-miss repairs: find's name/filename/glob \u2192 pattern, write's\n// data \u2192 content, ls's folder \u2192 path, bash's script \u2192 command; numeric option\n// fields (limit/offset/context/timeout) also accept numeric strings, coerced\n// at runtime (2322 diagnostics are suppressed by the type-checker by design).\n// String-primary tools also take a two-arg (primary, options) form \u2014\n// omp.read(\"index.ts\", { limit: 120 }) merges to { path, ...options } at\n// runtime, the positional string winning the primary field on conflict.\n// shell/edit/write envelopes are proxy-guarded so string-method access\n// (.trim(), .split(), iteration) fails with an actionable TypeError pointing\n// at .output instead of QuickJS's context-free \"not a function\" \u2014 property-\n// miss (2339) checks are suppressed by design, so the runtime gives the hint.\ntype OmpPathArgument = {\n path?: string;\n file?: string;\n absolutePath?: string;\n file_path?: string;\n filePath?: string;\n filepath?: string;\n pathname?: string;\n target_file?: string;\n targetFile?: string;\n absolute_path?: string;\n fileAbsolutePath?: string;\n};\ntype OmpOptionalPathArgument = {\n path?: string;\n file?: string;\n absolutePath?: string;\n file_path?: string;\n filePath?: string;\n filepath?: string;\n pathname?: string;\n target_file?: string;\n targetFile?: string;\n absolute_path?: string;\n fileAbsolutePath?: string;\n dir?: string;\n folder?: string;\n directory?: string;\n directoryPath?: string;\n};\ntype OmpOldTextArgument = {\n oldText?: string;\n old?: string;\n old_string?: string;\n oldString?: string;\n old_str?: string;\n oldStr?: string;\n from?: string;\n old_value?: string;\n old_text?: string;\n oldContent?: string;\n old_content?: string;\n};\ntype OmpNewTextArgument = {\n newText?: string;\n new?: string;\n replacement?: string;\n new_string?: string;\n newString?: string;\n new_str?: string;\n newStr?: string;\n to?: string;\n new_value?: string;\n new_text?: string;\n newContent?: string;\n new_content?: string;\n};\ntype OmpEditOperation = OmpOldTextArgument & OmpNewTextArgument & { all?: boolean };\ntype OmpCommandArgument = { command?: string; cmd?: string; shell?: string; cmdline?: string; script?: string; commandLine?: string };\ntype OmpContentArgument = { content?: string; contents?: string; body?: string; text?: string; data?: string; fileContent?: string };\ntype OmpGrepPatternArgument = { pattern?: string; query?: string; regex?: string; search?: string; q?: string; expression?: string; text?: string };\ntype OmpFindPatternArgument = { pattern?: string; query?: string; regex?: string; search?: string; name?: string; filename?: string; glob?: string; expression?: string; include?: string };\n// Two-arg (primary, options) bags for the string-primary tools. Only option\n// aliases belong here (max/start/ctx/ic/...), never primary-field aliases \u2014\n// the primary field comes from the positional string.\ntype OmpReadOptions = { offset?: number; limit?: number; start?: number; max?: number };\n// cwd is honored per call by the omp provider, which binds the command to a\n// shell definition rooted there; relative paths resolve from the session cwd.\n// The alias spellings mirror the shell entries in __ompArgAliases: the\n// runtime repairs them, so the checker has to accept the same spellings or a\n// repairable call is rejected before it ever reaches the sandbox.\ntype OmpShellOptions = {\n timeout?: number; timeoutMs?: number; settle?: boolean;\n async?: boolean;\n cwd?: string; workdir?: string; directory?: string; workingDirectory?: string;\n pty?: boolean;\n};\ntype OmpBashOptions = OmpShellOptions;\ntype OmpGrepOptions = { path?: string; glob?: string; globPattern?: string; ignoreCase?: boolean; ic?: boolean; caseInsensitive?: boolean; literal?: boolean; context?: number; ctx?: number; skip?: number; limit?: number; gitignore?: boolean };\ntype OmpFindOptions = { path?: string; limit?: number; max?: number; gitignore?: boolean; hidden?: boolean };\ntype OmpLsOptions = { limit?: number; max?: number };\ntype OmpReadArgument = string | (OmpPathArgument & OmpReadOptions);\ntype OmpBashArgument = string | (OmpCommandArgument & OmpBashOptions);\ntype OmpEditFlatArgument = OmpPathArgument & OmpOldTextArgument & OmpNewTextArgument & { all?: boolean };\ntype OmpEditArgument = OmpPathArgument & ({ edits: OmpEditOperation[]; all?: boolean } | OmpEditFlatArgument);\ntype OmpWriteArgument = string | (OmpPathArgument & OmpContentArgument);\ntype OmpGrepArgument = string | (OmpGrepPatternArgument & OmpGrepOptions);\ntype OmpFindArgument = string | (OmpFindPatternArgument & OmpFindOptions);\ntype OmpLsArgument = string | (OmpOptionalPathArgument & OmpLsOptions);\ntype OmpNumericString<T> = T extends number ? T | string : T;\ntype OmpNumericStringOptions<T> = { [K in keyof T]: OmpNumericString<T[K]> };\ntype OmpReadCompatibilityArgument = string | (OmpPathArgument & OmpNumericStringOptions<OmpReadOptions>);\ntype OmpBashCompatibilityArgument = string | (OmpCommandArgument & OmpNumericStringOptions<OmpBashOptions>);\ntype OmpEditCompatibilityArgument = OmpEditFlatArgument;\ntype OmpWriteCompatibilityArgument = OmpWriteArgument;\ntype OmpGrepCompatibilityArgument = string | (OmpGrepPatternArgument & OmpNumericStringOptions<OmpGrepOptions>);\ntype OmpFindCompatibilityArgument = string | (OmpFindPatternArgument & OmpNumericStringOptions<OmpFindOptions>);\ntype OmpLsCompatibilityArgument = string | (OmpOptionalPathArgument & OmpNumericStringOptions<OmpLsOptions>);\ninterface OmpToolsApi {\n read(args: OmpReadArgument, options?: OmpReadOptions): Promise<string>;\n bash(args: OmpBashArgument, options?: OmpBashOptions): Promise<{ ok: true; output: string; details: unknown } | { ok: false; output: string; details: null; exitCode: number; error: string }>;\n edit(args: OmpEditArgument): Promise<{ ok: true; output: string; details: unknown }>;\n edit(path: string, oldText: string, newText: string): Promise<{ ok: true; output: string; details: unknown }>;\n write(args: OmpWriteArgument): Promise<{ ok: true; output: string; details: unknown }>;\n write(path: string, content: string): Promise<{ ok: true; output: string; details: unknown }>;\n grep(args: OmpGrepArgument): Promise<string>;\n grep(pattern: string, path?: string | OmpGrepOptions, skip?: number): Promise<string>;\n find(args: OmpFindArgument): Promise<string>;\n find(pattern: string, path?: string | OmpFindOptions, limit?: number): Promise<string>;\n ls(args?: OmpLsArgument, options?: OmpLsOptions): Promise<string>;\n wait(): Promise<{ ok: true; output: string; details: unknown } | { ok: false; output: string; details: null; exitCode: number; error: string }>;\n}\ntype FabricActorHostEvent =\n | \"resources_discover\"\n | \"session_start\"\n | \"session_before_switch\"\n | \"session_switch\"\n | \"session_before_branch\"\n | \"session_branch\"\n | \"session_before_compact\"\n | \"session.compacting\"\n | \"session_compact\"\n | \"session_shutdown\"\n | \"session_before_tree\"\n | \"session_tree\"\n | \"goal_updated\"\n | \"input\"\n | \"before_agent_start\"\n | \"agent_start\"\n | \"agent_end\"\n | \"session_stop\"\n | \"turn_start\"\n | \"turn_end\"\n | \"message_start\"\n | \"message_update\"\n | \"message_end\"\n | \"context\"\n | \"before_provider_request\"\n | \"after_provider_response\"\n | \"tool_execution_start\"\n | \"tool_call\"\n | \"tool_execution_update\"\n | \"tool_result\"\n | \"tool_execution_end\"\n | \"user_bash\"\n | \"tool_error\";\ntype FabricActorDelivery = \"mailbox\" | \"steer\" | \"followUp\" | \"nextTurn\";\ninterface FabricActorHostMediaDescriptor {\n readonly type: \"image\";\n readonly mediaIndex: number;\n readonly mimeType: string;\n}\ninterface FabricActorHostSignal {\n readonly payload: unknown;\n readonly media?: readonly FabricActorHostMediaDescriptor[];\n readonly idle: boolean;\n readonly observedAt: number;\n}\ntype FabricActorActivation =\n | { readonly kind: \"hostEvent\"; readonly id: string; readonly source: string; readonly sequence: number; readonly createdAt: number; readonly event: FabricActorHostEvent; readonly mainRevision: number; readonly taskRevision: number; readonly signal?: FabricActorHostSignal }\n | { readonly kind: \"direct\"; readonly id: string; readonly source: string; readonly sequence: number; readonly createdAt: number }\n | { readonly kind: \"mesh\"; readonly id: string; readonly source: string; readonly sequence: number; readonly createdAt: number; readonly topic: string };\ninterface FabricActorValidityFacts {\n readonly activation: Readonly<FabricActorActivation>;\n readonly current: Readonly<{ latestActivationSequence: number; mainRevision: number; taskRevision: number; idle: boolean; now: number }>;\n}\ntype FabricActorValidityDecision = boolean | { valid: boolean; reason?: string };\ntype FabricActorBindingScope = \"session\" | \"project\";\ninterface FabricActorRunBinding { model?: string; thinking?: FabricThinking }\ntype FabricActorValidWhile = (facts: Readonly<FabricActorValidityFacts>) => FabricActorValidityDecision;\ninterface FabricActorRequestBase {\n scope?: \"session\" | \"project\" | \"global\";\n name: string;\n instructions: string;\n events?: FabricActorHostEvent[];\n topics?: string[];\n responseMode?: \"text\" | \"directive\";\n coalesce?: boolean;\n runner?: FabricAgentRunner;\n model?: string;\n thinking?: FabricThinking;\n tools?: string[];\n transport?: FabricTransport;\n cwd?: string;\n timeoutMs?: number;\n timeout_ms?: number;\n extensions?: boolean;\n requires?: Array<string | { ref: string; optional?: boolean }>;\n validWhile?: FabricActorValidWhile;\n residency?: FabricParticipantResidency;\n}\ntype FabricActorRequest = FabricActorRequestBase & (\n | { delivery?: \"mailbox\"; triggerTurn?: false }\n | { delivery: \"nextTurn\"; triggerTurn?: false }\n | { delivery: \"steer\" | \"followUp\"; triggerTurn: boolean }\n);\ninterface FabricActorInfo {\n id: string;\n scope: \"session\" | \"project\";\n name: string;\n status: \"idle\" | \"queued\" | \"running\" | \"stopped\";\n runner: FabricAgentRunner;\n events: FabricActorHostEvent[];\n topics: string[];\n delivery: FabricActorDelivery;\n responseMode: \"text\" | \"directive\";\n triggerTurn: boolean;\n coalesce: boolean;\n model?: string;\n thinking?: FabricThinking;\n binding?: FabricActorRunBinding & { scope: \"session\"; sessionId: string; updatedAt?: number };\n projectDefaults?: FabricActorRunBinding & { scope: \"project\" };\n tools?: string[];\n timeoutMs?: number;\n extensions?: boolean;\n requirements?: Array<{ ref: string; optional?: boolean }>;\n capabilityDigest?: string;\n missingCapabilities?: string[];\n validWhile?: { version: 1; source: string };\n residency: FabricParticipantResidency;\n queued: number;\n messages: number;\n createdAt: number;\n updatedAt: number;\n lastRunId?: string;\n lastError?: string;\n sessionFile?: string;\n logDir?: string;\n}\ninterface FabricModelSwitchRequest {\n /** provider/id, a models.aliases name, or a search term; resolution tries aliases first, then exact matches, then the closest fuzzy match (recency from pi-model-sort breaks ties) against authenticated models. */\n model: string;\n /** Optional provider filter applied before matching (e.g. \"anthropic\"). */\n provider?: string;\n}\ninterface FabricModelSwitchResult {\n switched: boolean;\n /** Active model as provider/id after the call (unchanged when reason is \"already-active\"). */\n model: string;\n name?: string;\n /** Previously active provider/id when known. Absent for already-active results. */\n previous?: string;\n /** Set when the selector resolved through a configured models.aliases name. */\n alias?: string;\n /** How the selector resolved: the alias name, or one of closest/recent/latest for inexact picks. Absent for exact provider/id or bare-id matches. */\n via?: string;\n reason?: \"already-active\";\n}\ninterface FabricActorMessage {\n id: string;\n actorId: string;\n actorName: string;\n direction: \"in\" | \"out\";\n source: string;\n createdAt: number;\n text?: string;\n data?: unknown;\n action?: \"silent\" | \"message\" | \"stop\";\n runId?: string;\n error?: string;\n stale?: boolean;\n reason?: string;\n}\n// agentId/agent_id spellings repair to id during agent arg normalization.\ntype FabricAgentTargetArgs = { id: string; agentId?: string; agent_id?: string };\ninterface FabricAgentsApi {\n run(args: FabricAgentRequest): Promise<FabricAgentResult>;\n handoff(args: FabricHandoffRequest): Promise<FabricHandoffResult>;\n spawn(args: FabricAgentRequest): Promise<FabricAgentHandle>;\n wait(args: FabricAgentTargetArgs): Promise<FabricAgentResult>;\n status(args: FabricAgentTargetArgs): Promise<FabricAgentResult | FabricAgentHandle | FabricMainAgentInfo | FabricActorInfo | FabricParticipantInfo>;\n list(args?: { scope?: FabricParticipantScope }): Promise<Array<FabricAgentResult | FabricAgentHandle | FabricParticipantInfo>>;\n members(args?: { scope?: FabricParticipantScope; kinds?: FabricParticipantKind[]; includeStale?: boolean }): Promise<FabricParticipantInfo[]>;\n self(): Promise<FabricParticipantInfo>;\n main(): Promise<FabricMainAgentInfo>;\n sessions(): Promise<FabricParticipantInfo[]>;\n peers(): Promise<FabricPeerInfo[]>;\n subscribe(args: {\n from: string;\n events: FabricLifecycleEventType[];\n to?: string;\n delivery: FabricLifecycleDelivery;\n triggerTurn: boolean;\n once?: boolean;\n }): Promise<FabricLifecycleSubscription>;\n subscriptions(args?: { from?: string; to?: string }): Promise<FabricLifecycleSubscription[]>;\n unsubscribe(args: FabricAgentTargetArgs): Promise<{ removed: boolean }>;\n models(args?: { runner?: FabricAgentRunner; refresh?: boolean }): Promise<FabricModelInfo[]>;\n stop(args: FabricAgentTargetArgs): Promise<FabricAgentResult | FabricActorInfo | FabricRemoteControlResult>;\n cleanup(args: FabricAgentTargetArgs & { deleteBranch?: boolean; delete_branch?: boolean }): Promise<{ cleaned: boolean }>;\n create(args: FabricActorRequest): Promise<FabricActorInfo>;\n setModel(args: { id: string; model?: string; scope?: FabricActorBindingScope }): Promise<FabricActorInfo>;\n switchModel(args: FabricModelSwitchRequest): Promise<FabricModelSwitchResult>;\n setThinking(args: { id: string; thinking?: FabricThinking; scope?: FabricActorBindingScope }): Promise<FabricActorInfo>;\n setTools(args: { id: string; tools: string[]; scope?: \"project\" | \"global\" }): Promise<FabricActorInfo>;\n setEvents(args: { id: string; events: FabricActorHostEvent[] }): Promise<FabricActorInfo>;\n setDeliveryPolicy(args: {\n id: string;\n delivery: FabricActorDelivery;\n triggerTurn: boolean;\n scope?: \"project\" | \"global\";\n }): Promise<FabricActorInfo>;\n setInstructions(args: {\n id: string;\n instructions: string;\n scope?: \"project\" | \"global\";\n }): Promise<FabricActorInfo>;\n ask(args: { id: string; message: string; data?: unknown; model?: string; thinking?: FabricThinking }): Promise<FabricActorMessage>;\n tell(args: { id: string; message: string; data?: unknown; model?: string; thinking?: FabricThinking }): Promise<{ queued: true; messageId: string }>;\n steer(args: { id: string; message: string; data?: unknown }): Promise<{ queued: true; messageId: string; routed?: \"local\" | \"main\" | \"mesh\"; acknowledged?: boolean }>;\n followUp(args: { id: string; message: string; data?: unknown }): Promise<{ queued: true; messageId: string; routed?: \"local\" | \"main\" | \"mesh\"; acknowledged?: boolean }>;\n setSteeringMode(args: { id: string; mode: \"all\" | \"one-at-a-time\" }): Promise<{ queued: true; messageId: string }>;\n setFollowUpMode(args: { id: string; mode: \"all\" | \"one-at-a-time\" }): Promise<{ queued: true; messageId: string }>;\n actorStatus(args: FabricAgentTargetArgs): Promise<FabricActorInfo>;\n actors(): Promise<FabricActorInfo[]>;\n messages(args: { id: string; limit?: number }): Promise<FabricActorMessage[]>;\n remove(args: { id: string }): Promise<{ removed: boolean }>;\n log(args: {\n id: string;\n type?: \"session\" | \"run\" | \"all\";\n lines?: number;\n before?: number;\n runId?: string;\n }): Promise<FabricActorLog | FabricAgentLog>;\n}\ninterface FabricMcpResult {\n text: string;\n content: unknown[];\n structuredContent: unknown;\n}\ninterface FabricMcpTool {\n (args?: Record<string, unknown>): Promise<FabricMcpResult | unknown>;\n}\ninterface FabricMcpServer {\n [tool: string]: FabricMcpTool;\n}\n// Management verbs stay members of mcp even when the declare line below is\n// replaced by generated per-server declarations (see the dynamic option on\n// guestTypeDeclarations), so generated surfaces intersect with this type\n// rather than re-declaring them.\ninterface FabricMcpManagement {\n servers(): Promise<Array<{ name: string; description: string | null; transport: \"http\" | \"stdio\" }>>;\n reload(): Promise<{ servers: string[] }>;\n register(args: {\n name: string;\n description?: string;\n command?: string;\n args?: string[];\n cwd?: string;\n baseUrl?: string;\n headers?: Record<string, string>;\n env?: Record<string, string>;\n overwrite?: boolean;\n }): Promise<{ registered: string }>;\n call(args: { server: string; tool: string; args?: Record<string, unknown>; timeoutMs?: number }): Promise<unknown>;\n}\n// Loose static surface: any server/tool name compiles and argument shapes are\n// enforced at dispatch by the registry. With descriptor data available the\n// execution service replaces the declare-const-mcp line below with a\n// schema-typed rendering of the live cache (runtime/dynamic-guest-types.ts).\ntype FabricMcpApi = Record<string, FabricMcpServer> & FabricMcpManagement;\ninterface FabricCouncilRunOptions {\n task: string;\n roles: string[];\n runner?: FabricAgentRunner;\n transport?: FabricTransport;\n model?: string;\n thinking?: FabricThinking;\n tools?: string[];\n timeoutMs?: number;\n /** Filesystem execution directory; relative paths resolve from the parent agent cwd. */\n cwd?: string;\n worktree?: boolean;\n}\ninterface FabricCouncilApi {\n run(args: FabricCouncilRunOptions & { synthesize?: true }): Promise<FabricAgentResult>;\n run(args: FabricCouncilRunOptions & { synthesize: false }): Promise<FabricAgentResult[]>;\n}\ninterface FabricMeshIdentity {\n id: string;\n name: string;\n kind: \"main\" | \"actor\" | \"agent\";\n sessionId?: string;\n}\ninterface FabricMeshEvent {\n id: string;\n sequence: number;\n topic: string;\n kind: string;\n from: FabricMeshIdentity;\n to?: string;\n text?: string;\n data?: unknown;\n createdAt: number;\n}\ninterface FabricMeshStateEntry<T = unknown> {\n key: string;\n value: T;\n version: number;\n updatedAt: number;\n updatedBy: FabricMeshIdentity;\n}\ninterface FabricMeshApi {\n self(): Promise<FabricMeshIdentity>;\n publish(args: { topic: string; kind?: string; to?: string; text?: string; data?: unknown; message?: string; body?: string }): Promise<FabricMeshEvent>;\n read(args?: { after?: number; topic?: string; to?: string; limit?: number; max?: number }): Promise<FabricMeshEvent[]>;\n members(args: { scope?: FabricParticipantScope; kinds?: FabricParticipantKind[]; includeStale?: boolean; limit?: number; max?: number; include_stale?: boolean; withTotal: true }): Promise<{ members: FabricParticipantInfo[]; total: number; truncated: boolean }>;\n members(args?: { scope?: FabricParticipantScope; kinds?: FabricParticipantKind[]; includeStale?: boolean; limit?: number; max?: number; include_stale?: boolean; withTotal?: false }): Promise<FabricParticipantInfo[]>;\n get<T = unknown>(args: { key: string }): Promise<FabricMeshStateEntry<T> | null>;\n list<T = unknown>(args: { prefix?: string; limit?: number; max?: number; withTotal: true }): Promise<{ entries: Array<FabricMeshStateEntry<T>>; total: number; truncated: boolean }>;\n list<T = unknown>(args?: { prefix?: string; limit?: number; max?: number; withTotal?: false }): Promise<Array<FabricMeshStateEntry<T>>>;\n put<T = unknown>(args: { key: string; value: T; ifVersion?: number; if_version?: number; version?: number }): Promise<FabricMeshStateEntry<T>>;\n delete(args: { key: string; ifVersion?: number; if_version?: number; version?: number }): Promise<{ deleted: boolean; version?: number }>;\n}\n// Stable-provider argument bags declare the canonical keys plus the\n// near-miss spellings repaired during argument normalization\n// (providers/arg-normalization.ts and each provider's per-action table). The\n// registry's prepare stage repairs aliases before schema validation, so a\n// call spelled with an alias typechecks instead of tripping the\n// excess-property check; the canonical key wins on conflict, and anything\n// else fails additionalProperties:false validation with the offending\n// property path named. Keep these spillover fields in sync with the provider\n// normalization tables.\ntype FabricMemoryBranches = \"active\" | \"all\";\ntype FabricMemoryQueryMode = \"literal\" | \"phrase\" | \"regex\";\ntype FabricMemoryQueryMatch = \"all\" | \"any\";\ninterface FabricMemoryEntryRange {\n first: number;\n last: number;\n}\ninterface FabricMemoryRecallArgs {\n query?: string;\n queryMode?: FabricMemoryQueryMode;\n queryMatch?: FabricMemoryQueryMatch;\n expectedSourceHash?: string;\n expectedLineageFingerprint?: string;\n branches?: FabricMemoryBranches;\n scope?: string;\n offset?: number;\n pageSize?: number;\n snippetChars?: number;\n role?: string;\n tool?: string;\n ref?: string;\n provider?: string;\n action?: string;\n outcome?: \"succeeded\" | \"failed\" | \"aborted\" | \"timed_out\";\n since?: number;\n until?: number;\n entryRange?: FabricMemoryEntryRange;\n q?: string;\n limit?: number;\n max?: number;\n page_size?: number;\n snippet_chars?: number;\n query_mode?: FabricMemoryQueryMode;\n query_match?: FabricMemoryQueryMatch;\n entry_range?: FabricMemoryEntryRange;\n}\ninterface FabricMemoryExpandArgs {\n session: string;\n expectedSourceHash?: string;\n expectedLineageFingerprint?: string;\n branches?: FabricMemoryBranches;\n indices?: number[];\n entryIds?: string[];\n operationAddresses?: string[];\n entryRange?: FabricMemoryEntryRange;\n before?: number;\n after?: number;\n entryOffset?: number;\n textOffset?: number;\n maxChars?: number;\n maxEntries?: number;\n id?: string;\n file?: string;\n path?: string;\n session_id?: string;\n index?: number;\n entry_ids?: string[];\n operation_addresses?: string[];\n entry_range?: FabricMemoryEntryRange;\n entry_offset?: number;\n text_offset?: number;\n max_chars?: number;\n max_entries?: number;\n}\ninterface FabricMemoryCall<Ref extends string, Args> {\n ref: Ref;\n args: Args;\n}\ninterface FabricMemoryRecallEntryHit {\n kind: \"entry\";\n sessionId: string;\n tier: \"hot\" | \"cold\";\n index: number;\n entryId: string | null;\n parentId: string | null;\n operationAddress: string | null;\n type: string;\n role: string | null;\n tool: string | null;\n ref: string | null;\n provider: string | null;\n action: string | null;\n timestamp: number | null;\n isError: boolean;\n outcome?: \"succeeded\" | \"failed\" | \"aborted\" | \"timed_out\";\n score: number;\n snippet: string;\n truncated: boolean;\n follow: FabricMemoryCall<\"memory.expand\", FabricMemoryExpandArgs>;\n}\ninterface FabricMemoryRecallSessionHit {\n kind: \"session\";\n sessionId: string;\n tier: \"cold\";\n cwd: string;\n lastTimestamp: number | null;\n score: number;\n matchedTerms: number;\n matchedStructuralEntries: number;\n follow: FabricMemoryCall<\"memory.recall\", FabricMemoryRecallArgs>;\n}\ninterface FabricLcmMemoryHit {\n kind: \"lcm.raw\" | \"lcm.summary\";\n sessionId: string;\n score: number;\n snippet: string;\n truncated: boolean;\n source: { kind: \"raw\" | \"summary\"; projectKey: string; sessionId: string; entryId?: string; revision?: number; contentHash?: string; nodeId?: string; sourceHash: string };\n follow: FabricMemoryCall<\"memory.expand\", FabricMemoryExpandArgs>;\n}\ntype FabricMemoryRecallHit = FabricMemoryRecallEntryHit | FabricMemoryRecallSessionHit | FabricLcmMemoryHit;\ninterface FabricMemoryError {\n code: string;\n message: string;\n [key: string]: unknown;\n}\ninterface FabricMemoryCoverage {\n complete: boolean;\n indexedSessions: number;\n eligibleSessions: number;\n staleSessions: number;\n incompleteSessions: number;\n reasons: string[];\n error?: FabricMemoryError;\n}\ninterface FabricMemoryRecallResult {\n total: number;\n hits: FabricMemoryRecallHit[];\n next: FabricMemoryCall<\"memory.recall\", FabricMemoryRecallArgs> | null;\n coverage: FabricMemoryCoverage;\n error?: FabricMemoryError;\n}\ninterface FabricMemoryExpandedEntry {\n index: number;\n entryId: string | null;\n parentId: string | null;\n type: string | null;\n role: string | null;\n timestamp: number | null;\n isError: boolean;\n anchor?: boolean;\n text: string;\n textRange: { start: number; end: number; total: number; complete: boolean };\n parentEntryId?: string | null;\n operationAddress?: string | null;\n tool?: string | null;\n ref?: string | null;\n provider?: string | null;\n action?: string | null;\n outcome?: \"succeeded\" | \"failed\" | \"aborted\" | \"timed_out\";\n filesTouched?: Array<string | null>;\n operation?: unknown;\n branchFact?: unknown;\n structuredContent?: unknown;\n structuredTruncated?: boolean;\n factAddress?: string | null;\n carrierEntryId?: string | null;\n carrierParentId?: string | null;\n carrierFromId?: string | null;\n}\ninterface FabricMemoryExpandResult {\n session?: string;\n sourceHash?: string;\n branches?: FabricMemoryBranches;\n lineageFingerprint?: string;\n entryCount?: number;\n entries: FabricMemoryExpandedEntry[];\n next?: FabricMemoryCall<\"memory.expand\", FabricMemoryExpandArgs> | null;\n error?: FabricMemoryError;\n}\ninterface FabricMemoryWalkResult {\n visited: number;\n stopped: boolean;\n error?: FabricMemoryError;\n}\ninterface FabricMemorySessionInfo {\n id: string;\n file: string;\n cwd: string;\n mtime: number;\n entryCount: number;\n tier: \"hot\" | \"cold\";\n branches: FabricMemoryBranches;\n lineageFingerprint: string | null;\n}\ninterface FabricMemoryApi {\n recall(args?: FabricMemoryRecallArgs): Promise<FabricMemoryRecallResult>;\n expand(args: FabricMemoryExpandArgs): Promise<FabricMemoryExpandResult>;\n walk(\n args: FabricMemoryExpandArgs,\n visitor: (\n entry: FabricMemoryExpandedEntry,\n index: number,\n ) => boolean | void | Promise<boolean | void>,\n ): Promise<FabricMemoryWalkResult>;\n sessions(args?: {\n scope?: string;\n branches?: FabricMemoryBranches;\n limit?: number;\n max?: number;\n offset?: number;\n }): Promise<{\n scope?: string;\n branches?: FabricMemoryBranches;\n offset?: number;\n total?: number;\n truncated?: boolean;\n sessions?: FabricMemorySessionInfo[];\n error?: FabricMemoryError;\n }>;\n}\ninterface FabricStateTransitionArgs {\n label: string;\n from?: string;\n to: string;\n summary: string;\n evidence?: string[];\n tags?: string[];\n kind?: \"state\" | \"representation\";\n complexity?: { files: string[] };\n force?: boolean;\n name?: string;\n description?: string;\n}\ninterface FabricStateComplexityFile {\n file: string;\n supported: boolean;\n language?: string;\n current?: number;\n recorded?: number;\n delta?: number;\n recordedDelta?: number;\n}\ninterface FabricStateVerificationResult {\n certified: boolean;\n violated: boolean;\n certificationStatus: \"certified\" | \"failed\";\n results: unknown[];\n failures: unknown[];\n certificate?: unknown;\n reportingError?: string;\n evidenceDigest: string;\n resultDigest: string;\n}\ninterface FabricStateApi {\n transition(args: FabricStateTransitionArgs): Promise<{ event: FabricMeshEvent; head: unknown }>;\n get(): Promise<{\n head: unknown | null;\n goal: { check: string; description?: string } | null;\n complexity: { files: number; decisionPoints: number; lastNetDelta: number };\n certification: { current: unknown | null; recent: unknown[] };\n recentLabels: string[];\n }>;\n history(args?: { label?: string; limit?: number; includeArchived?: boolean; name?: string; max?: number }): Promise<{\n transitions: unknown[];\n labels: string[];\n certifications: unknown[];\n }>;\n complexity(args?: { files?: string[]; paths?: string[] }): Promise<{ files: FabricStateComplexityFile[]; netDelta: number }>;\n verify(args?: { labels?: string[]; includeArchived?: boolean; timeoutMs?: number; label?: string }): Promise<FabricStateVerificationResult>;\n goal(args: { check: string; description?: string; command?: string; cmd?: string; predicate?: string }): Promise<FabricMeshStateEntry<{ check: string; description?: string }>>;\n checkGoal(args?: { timeoutMs?: number }): Promise<{\n passed: boolean;\n output: string;\n exitCode: number | null;\n error?: string;\n }>;\n}\ntype FabricSchemaEvidence =\n | { kind: \"file_exists\"; path: string }\n | { kind: \"file_absent\"; path: string }\n | { kind: \"file_contains\"; path: string; literal: string }\n | { kind: \"file_sha256\"; path: string; sha256: string }\n | { kind: \"trusted_command\"; name: string };\ntype FabricSchemaFileOperation =\n | { kind: \"write\"; path: string; content: string; expected: { absent: true } | { sha256: string } }\n | { kind: \"edit\"; path: string; oldText: string; newText: string; expectedSha256: string }\n | { kind: \"delete\"; path: string; expectedSha256: string };\ninterface FabricSchemaEvidenceResult {\n evidence: FabricSchemaEvidence;\n status: \"confirmed\" | \"nonconfirmed\" | \"error\";\n detail: string;\n exitCode?: number | null;\n output?: string;\n observedSha256?: string;\n}\ninterface FabricSchemaStatus {\n mode: \"off\" | \"audit\" | \"enforce\";\n certificateTtlMs: number;\n maxFiles: number;\n maxBytes: number;\n trustedCommands: string[];\n generation: number;\n lastOutcome: \"committed\" | \"rolled_back\" | \"quarantined\" | null;\n hypotheses: Array<{\n id: string;\n label: string;\n status: string;\n generation: number;\n updatedAt: number;\n }>;\n}\ninterface FabricSchemaVerificationResult {\n verified: boolean;\n hypothesisId: string;\n certificate?: string;\n issuedAt?: number;\n expiresAt?: number;\n reason?: string;\n results: FabricSchemaEvidenceResult[];\n}\ninterface FabricSchemaCommitResult {\n outcome: \"committed\" | \"rolled_back\" | \"quarantined\";\n transactionId: string;\n generation?: number;\n paths?: string[];\n postconditions?: FabricSchemaEvidenceResult[];\n complexityReductionCertified?: boolean;\n stateTransition?: unknown;\n error?: string;\n rollbackError?: string;\n}\ninterface FabricSchemaApi {\n status(): Promise<FabricSchemaStatus>;\n hypothesize(args: {\n label: string;\n summary: string;\n evidence: FabricSchemaEvidence[];\n complexityReduction?: boolean;\n name?: string;\n description?: string;\n complexity_reduction?: boolean;\n }): Promise<{\n hypothesisId: string;\n status: string;\n state: unknown;\n fingerprint: string;\n generation: number;\n }>;\n verify(args: { hypothesisId: string; id?: string; hypothesis_id?: string }): Promise<FabricSchemaVerificationResult>;\n commit(args: {\n hypothesisId: string;\n certificate: string;\n operations: FabricSchemaFileOperation[];\n postconditions: FabricSchemaEvidence[];\n id?: string;\n hypothesis_id?: string;\n }): Promise<FabricSchemaCommitResult>;\n abort(args: { hypothesisId: string; certificate?: string; id?: string; hypothesis_id?: string }): Promise<{\n aborted: true;\n hypothesisId: string;\n }>;\n}\ninterface FabricCompactPendingIntent {\n reason?: string;\n instructions?: string;\n preserve?: string[];\n requestedBy: string;\n requestedAt: number;\n}\ninterface FabricCompactLastCommit {\n at: number;\n requestedBy: string;\n status: \"committed\" | \"skipped\" | \"cancelled\" | \"failed\";\n summary?: string;\n tokensBefore?: number;\n estimatedTokensAfter?: number;\n error?: string;\n persisted?: boolean;\n}\ninterface FabricCompactContextUsage {\n known: boolean;\n tokens: number | null;\n contextWindow: number | null;\n percent: number | null;\n remainingTokens: number | null;\n}\ninterface FabricCompactStatus {\n pending?: FabricCompactPendingIntent;\n last?: FabricCompactLastCommit;\n context?: FabricCompactContextUsage;\n engine?: string;\n targetContextRatio?: number;\n model?: string;\n sessionId?: string;\n}\ntype FabricComponentState = \"waiting\" | \"loading\" | \"active\" | \"unloading\" | \"failed\" | \"quarantined\" | \"disposed\";\ninterface FabricComponentEffectInfo {\n label: string;\n kind: \"none\" | \"scoped\" | \"transactional\" | \"emission\";\n resources: string[];\n ordering: \"commutative\" | \"ordered\" | \"unknown\";\n}\ninterface FabricComponentEffectConflict {\n withComponent: string;\n resources: string[];\n reason: \"shared_resource\" | \"unknown_resource\";\n}\ninterface FabricComponentInfo {\n id: string;\n component: string;\n parentId?: string;\n state: FabricComponentState;\n guarantee: \"managed\" | \"revertible\";\n requirements: string[];\n provisions: string[];\n missing: string[];\n optionalMissing: string[];\n effects?: FabricComponentEffectInfo[];\n effectConflicts?: FabricComponentEffectConflict[];\n targetDigest?: string;\n error?: string;\n cleanupErrors?: string[];\n revision: number;\n createdAt: number;\n updatedAt: number;\n}\ninterface FabricComponentsApi {\n list(): Promise<{\n definitions: Array<{ name: string; description?: string; revision: number; requirements: string[]; provisions: string[] }>;\n components: FabricComponentInfo[];\n }>;\n status(args: { id: string }): Promise<FabricComponentInfo>;\n graph(): Promise<{\n components: FabricComponentInfo[];\n edges: Array<{ from: string; to: string; ref: string; kind?: \"dependency\" | \"ownership\" }>;\n cycles: string[][];\n }>;\n reload(args?: { id?: string }): Promise<{ components: FabricComponentInfo[] }>;\n}\n\ninterface FabricCompactApi {\n request(args?: {\n reason?: string;\n instructions?: string;\n preserve?: string[];\n requestedBy?: string;\n instruction?: string;\n requested_by?: string;\n }): Promise<{ requested: true; intent: FabricCompactPendingIntent }>;\n status(): Promise<FabricCompactStatus>;\n cancel(): Promise<{ cancelled: true }>;\n}\n\ninterface FabricCodemapSymbolCounts {\n files: number;\n symbols: number;\n languages: Record<string, number>;\n fallbackFiles: number;\n truncated: boolean;\n elapsedMs: number;\n}\ninterface FabricCodemapCascadeEdge {\n file: string;\n score: number;\n commits: number;\n}\ninterface FabricCodemapCascade {\n seeds: string[];\n edges: FabricCodemapCascadeEdge[];\n commitsScanned: number;\n truncated: boolean;\n unavailable?: string;\n}\ninterface FabricCodemapApi {\n map(args?: {\n path?: string;\n maxTokens?: number;\n glob?: string;\n focus?: string;\n seeds?: string[];\n refresh?: boolean;\n }): Promise<{\n text: string;\n root: string;\n tokensEstimated: number;\n filesShown: number;\n symbolsShown: number;\n omittedFiles: number;\n omittedSymbols: number;\n truncated: boolean;\n indexed: FabricCodemapSymbolCounts;\n cascade?: FabricCodemapCascade;\n }>;\n cascade(args: {\n path?: string;\n seeds: string[];\n limit?: number;\n maxCommits?: number;\n }): Promise<FabricCodemapCascade>;\n}\n\ninterface FabricWorkflowAgentOptions extends Omit<FabricAgentRequest, \"task\"> {\n label?: string;\n}\ntype FabricActivityStatus = \"pending\" | \"running\" | \"completed\" | \"failed\" | \"blocked\" | \"stopped\";\ntype FabricActivityKind = \"agent\" | \"actor\" | \"tool\" | \"extension\" | \"mcp\" | \"mesh\" | \"task\" | \"custom\";\ninterface FabricWorkflowDisplay {\n name?: string;\n description?: string;\n}\ninterface FabricWorkflowPhaseOptions {\n id?: string;\n description?: string;\n total?: number;\n}\ninterface FabricWorkflowPhaseInput extends FabricWorkflowPhaseOptions {\n name: string;\n}\ninterface FabricWorkflowItem {\n id: string;\n label: string;\n status?: FabricActivityStatus;\n phase?: string;\n detail?: string;\n kind?: FabricActivityKind;\n current?: string;\n total?: number;\n completed?: number;\n data?: unknown;\n}\ninterface FabricWorkflowApi {\n agent<T = string>(prompt: string, options?: FabricWorkflowAgentOptions): Promise<T>;\n parallel<T, R>(items: T[], mapper: (item: T, index: number) => Promise<R> | R, concurrency?: number | { concurrency?: number }): Promise<R[]>;\n parallel<T>(thunks: Array<() => Promise<T> | T>, concurrency?: number | { concurrency?: number }): Promise<T[]>;\n pipeline<T>(items: T[], ...stages: Array<(value: unknown, original: T, index: number) => Promise<unknown> | unknown>): Promise<unknown[]>;\n configure(display: FabricWorkflowDisplay): Promise<FabricWorkflowDisplay>;\n phase(name: string, options?: FabricWorkflowPhaseOptions): Promise<{ name: string; index: number; id?: string }>;\n phase(input: FabricWorkflowPhaseInput): Promise<{ name: string; index: number; id?: string }>;\n item(item: FabricWorkflowItem): Promise<FabricWorkflowItem>;\n event(event: { message: string; level?: \"info\" | \"success\" | \"warning\" | \"error\"; data?: unknown }): Promise<void>;\n log(...values: unknown[]): void;\n budget: { total: number; spent(): number; remaining(): number };\n}\ninterface FabricJudgmentChoiceQuestion {\n type: \"choice\";\n instructions: string;\n criteria: Record<string, string | null>;\n}\ninterface FabricJudgmentBoolQuestion {\n type: \"bool\";\n instructions: string;\n criteria?: { true?: string; false?: string };\n}\ninterface FabricJudgmentScoreQuestion {\n type: \"score\";\n instructions: string;\n criteria: [string, string, ...string[]];\n}\ntype FabricJudgmentQuestion =\n | FabricJudgmentChoiceQuestion\n | FabricJudgmentBoolQuestion\n | FabricJudgmentScoreQuestion;\ninterface FabricJudgmentChoiceAnswer {\n type: \"choice\";\n choice: string;\n probabilities: Record<string, number>;\n confidence: number;\n}\ninterface FabricJudgmentBoolAnswer {\n type: \"bool\";\n bool: number;\n}\ninterface FabricJudgmentScoreAnswer {\n type: \"score\";\n score: number;\n probabilities: Record<string, number>;\n confidence: number;\n}\ntype FabricJudgmentAnswer =\n | FabricJudgmentChoiceAnswer\n | FabricJudgmentBoolAnswer\n | FabricJudgmentScoreAnswer;\ninterface FabricJudgmentApi {\n ask(args: {\n state: unknown;\n questions: Record<string, FabricJudgmentQuestion>;\n }): Promise<\n | { ok: true; backend: string; answers: Record<string, FabricJudgmentAnswer> }\n | {\n ok: false;\n reason: \"disabled\" | \"unsupported\" | \"refused\" | \"failed\" | \"timeout\" | \"aborted\";\n detail?: string;\n }\n >;\n stats(): Promise<{\n enabled: boolean;\n requests: number;\n batched: number;\n questions: number;\n merged: number;\n failures: number;\n refusals: number;\n timeouts: number;\n lastBackend?: string;\n lastError?: string;\n }>;\n}\ninterface FabricJudgeFilterOptions {\n threshold?: number;\n onFail?: \"keep-all\" | \"empty\" | \"throw\";\n maxItems?: number;\n maxBytes?: number;\n}\ninterface FabricJudgeClassifyOptions {\n onFail?: \"keep-all\" | \"empty\" | \"throw\";\n fallbackCategory?: string;\n maxItems?: number;\n maxBytes?: number;\n}\ninterface FabricJudgeBoolOptions {\n fallback?: number;\n}\ninterface FabricJudgeChoiceOptions {\n fallback?: string;\n}\ninterface FabricJudgeScoreOptions {\n fallback?: number;\n}\ninterface FabricJudgeApi {\n ask(args: {\n state: unknown;\n questions: Record<string, FabricJudgmentQuestion>;\n }): Promise<\n | { ok: true; backend: string; answers: Record<string, FabricJudgmentAnswer> }\n | {\n ok: false;\n reason: \"disabled\" | \"unsupported\" | \"refused\" | \"failed\" | \"timeout\" | \"aborted\";\n detail?: string;\n }\n >;\n ask(\n state: unknown,\n questions: Record<string, FabricJudgmentQuestion>,\n ): Promise<\n | { ok: true; backend: string; answers: Record<string, FabricJudgmentAnswer> }\n | {\n ok: false;\n reason: \"disabled\" | \"unsupported\" | \"refused\" | \"failed\" | \"timeout\" | \"aborted\";\n detail?: string;\n }\n >;\n bool(state: unknown, instructions: string, options?: FabricJudgeBoolOptions): Promise<number | undefined>;\n choice(\n state: unknown,\n options: readonly string[] | Record<string, string | null>,\n instructions: string,\n config?: FabricJudgeChoiceOptions,\n ): Promise<string | undefined>;\n score(\n state: unknown,\n criteria: readonly string[],\n instructions: string,\n config?: FabricJudgeScoreOptions,\n ): Promise<number | undefined>;\n filter<T>(items: T[], instructions: string, options?: FabricJudgeFilterOptions): Promise<T[]>;\n classify<T, C extends string>(\n items: T[],\n categories: readonly C[],\n instructions: string,\n options?: FabricJudgeClassifyOptions,\n ): Promise<Array<{ item: T; category?: C; confidence?: number }>>;\n}\ndeclare const tools: FabricToolsApi;\ndeclare const omp: OmpToolsApi;\ndeclare const extensions: FabricExtensionsApi;\ndeclare const agents: FabricAgentsApi;\ndeclare const mesh: FabricMeshApi;\ndeclare const mcp: FabricMcpApi;\ndeclare const memory: FabricMemoryApi;\ndeclare const state: FabricStateApi;\ndeclare const schema: FabricSchemaApi;\ndeclare const components: FabricComponentsApi;\ndeclare const compact: FabricCompactApi;\ndeclare const codemap: FabricCodemapApi;\ndeclare const judgment: FabricJudgmentApi;\ndeclare const judge: FabricJudgeApi;\ndeclare const council: FabricCouncilApi;\ndeclare const workflow: FabricWorkflowApi;\ndeclare function agent<T = string>(prompt: string, options?: FabricWorkflowAgentOptions): Promise<T>;\ndeclare function parallel<T, R>(items: T[], mapper: (item: T, index: number) => Promise<R> | R, concurrency?: number | { concurrency?: number }): Promise<R[]>;\ndeclare function parallel<T>(thunks: Array<() => Promise<T> | T>, concurrency?: number | { concurrency?: number }): Promise<T[]>;\ndeclare function pipeline<T>(items: T[], ...stages: Array<(value: unknown, original: T, index: number) => Promise<unknown> | unknown>): Promise<unknown[]>;\ndeclare function phase(name: string, options?: FabricWorkflowPhaseOptions): Promise<{ name: string; index: number; id?: string }>;\ndeclare function phase(input: FabricWorkflowPhaseInput): Promise<{ name: string; index: number; id?: string }>;\ndeclare function log(...values: unknown[]): void;\ndeclare const budget: FabricWorkflowApi[\"budget\"];\ntype FabricRlmRequest = Omit<FabricAgentRequest, \"runner\" | \"recursive\" | \"cwd\"> & { runner?: \"omp\" };\ndeclare const rlm: { query(args: FabricRlmRequest): Promise<FabricAgentResult> };\ninterface FabricConsole {\n log(...args: unknown[]): void;\n info(...args: unknown[]): void;\n warn(...args: unknown[]): void;\n error(...args: unknown[]): void;\n}\ndeclare const console: FabricConsole;\ndeclare const payloads: Readonly<Record<string, string>>;\ndeclare function print(...args: unknown[]): void;\ndeclare function setTimeout(handler: (...args: any[]) => void, timeout?: number): number;\ndeclare function clearTimeout(handle: number): void;\ndeclare function setInterval(handler: (...args: any[]) => void, timeout?: number): number;\ndeclare function clearInterval(handle: number): void;\n`;\n\nconst FULL_CODE_GLOBAL_DECLARATIONS = [\n \"declare const omp: OmpToolsApi;\\n\",\n \"declare const extensions: FabricExtensionsApi;\\n\",\n];\n\nconst OMP_LOOSE_DECLARATION = \"declare const omp: OmpToolsApi;\\n\";\nconst MCP_LOOSE_DECLARATION = \"declare const mcp: FabricMcpApi;\\n\";\nconst EXTENSIONS_LOOSE_DECLARATION = \"declare const extensions: FabricExtensionsApi;\\n\";\n\nexport interface FabricGuestDeclarationOptions {\n /** Global names to omit (for example providers disabled by configuration). */\n excludeGlobals?: readonly string[];\n /**\n * Pre-rendered replacement blocks from buildDynamicGuestDeclarations().\n * Applied only when the loose anchor line is still present \u2014 excluded\n * globals (or orchestration-only mode, for extensions) keep nothing to\n * replace, and missing/undefined sections keep the loose surface.\n */\n dynamic?: FabricDynamicGuestDeclarations;\n /** Add captured core overloads to the full-code OMP declaration. */\n coreOverrides?: string;\n}\n\nconst globalDeclarationLine = (name: string): RegExp =>\n new RegExp(`^declare const ${name}: [^\\\\n]*;\\\\n`, \"m\");\n\nconst terminatedDeclaration = (block: string): string =>\n block.endsWith(\"\\n\") ? block : `${block}\\n`;\n\nexport const guestTypeDeclarations = (\n fullCodeMode: boolean,\n options: FabricGuestDeclarationOptions = {},\n): string => {\n const base = fullCodeMode\n ? GUEST_TYPE_DECLARATIONS\n : FULL_CODE_GLOBAL_DECLARATIONS.reduce(\n (declarations, declaration) => declarations.replace(declaration, \"\"),\n GUEST_TYPE_DECLARATIONS,\n );\n let result = (options.excludeGlobals ?? []).reduce(\n (declarations, name) => declarations.replace(globalDeclarationLine(name), \"\"),\n base,\n );\n if (fullCodeMode && options.coreOverrides && result.includes(OMP_LOOSE_DECLARATION)) {\n result = result.replace(\n OMP_LOOSE_DECLARATION,\n terminatedDeclaration(options.coreOverrides),\n );\n }\n if (options.dynamic?.mcp && result.includes(MCP_LOOSE_DECLARATION)) {\n result = result.replace(\n MCP_LOOSE_DECLARATION,\n terminatedDeclaration(options.dynamic.mcp),\n );\n }\n if (options.dynamic?.extensions && result.includes(EXTENSIONS_LOOSE_DECLARATION)) {\n result = result.replace(\n EXTENSIONS_LOOSE_DECLARATION,\n terminatedDeclaration(options.dynamic.extensions),\n );\n }\n return result;\n};\n"],
5
+ "mappings": ";AAQO,IAAM,6CAA6C;AAAA,EACxD,MAAM;AAAA,EACN,MAAM;AAAA,EACN,MAAM;AAAA,EACN,OAAO;AAAA,EACP,MAAM;AAAA,EACN,MAAM;AAAA,EACN,IAAI;AACN;AAEO,IAAM,0BAA0B;AAAA,EACrC,MAAM,CAAC,UAAU,OAAO;AAAA,EACxB,MAAM,CAAC,SAAS;AAAA,EAChB,MAAM,CAAC;AAAA,EACP,OAAO,CAAC;AAAA,EACR,MAAM,CAAC,WAAW,QAAQ,OAAO;AAAA,EACjC,MAAM,CAAC,OAAO;AAAA,EACd,IAAI,CAAC,OAAO;AACd;AAEO,IAAM,0BAA0B;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;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AsB,QAAQ,QAAQ,UAAU;AAAA,IAClD;AAAA,EACF;AACA,SAAO;AACT;",
6
+ "names": []
7
+ }
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  readSessionHeader
3
- } from "./chunk-G3ELO3QC.js";
3
+ } from "./chunk-Z6TTRT6Q.js";
4
4
 
5
5
  // src/memory/discovery.ts
6
6
  import crypto from "node:crypto";
@@ -252,4 +252,4 @@ export {
252
252
  InvalidProjectScopeError,
253
253
  resolveScope
254
254
  };
255
- //# sourceMappingURL=chunk-GPJV2FSP.js.map
255
+ //# sourceMappingURL=chunk-WX6C7N3W.js.map
@@ -21,7 +21,7 @@ import {
21
21
  import {
22
22
  peerLabelPrefix,
23
23
  writeHandoffSession
24
- } from "./chunk-H3KRHDDF.js";
24
+ } from "./chunk-QJKOPPW2.js";
25
25
  import {
26
26
  DEFAULT_FABRIC_CONFIG,
27
27
  MAX_AGENT_TIMEOUT_MS,
@@ -6784,4 +6784,4 @@ export {
6784
6784
  agentParticipantRecords,
6785
6785
  actorParticipantRecord
6786
6786
  };
6787
- //# sourceMappingURL=chunk-ABBGHQVX.js.map
6787
+ //# sourceMappingURL=chunk-YAI5SCIE.js.map
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  readFabricBranchSummaryDetails,
3
3
  readFabricProjectionTrace
4
- } from "./chunk-3BS4RMF4.js";
4
+ } from "./chunk-AZBJNZS4.js";
5
5
 
6
6
  // src/memory/normalize.ts
7
7
  import fs from "node:fs";
@@ -644,4 +644,4 @@ export {
644
644
  expandSessionEntries,
645
645
  expandSessionEntriesChecked
646
646
  };
647
- //# sourceMappingURL=chunk-G3ELO3QC.js.map
647
+ //# sourceMappingURL=chunk-Z6TTRT6Q.js.map
@@ -4,12 +4,12 @@ import {
4
4
  fabricCompactionVersion,
5
5
  rawContextTokens,
6
6
  registerCompactionHook
7
- } from "../chunks/chunk-BQG4LFAC.js";
7
+ } from "../chunks/chunk-D55BFSFK.js";
8
8
  import "../chunks/chunk-3J7BKUNG.js";
9
9
  import "../chunks/chunk-QSRTEINF.js";
10
10
  import "../chunks/chunk-UAP6IQIR.js";
11
- import "../chunks/chunk-3BS4RMF4.js";
12
- import "../chunks/chunk-JBKYNJFN.js";
11
+ import "../chunks/chunk-AZBJNZS4.js";
12
+ import "../chunks/chunk-FL4A542C.js";
13
13
  import "../chunks/chunk-ATTYOQSI.js";
14
14
  export {
15
15
  compileFabricSummary,
@@ -10,8 +10,8 @@ import {
10
10
  import {
11
11
  sessionDirNamesForCwd,
12
12
  sessionsDirRoot
13
- } from "../chunks/chunk-GPJV2FSP.js";
14
- import "../chunks/chunk-G3ELO3QC.js";
13
+ } from "../chunks/chunk-WX6C7N3W.js";
14
+ import "../chunks/chunk-Z6TTRT6Q.js";
15
15
  import {
16
16
  DEFAULT_LCM_MAX_INPUT_CHARS,
17
17
  LcmModelAdapter,
@@ -45,8 +45,8 @@ import {
45
45
  clipUtf8,
46
46
  utf8Bytes
47
47
  } from "../chunks/chunk-UAP6IQIR.js";
48
- import "../chunks/chunk-3BS4RMF4.js";
49
- import "../chunks/chunk-JBKYNJFN.js";
48
+ import "../chunks/chunk-AZBJNZS4.js";
49
+ import "../chunks/chunk-FL4A542C.js";
50
50
  import "../chunks/chunk-ATTYOQSI.js";
51
51
 
52
52
  // src/compaction/lcm-runtime.ts
@@ -1,14 +1,14 @@
1
1
  import {
2
2
  ActionRegistry,
3
3
  NESTED_TOOL_CALL_ID_PREFIX
4
- } from "../chunks/chunk-3KORI7FQ.js";
4
+ } from "../chunks/chunk-KLWNXXEI.js";
5
5
  import "../chunks/chunk-LMAVZN7J.js";
6
6
  import "../chunks/chunk-7TB7NXSL.js";
7
7
  import "../chunks/chunk-4A4MVZQW.js";
8
8
  import "../chunks/chunk-X2SKPWJA.js";
9
9
  import "../chunks/chunk-77FQHHZD.js";
10
10
  import "../chunks/chunk-7363CD5A.js";
11
- import "../chunks/chunk-JBKYNJFN.js";
11
+ import "../chunks/chunk-FL4A542C.js";
12
12
  import "../chunks/chunk-ATTYOQSI.js";
13
13
  export {
14
14
  ActionRegistry,
@@ -1 +1 @@
1
- {"version":3,"file":"system-guidance.d.ts","sourceRoot":"","sources":["../../src/core/system-guidance.ts"],"names":[],"mappings":"AA6BA,eAAO,MAAM,6BAA6B,GACxC,cAAc,OAAO,EACrB,kBAAiB,SAAS,MAAM,EAAO,KACtC,MAqBU,CAAC;AAEd,eAAO,MAAM,8BAA8B,GACzC,cAAc,OAAO,EACrB,kBAAiB,SAAS,MAAM,EAAO,KACtC,MAKmW,CAAC;AAGvW,MAAM,WAAW,yBAAyB;IACxC,IAAI,EAAE,MAAM,CAAC;IACb,UAAU,CAAC,EAAE;QAAE,MAAM,CAAC,EAAE,MAAM,CAAC;QAAC,IAAI,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;CACjD;AAqCD,eAAO,MAAM,2BAA2B,GACtC,OAAO,aAAa,CAAC,yBAAyB,CAAC,EAC/C,eAAe,WAAW,CAAC,MAAM,CAAC,KACjC,MAAM,GAAG,SA8BX,CAAC;AAEF,eAAO,MAAM,oBAAoB,GAAI,MAAM,KAAK,GAAG,OAAO,GAAG,SAAS,KAAG,MAAM,GAAG,SAQjF,CAAC"}
1
+ {"version":3,"file":"system-guidance.d.ts","sourceRoot":"","sources":["../../src/core/system-guidance.ts"],"names":[],"mappings":"AA6BA,eAAO,MAAM,6BAA6B,GACxC,cAAc,OAAO,EACrB,kBAAiB,SAAS,MAAM,EAAO,KACtC,MAqBU,CAAC;AAEd,eAAO,MAAM,8BAA8B,GACzC,cAAc,OAAO,EACrB,kBAAiB,SAAS,MAAM,EAAO,KACtC,MAKmW,CAAC;AAGvW,MAAM,WAAW,yBAAyB;IACxC,IAAI,EAAE,MAAM,CAAC;IACb,UAAU,CAAC,EAAE;QAAE,MAAM,CAAC,EAAE,MAAM,CAAC;QAAC,IAAI,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;CACjD;AAwCD,eAAO,MAAM,2BAA2B,GACtC,OAAO,aAAa,CAAC,yBAAyB,CAAC,EAC/C,eAAe,WAAW,CAAC,MAAM,CAAC,KACjC,MAAM,GAAG,SAgCX,CAAC;AAEF,eAAO,MAAM,oBAAoB,GAAI,MAAM,KAAK,GAAG,OAAO,GAAG,SAAS,KAAG,MAAM,GAAG,SAQjF,CAAC"}
@@ -60,7 +60,7 @@ import {
60
60
  staticFreedomFromSchema,
61
61
  surfaceFreedomReport,
62
62
  trendFromScores
63
- } from "../chunks/chunk-WUPYPFAC.js";
63
+ } from "../chunks/chunk-E3KTE736.js";
64
64
  import {
65
65
  compiledSurfaceDirectory,
66
66
  loadCompiledSurface,
@@ -82,12 +82,12 @@ import {
82
82
  replaySuccessfulCallsAsync,
83
83
  schemaDigest
84
84
  } from "../chunks/chunk-4A4MVZQW.js";
85
- import "../chunks/chunk-GPJV2FSP.js";
86
- import "../chunks/chunk-G3ELO3QC.js";
85
+ import "../chunks/chunk-WX6C7N3W.js";
86
+ import "../chunks/chunk-Z6TTRT6Q.js";
87
87
  import "../chunks/chunk-7363CD5A.js";
88
88
  import "../chunks/chunk-KAD7UWT2.js";
89
- import "../chunks/chunk-3BS4RMF4.js";
90
- import "../chunks/chunk-JBKYNJFN.js";
89
+ import "../chunks/chunk-AZBJNZS4.js";
90
+ import "../chunks/chunk-FL4A542C.js";
91
91
  import "../chunks/chunk-ATTYOQSI.js";
92
92
  export {
93
93
  AUTO_APPLY_PROPOSAL_KINDS,
@@ -11,8 +11,8 @@ import {
11
11
  MemoryProvider,
12
12
  actionArgNormalizer,
13
13
  uniqueDeclaredKeyForSpelling
14
- } from "./chunks/chunk-REHGQCXU.js";
15
- import "./chunks/chunk-63VIZJGS.js";
14
+ } from "./chunks/chunk-J2BDKPO4.js";
15
+ import "./chunks/chunk-BWLZ6VDQ.js";
16
16
  import "./chunks/chunk-U5FYOMG5.js";
17
17
  import {
18
18
  ApprovalController,
@@ -33,7 +33,7 @@ import {
33
33
  repairFabricGuestCode,
34
34
  resolveFabricIdentity,
35
35
  runFabricHandoffAtBoundary
36
- } from "./chunks/chunk-XLINRLLP.js";
36
+ } from "./chunks/chunk-PIW2DEO2.js";
37
37
  import "./chunks/chunk-7VIQNUPS.js";
38
38
  import {
39
39
  AgentTranscriptReader,
@@ -50,7 +50,7 @@ import {
50
50
  repairActionName,
51
51
  setActiveCompiledSurface,
52
52
  setActiveRepairCompiler
53
- } from "./chunks/chunk-3KORI7FQ.js";
53
+ } from "./chunks/chunk-KLWNXXEI.js";
54
54
  import {
55
55
  formatFabricEffectConflict
56
56
  } from "./chunks/chunk-LMAVZN7J.js";
@@ -63,8 +63,8 @@ import {
63
63
  withExclusiveFileLockAsync
64
64
  } from "./chunks/chunk-YWEXP724.js";
65
65
  import "./chunks/chunk-4A4MVZQW.js";
66
- import "./chunks/chunk-GPJV2FSP.js";
67
- import "./chunks/chunk-G3ELO3QC.js";
66
+ import "./chunks/chunk-WX6C7N3W.js";
67
+ import "./chunks/chunk-Z6TTRT6Q.js";
68
68
  import {
69
69
  FABRIC_COMPONENT_DISCOVER_EVENT,
70
70
  FABRIC_PROVIDER_DISCOVER_EVENT,
@@ -94,7 +94,7 @@ import {
94
94
  resolveAgentCwd,
95
95
  resolveOmpBinary,
96
96
  validateAgentCwdRequest
97
- } from "./chunks/chunk-ABBGHQVX.js";
97
+ } from "./chunks/chunk-YAI5SCIE.js";
98
98
  import "./chunks/chunk-VPPIJRNZ.js";
99
99
  import {
100
100
  executeFile,
@@ -104,7 +104,7 @@ import {
104
104
  import "./chunks/chunk-CT2AJ2UI.js";
105
105
  import {
106
106
  checkedHandoffCompaction
107
- } from "./chunks/chunk-H3KRHDDF.js";
107
+ } from "./chunks/chunk-QJKOPPW2.js";
108
108
  import {
109
109
  DEFAULT_FABRIC_CONFIG,
110
110
  FUZZY_RESOLUTION_MARKERS,
@@ -154,7 +154,7 @@ import {
154
154
  import {
155
155
  estimateTokens,
156
156
  fabricExecTitleHintCached
157
- } from "./chunks/chunk-BQG4LFAC.js";
157
+ } from "./chunks/chunk-D55BFSFK.js";
158
158
  import "./chunks/chunk-3J7BKUNG.js";
159
159
  import {
160
160
  MAX_COMPACTION_INSTRUCTIONS_CHARS,
@@ -164,12 +164,12 @@ import {
164
164
  encodeCompactionRequest
165
165
  } from "./chunks/chunk-QSRTEINF.js";
166
166
  import "./chunks/chunk-UAP6IQIR.js";
167
- import "./chunks/chunk-3BS4RMF4.js";
167
+ import "./chunks/chunk-AZBJNZS4.js";
168
168
  import {
169
169
  FabricExecutionTraceRecorder,
170
170
  FabricTraceSafeError,
171
171
  executionOutcomeFromError
172
- } from "./chunks/chunk-JBKYNJFN.js";
172
+ } from "./chunks/chunk-FL4A542C.js";
173
173
  import {
174
174
  OMP_GUEST_TOOL_NAMES,
175
175
  OMP_GUEST_TOOL_NAME_SET,
@@ -10773,6 +10773,10 @@ var GREP_SKIP_PROPERTY = {
10773
10773
  type: "number",
10774
10774
  description: "Files to skip before collecting results \u2014 paginate when a search hit the file limit"
10775
10775
  };
10776
+ var GREP_LIMIT_PROPERTY = {
10777
+ type: "number",
10778
+ description: "Cap on total surfaced matches \u2014 applied on top of the per-file and file-window caps, never above them"
10779
+ };
10776
10780
  var GITIGNORE_PROPERTY = {
10777
10781
  type: "boolean",
10778
10782
  description: "Respect gitignore rules; pass false to search ignored files such as build output or .env"
@@ -10793,7 +10797,7 @@ var withExtraProperties = (document, extras) => {
10793
10797
  if (Object.keys(additions).length === 0) return document;
10794
10798
  return { ...schema, properties: { ...properties, ...additions } };
10795
10799
  };
10796
- var withGrepSkipSchema = (document) => withExtraProperties(document, { skip: GREP_SKIP_PROPERTY, gitignore: GITIGNORE_PROPERTY });
10800
+ var withGrepOptionSchema = (document) => withExtraProperties(document, { skip: GREP_SKIP_PROPERTY, limit: GREP_LIMIT_PROPERTY, gitignore: GITIGNORE_PROPERTY });
10797
10801
  var withFindFilterSchema = (document) => withExtraProperties(document, { gitignore: GITIGNORE_PROPERTY, hidden: HIDDEN_PROPERTY });
10798
10802
  var grepSession = (cwd, context) => ({
10799
10803
  cwd,
@@ -10804,12 +10808,12 @@ var grepSession = (cwd, context) => ({
10804
10808
  context === void 0 ? void 0 : { "grep.contextBefore": Math.max(0, Math.floor(context)), "grep.contextAfter": Math.max(0, Math.floor(context)) }
10805
10809
  )
10806
10810
  });
10807
- var createGrepDefinitionWithSkip = (cwd) => {
10811
+ var createGrepDefinitionWithOptions = (cwd) => {
10808
10812
  const legacy = createGrepToolDefinition(cwd);
10809
10813
  const defaultTool = new GrepTool(grepSession(cwd));
10810
10814
  return {
10811
10815
  ...legacy,
10812
- parameters: withGrepSkipSchema(legacy.parameters),
10816
+ parameters: withGrepOptionSchema(legacy.parameters),
10813
10817
  execute: (toolCallId, params, signal, onUpdate, context) => {
10814
10818
  const record2 = asRecord(params) ?? {};
10815
10819
  const rawPattern = typeof record2.pattern === "string" ? record2.pattern : "";
@@ -10817,7 +10821,8 @@ var createGrepDefinitionWithSkip = (cwd) => {
10817
10821
  const glob = typeof record2.glob === "string" ? record2.glob : void 0;
10818
10822
  const contextLines = typeof record2.context === "number" ? record2.context : void 0;
10819
10823
  const skip = typeof record2.skip === "number" ? record2.skip : void 0;
10820
- const tool = contextLines === void 0 ? defaultTool : new GrepTool(grepSession(cwd, contextLines));
10824
+ const limit = typeof record2.limit === "number" ? record2.limit : void 0;
10825
+ const tool = contextLines === void 0 && limit === void 0 ? defaultTool : new GrepTool(grepSession(cwd, contextLines), limit === void 0 ? void 0 : { totalMatchLimit: limit });
10821
10826
  return tool.execute(
10822
10827
  toolCallId,
10823
10828
  {
@@ -11036,8 +11041,19 @@ var unreadableReadMessage = (note, readPath) => {
11036
11041
  const remedy = target ? ` Read the bytes with omp.read("${target}:raw").` : "";
11037
11042
  return `omp.read returned no text content: ${note.trim()}${remedy}`;
11038
11043
  };
11039
- var restoreBashOutput = (artifactPath, maxChars, delivered, artifactElidedBytes) => {
11044
+ var artifactFailureClause = (artifactError) => typeof artifactError === "string" ? `the host failed to save it (artifact ${artifactError} failed)` : "the host failed to save it";
11045
+ var oversizedArtifactBytes = (artifactPath, maxChars) => {
11046
+ if (!artifactPath || maxChars <= 0) return void 0;
11047
+ try {
11048
+ const { size } = statSync4(artifactPath);
11049
+ return size > maxChars ? size : void 0;
11050
+ } catch {
11051
+ return void 0;
11052
+ }
11053
+ };
11054
+ var restoreBashOutput = (artifactPath, maxChars, delivered, artifactElidedBytes, artifactError) => {
11040
11055
  if (!artifactPath || maxChars <= 0) return void 0;
11056
+ if (artifactError !== void 0) return void 0;
11041
11057
  if (artifactElidedBytes !== void 0 && artifactElidedBytes > 0) return void 0;
11042
11058
  let size;
11043
11059
  try {
@@ -11067,15 +11083,24 @@ var withoutColumnLimit = (detailRecord, metaRecord) => {
11067
11083
  const { meta: _meta, ...remainingDetails } = detailRecord;
11068
11084
  return remainingDetails;
11069
11085
  };
11070
- var grepTruncationSignal = (details) => {
11086
+ var grepTruncationSignal = (details, requestedLimit) => {
11071
11087
  const record2 = asRecord(details);
11072
11088
  if (!record2 || record2.truncated !== true) return void 0;
11073
- const perFile = finiteNumber2(record2.perFileLimitReached);
11089
+ const reached = finiteNumber2(record2.perFileLimitReached);
11090
+ const askedFor = requestedLimit === void 0 ? void 0 : Math.max(1, Math.floor(requestedLimit));
11091
+ const totalLimit = reached !== void 0 && reached === askedFor ? reached : void 0;
11092
+ const perFile = totalLimit === void 0 ? reached : void 0;
11074
11093
  const maxColumn = finiteNumber2(asRecord(asRecord(asRecord(record2.meta)?.limits)?.columnTruncated)?.maxColumn);
11075
11094
  const fileCount = finiteNumber2(record2.fileCount);
11076
11095
  const reasons = [];
11077
11096
  const notes = [];
11078
11097
  let continuation = null;
11098
+ if (totalLimit !== void 0) {
11099
+ reasons.push("matchLimit");
11100
+ notes.push(
11101
+ `Only the first ${totalLimit} matches are returned because limit=${totalLimit}; raise limit or narrow the pattern.`
11102
+ );
11103
+ }
11079
11104
  if (perFile !== void 0) {
11080
11105
  reasons.push("matchLimit");
11081
11106
  notes.push(
@@ -11101,6 +11126,7 @@ var grepTruncationSignal = (details) => {
11101
11126
  reasons,
11102
11127
  ...finiteNumber2(record2.matchCount) === void 0 ? {} : { matchCount: record2.matchCount },
11103
11128
  ...fileCount === void 0 ? {} : { fileCount },
11129
+ ...totalLimit === void 0 ? {} : { matchLimit: totalLimit },
11104
11130
  ...perFile === void 0 ? {} : { perFileMatchLimit: perFile },
11105
11131
  ...maxColumn === void 0 ? {} : { maxColumn },
11106
11132
  continue: continuation,
@@ -11205,7 +11231,7 @@ var normalizeResult = (name, result, artifactPaths, appendReadNewline = true, ex
11205
11231
  return readSignal?.signal ? appendTruncationMarker(body, readSignal.signal) : body;
11206
11232
  }
11207
11233
  if (name === "grep") {
11208
- const signal = grepTruncationSignal(result.details);
11234
+ const signal = grepTruncationSignal(result.details, extras?.grepLimit);
11209
11235
  return signal ? appendTruncationMarker(text, signal) : text;
11210
11236
  }
11211
11237
  if (name === "find") {
@@ -11226,7 +11252,8 @@ var normalizeResult = (name, result, artifactPaths, appendReadNewline = true, ex
11226
11252
  if (truncation && typeof truncation === "object" && !Array.isArray(truncation)) {
11227
11253
  const truncationRecord = truncation;
11228
11254
  const artifactId = truncationRecord.artifactId;
11229
- const fullOutputPath = typeof artifactId === "string" ? artifactPaths?.get(artifactId) ?? extras?.bashArtifactPath : extras?.bashArtifactPath;
11255
+ const artifactError = metaRecord?.artifactError;
11256
+ const fullOutputPath = artifactError !== void 0 ? void 0 : typeof artifactId === "string" ? artifactPaths?.get(artifactId) ?? extras?.bashArtifactPath : extras?.bashArtifactPath;
11230
11257
  const artifactElidedBytes = finiteNumber2(truncationRecord.artifactElidedBytes);
11231
11258
  details = {
11232
11259
  ...detailRecord,
@@ -11246,7 +11273,7 @@ var normalizeResult = (name, result, artifactPaths, appendReadNewline = true, ex
11246
11273
  ...columnCap === void 0 ? {} : { maxColumn: columnCap },
11247
11274
  fullOutputPath: fullOutputPath ?? null,
11248
11275
  continue: null,
11249
- note: fullOutputPath ? artifactElidedBytes === void 0 ? `Output exceeded the host bash result budget; the complete stream is on disk at ${fullOutputPath}.` : `Output exceeded the host bash result budget, and the on-disk artifact at ${fullOutputPath} is itself capped: ${artifactElidedBytes} bytes were dropped from its middle. Only the artifact's head and tail survive; set the host's \`tools.artifactMaxBytes\` to \`0\` for an uncapped file.` : "Output exceeded the host bash result budget and no full-output artifact was retained."
11276
+ note: artifactError !== void 0 ? `Output exceeded the host bash result budget and ${artifactFailureClause(artifactError)}, so the full output is unrecoverable.` : fullOutputPath ? artifactElidedBytes === void 0 ? `Output exceeded the host bash result budget; the complete stream is on disk at ${fullOutputPath}.` : `Output exceeded the host bash result budget, and the on-disk artifact at ${fullOutputPath} is itself capped: ${artifactElidedBytes} bytes were dropped from its middle. Only the artifact's head and tail survive; set the host's \`tools.artifactMaxBytes\` to \`0\` for an uncapped file.` : "Output exceeded the host bash result budget and no full-output artifact was retained."
11250
11277
  });
11251
11278
  }
11252
11279
  } else {
@@ -11255,26 +11282,31 @@ var normalizeResult = (name, result, artifactPaths, appendReadNewline = true, ex
11255
11282
  const columnElidedBytes = finiteNumber2(
11256
11283
  asRecord(asRecord(metaRecord?.limits)?.columnTruncated)?.artifactElidedBytes
11257
11284
  );
11285
+ const artifactError = metaRecord?.artifactError;
11286
+ const maxChars = extras?.maxResultChars ?? 0;
11258
11287
  const restored = restoreBashOutput(
11259
11288
  extras?.bashArtifactPath,
11260
- extras?.maxResultChars ?? 0,
11289
+ maxChars,
11261
11290
  text,
11262
- columnElidedBytes
11291
+ columnElidedBytes,
11292
+ artifactError
11263
11293
  );
11264
11294
  if (restored === void 0) {
11295
+ const fullOutputPath = artifactError === void 0 ? extras?.bashArtifactPath : void 0;
11296
+ const oversizedBytes = columnElidedBytes === void 0 ? oversizedArtifactBytes(fullOutputPath, maxChars) : void 0;
11265
11297
  details = {
11266
11298
  ...detailRecord,
11267
11299
  columnTruncated: { maxColumn: columnCap, restored: false },
11268
- ...extras?.bashArtifactPath ? { fullOutputPath: extras.bashArtifactPath } : {}
11300
+ ...fullOutputPath ? { fullOutputPath } : {}
11269
11301
  };
11270
11302
  output = appendTruncationMarker(text, {
11271
11303
  tool: name,
11272
11304
  partial: true,
11273
11305
  reasons: ["columnLimit"],
11274
11306
  maxColumn: columnCap,
11275
- fullOutputPath: extras?.bashArtifactPath ?? null,
11307
+ fullOutputPath: fullOutputPath ?? null,
11276
11308
  continue: null,
11277
- note: columnElidedBytes !== void 0 && columnElidedBytes > 0 ? `Output lines were cut at ${columnCap} bytes by the host bash executor, and the artifact is itself capped: ${columnElidedBytes} bytes were dropped from its middle, so the full output is unrecoverable. Set the host's \`tools.artifactMaxBytes\` to \`0\` for an uncapped file.` : `Output lines were cut at ${columnCap} bytes by the host bash executor, which reads global settings and ignores this session's tools.outputMaxColumns.`
11309
+ note: artifactError !== void 0 ? `Output lines were cut at ${columnCap} bytes by the host bash executor and ${artifactFailureClause(artifactError)}, so the full output is unrecoverable.` : columnElidedBytes !== void 0 && columnElidedBytes > 0 ? `Output lines were cut at ${columnCap} bytes by the host bash executor, and the artifact is itself capped: ${columnElidedBytes} bytes were dropped from its middle, so the full output is unrecoverable. Set the host's \`tools.artifactMaxBytes\` to \`0\` for an uncapped file.` : oversizedBytes !== void 0 && fullOutputPath ? `Output lines were cut at ${columnCap} bytes by the host bash executor; the complete output is on disk at ${fullOutputPath}, ${oversizedBytes} bytes that exceed this session's \`executor.maxNestedResultChars\` (${maxChars}), so it was not inlined here.` : `Output lines were cut at ${columnCap} bytes by the host bash executor, which reads global settings and ignores this session's tools.outputMaxColumns.`
11278
11310
  });
11279
11311
  } else {
11280
11312
  output = restored;
@@ -11321,7 +11353,7 @@ var OmpToolsProvider = class _OmpToolsProvider {
11321
11353
  bash: createNativeBashToolDefinition(cwd, this.#artifacts, this.#identity, this.#autoBackground),
11322
11354
  edit: createNativeReplaceEditToolDefinition(cwd, this.#identity),
11323
11355
  write: createPreviewWriteToolDefinition(cwd, createNativeSession(cwd, { identity: this.#identity })),
11324
- grep: createGrepDefinitionWithSkip(cwd),
11356
+ grep: createGrepDefinitionWithOptions(cwd),
11325
11357
  find: createFindDefinitionWithFilters(cwd),
11326
11358
  ls: createLsToolDefinition(cwd),
11327
11359
  wait: createNativeWaitToolDefinition(cwd, this.#identity, this.#autoBackground)
@@ -11550,6 +11582,10 @@ var OmpToolsProvider = class _OmpToolsProvider {
11550
11582
  // provider boundary; replacement is idempotent when middleware already ran.
11551
11583
  async #normalizeResult(name, result, args, context, appendReadNewline = true, artifacts) {
11552
11584
  const extras = {};
11585
+ if (name === "grep") {
11586
+ const limit = finiteNumber2(args.limit);
11587
+ if (limit !== void 0) extras.grepLimit = limit;
11588
+ }
11553
11589
  if (isOmpShellToolName(name)) {
11554
11590
  const artifactPath = artifacts?.at(-1);
11555
11591
  if (artifactPath !== void 0) extras.bashArtifactPath = artifactPath;