comisai 1.0.36 → 1.0.37

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 (239) hide show
  1. package/node_modules/@comis/agent/dist/background/auto-background-middleware.js +9 -0
  2. package/node_modules/@comis/agent/dist/background/background-task-manager.d.ts +22 -2
  3. package/node_modules/@comis/agent/dist/background/background-task-manager.js +48 -41
  4. package/node_modules/@comis/agent/dist/background/background-task-persistence.js +28 -5
  5. package/node_modules/@comis/agent/dist/background/background-task-types.d.ts +49 -0
  6. package/node_modules/@comis/agent/dist/background/completion-dispatcher.d.ts +130 -0
  7. package/node_modules/@comis/agent/dist/background/completion-dispatcher.js +215 -0
  8. package/node_modules/@comis/agent/dist/background/completion-runner.d.ts +10 -1
  9. package/node_modules/@comis/agent/dist/background/completion-runner.js +98 -15
  10. package/node_modules/@comis/agent/dist/background/index.d.ts +6 -1
  11. package/node_modules/@comis/agent/dist/background/index.js +2 -0
  12. package/node_modules/@comis/agent/dist/background/session-resolver.d.ts +85 -0
  13. package/node_modules/@comis/agent/dist/background/session-resolver.js +78 -0
  14. package/node_modules/@comis/agent/dist/bootstrap/sections/messaging-sections.js +1 -0
  15. package/node_modules/@comis/agent/dist/bootstrap/sections/tool-descriptions.js +3 -3
  16. package/node_modules/@comis/agent/dist/bootstrap/sections/tooling-sections.d.ts +30 -2
  17. package/node_modules/@comis/agent/dist/bootstrap/sections/tooling-sections.js +51 -2
  18. package/node_modules/@comis/agent/dist/bootstrap/system-prompt-assembler.d.ts +22 -0
  19. package/node_modules/@comis/agent/dist/bootstrap/system-prompt-assembler.js +2 -2
  20. package/node_modules/@comis/agent/dist/bridge/bridge-event-handlers.d.ts +1 -5
  21. package/node_modules/@comis/agent/dist/bridge/bridge-event-handlers.js +2 -14
  22. package/node_modules/@comis/agent/dist/bridge/bridge-metrics.d.ts +26 -0
  23. package/node_modules/@comis/agent/dist/bridge/bridge-metrics.js +3 -0
  24. package/node_modules/@comis/agent/dist/bridge/pi-event-bridge.d.ts +9 -0
  25. package/node_modules/@comis/agent/dist/bridge/pi-event-bridge.js +73 -2
  26. package/node_modules/@comis/agent/dist/context-engine/signature-surrogate-guard.d.ts +10 -10
  27. package/node_modules/@comis/agent/dist/context-engine/signature-surrogate-guard.js +14 -14
  28. package/node_modules/@comis/agent/dist/context-engine/thinking-block-cleaner.d.ts +11 -13
  29. package/node_modules/@comis/agent/dist/context-engine/thinking-block-cleaner.js +14 -15
  30. package/node_modules/@comis/agent/dist/executor/capability-index-context.d.ts +72 -0
  31. package/node_modules/@comis/agent/dist/executor/capability-index-context.js +329 -0
  32. package/node_modules/@comis/agent/dist/executor/drain-helper.d.ts +122 -0
  33. package/node_modules/@comis/agent/dist/executor/drain-helper.js +173 -0
  34. package/node_modules/@comis/agent/dist/executor/error-classifier.js +2 -2
  35. package/node_modules/@comis/agent/dist/executor/executor-post-execution.d.ts +48 -4
  36. package/node_modules/@comis/agent/dist/executor/executor-post-execution.js +134 -31
  37. package/node_modules/@comis/agent/dist/executor/executor-prompt-runner.d.ts +7 -0
  38. package/node_modules/@comis/agent/dist/executor/executor-prompt-runner.js +25 -4
  39. package/node_modules/@comis/agent/dist/executor/executor-tool-assembly.d.ts +18 -1
  40. package/node_modules/@comis/agent/dist/executor/executor-tool-assembly.js +19 -16
  41. package/node_modules/@comis/agent/dist/executor/jit-guide-injector.d.ts +11 -2
  42. package/node_modules/@comis/agent/dist/executor/jit-guide-injector.js +16 -2
  43. package/node_modules/@comis/agent/dist/executor/pi-executor.d.ts +8 -2
  44. package/node_modules/@comis/agent/dist/executor/pi-executor.js +25 -12
  45. package/node_modules/@comis/agent/dist/executor/prompt-assembly.d.ts +9 -1
  46. package/node_modules/@comis/agent/dist/executor/prompt-assembly.js +15 -1
  47. package/node_modules/@comis/agent/dist/executor/tool-deferral.d.ts +18 -27
  48. package/node_modules/@comis/agent/dist/executor/tool-deferral.js +29 -38
  49. package/node_modules/@comis/agent/dist/model/model-registry-adapter.js +1 -1
  50. package/node_modules/@comis/agent/dist/model/model-scanner.js +1 -1
  51. package/node_modules/@comis/agent/dist/safety/tool-retry-breaker.d.ts +11 -1
  52. package/node_modules/@comis/agent/dist/safety/tool-retry-breaker.js +19 -22
  53. package/node_modules/@comis/agent/dist/session/comis-session-manager.d.ts +16 -2
  54. package/node_modules/@comis/agent/dist/spawn/pi-mono-adapters.d.ts +1 -1
  55. package/node_modules/@comis/agent/dist/spawn/pi-mono-adapters.js +5 -5
  56. package/node_modules/@comis/agent/dist/workspace/data-env.d.ts +38 -0
  57. package/node_modules/@comis/agent/dist/workspace/data-env.js +56 -0
  58. package/node_modules/@comis/agent/dist/workspace/index.d.ts +1 -0
  59. package/node_modules/@comis/agent/dist/workspace/index.js +1 -0
  60. package/node_modules/@comis/agent/dist/workspace/templates.js +5 -1
  61. package/node_modules/@comis/agent/package.json +1 -1
  62. package/node_modules/@comis/channels/dist/index.d.ts +1 -1
  63. package/node_modules/@comis/channels/dist/index.js +1 -1
  64. package/node_modules/@comis/channels/dist/shared/channel-manager.d.ts +9 -3
  65. package/node_modules/@comis/channels/dist/shared/inbound-gate.d.ts +1 -1
  66. package/node_modules/@comis/channels/dist/shared/inbound-gate.js +22 -7
  67. package/node_modules/@comis/channels/dist/shared/inbound-pipeline.d.ts +10 -3
  68. package/node_modules/@comis/channels/dist/shared/inbound-route.d.ts +1 -1
  69. package/node_modules/@comis/channels/dist/shared/inbound-route.js +13 -2
  70. package/node_modules/@comis/channels/dist/shared/response-filter.d.ts +11 -24
  71. package/node_modules/@comis/channels/dist/shared/response-filter.js +25 -53
  72. package/node_modules/@comis/channels/package.json +1 -1
  73. package/node_modules/@comis/cli/dist/commands/providers.d.ts +1 -2
  74. package/node_modules/@comis/cli/dist/commands/providers.js +5 -6
  75. package/node_modules/@comis/cli/package.json +1 -1
  76. package/node_modules/@comis/core/dist/config/field-metadata.js +2 -0
  77. package/node_modules/@comis/core/dist/config/immutable-keys.js +4 -1
  78. package/node_modules/@comis/core/dist/config/index.d.ts +4 -0
  79. package/node_modules/@comis/core/dist/config/index.js +2 -0
  80. package/node_modules/@comis/core/dist/config/schema-agent.d.ts +0 -792
  81. package/node_modules/@comis/core/dist/config/schema-approvals.d.ts +0 -14
  82. package/node_modules/@comis/core/dist/config/schema-auto-reply-engine.d.ts +0 -6
  83. package/node_modules/@comis/core/dist/config/schema-background-tasks.d.ts +0 -12
  84. package/node_modules/@comis/core/dist/config/schema-browser.d.ts +0 -18
  85. package/node_modules/@comis/core/dist/config/schema-channel.d.ts +0 -158
  86. package/node_modules/@comis/core/dist/config/schema-coalescer.d.ts +0 -5
  87. package/node_modules/@comis/core/dist/config/schema-daemon.d.ts +0 -32
  88. package/node_modules/@comis/core/dist/config/schema-delivery.d.ts +0 -18
  89. package/node_modules/@comis/core/dist/config/schema-documentation.d.ts +0 -12
  90. package/node_modules/@comis/core/dist/config/schema-embedding.d.ts +0 -20
  91. package/node_modules/@comis/core/dist/config/schema-envelope.d.ts +0 -15
  92. package/node_modules/@comis/core/dist/config/schema-gateway.d.ts +0 -37
  93. package/node_modules/@comis/core/dist/config/schema-gemini-cache.d.ts +0 -2
  94. package/node_modules/@comis/core/dist/config/schema-integrations.d.ts +0 -318
  95. package/node_modules/@comis/core/dist/config/schema-lifecycle-reactions.d.ts +0 -18
  96. package/node_modules/@comis/core/dist/config/schema-memory-review.d.ts +0 -7
  97. package/node_modules/@comis/core/dist/config/schema-memory.d.ts +0 -16
  98. package/node_modules/@comis/core/dist/config/schema-messages.d.ts +0 -8
  99. package/node_modules/@comis/core/dist/config/schema-models.d.ts +0 -15
  100. package/node_modules/@comis/core/dist/config/schema-notification.d.ts +0 -5
  101. package/node_modules/@comis/core/dist/config/schema-oauth.d.ts +0 -5
  102. package/node_modules/@comis/core/dist/config/schema-observability.d.ts +0 -38
  103. package/node_modules/@comis/core/dist/config/schema-output-retention.d.ts +34 -0
  104. package/node_modules/@comis/core/dist/config/schema-output-retention.js +48 -0
  105. package/node_modules/@comis/core/dist/config/schema-plugins.d.ts +0 -8
  106. package/node_modules/@comis/core/dist/config/schema-providers.d.ts +0 -64
  107. package/node_modules/@comis/core/dist/config/schema-queue.d.ts +0 -58
  108. package/node_modules/@comis/core/dist/config/schema-response-prefix.d.ts +0 -2
  109. package/node_modules/@comis/core/dist/config/schema-retry.d.ts +0 -6
  110. package/node_modules/@comis/core/dist/config/schema-scheduler.d.ts +0 -39
  111. package/node_modules/@comis/core/dist/config/schema-secrets.d.ts +0 -3
  112. package/node_modules/@comis/core/dist/config/schema-security.d.ts +0 -18
  113. package/node_modules/@comis/core/dist/config/schema-send-policy.d.ts +0 -13
  114. package/node_modules/@comis/core/dist/config/schema-sender-trust-display.d.ts +0 -5
  115. package/node_modules/@comis/core/dist/config/schema-serializer.js +2 -0
  116. package/node_modules/@comis/core/dist/config/schema-skills.d.ts +0 -61
  117. package/node_modules/@comis/core/dist/config/schema-streaming.d.ts +0 -38
  118. package/node_modules/@comis/core/dist/config/schema-telegram-file-guard.d.ts +0 -3
  119. package/node_modules/@comis/core/dist/config/schema-tooling.d.ts +87 -0
  120. package/node_modules/@comis/core/dist/config/schema-tooling.js +152 -0
  121. package/node_modules/@comis/core/dist/config/schema-verbosity.d.ts +0 -12
  122. package/node_modules/@comis/core/dist/config/schema-webhooks.d.ts +0 -40
  123. package/node_modules/@comis/core/dist/config/schema.d.ts +41 -38
  124. package/node_modules/@comis/core/dist/config/schema.js +6 -0
  125. package/node_modules/@comis/core/dist/context/context.d.ts +0 -4
  126. package/node_modules/@comis/core/dist/domain/approval-request.d.ts +0 -17
  127. package/node_modules/@comis/core/dist/domain/background-task-origin.d.ts +0 -10
  128. package/node_modules/@comis/core/dist/domain/delivery-origin.d.ts +0 -5
  129. package/node_modules/@comis/core/dist/domain/execution-graph.d.ts +0 -48
  130. package/node_modules/@comis/core/dist/domain/memory-entry.d.ts +0 -3
  131. package/node_modules/@comis/core/dist/domain/model-compat.d.ts +0 -4
  132. package/node_modules/@comis/core/dist/domain/normalized-message.d.ts +0 -15
  133. package/node_modules/@comis/core/dist/domain/provider-capabilities.d.ts +0 -6
  134. package/node_modules/@comis/core/dist/domain/rich-message.d.ts +0 -14
  135. package/node_modules/@comis/core/dist/domain/subagent-context-config.d.ts +0 -22
  136. package/node_modules/@comis/core/dist/domain/subagent-context-types.d.ts +0 -8
  137. package/node_modules/@comis/core/dist/event-bus/events-agent.d.ts +31 -0
  138. package/node_modules/@comis/core/dist/event-bus/events-infra.d.ts +5 -0
  139. package/node_modules/@comis/core/dist/exports/config.d.ts +2 -2
  140. package/node_modules/@comis/core/dist/exports/config.js +3 -1
  141. package/node_modules/@comis/core/dist/exports/hooks.d.ts +1 -1
  142. package/node_modules/@comis/core/dist/exports/ports.d.ts +2 -2
  143. package/node_modules/@comis/core/dist/exports/ports.js +1 -1
  144. package/node_modules/@comis/core/dist/ports/channel-plugin.d.ts +0 -13
  145. package/node_modules/@comis/core/dist/ports/index.d.ts +2 -0
  146. package/node_modules/@comis/core/dist/ports/index.js +4 -0
  147. package/node_modules/@comis/core/dist/ports/no-op-tool-capability.d.ts +30 -0
  148. package/node_modules/@comis/core/dist/ports/no-op-tool-capability.js +47 -0
  149. package/node_modules/@comis/core/dist/ports/tool-capability.d.ts +165 -0
  150. package/node_modules/@comis/core/dist/ports/tool-capability.js +15 -0
  151. package/node_modules/@comis/core/dist/security/audit.d.ts +0 -11
  152. package/node_modules/@comis/core/dist/tool-metadata.d.ts +21 -1
  153. package/node_modules/@comis/core/dist/tool-metadata.js +1 -1
  154. package/node_modules/@comis/core/package.json +1 -1
  155. package/node_modules/@comis/daemon/bundled-skills/skill-creator/scripts/validate-skill.py +1 -1
  156. package/node_modules/@comis/daemon/dist/daemon.js +89 -14
  157. package/node_modules/@comis/daemon/dist/rpc/agent-inline-workspace.d.ts +1 -1
  158. package/node_modules/@comis/daemon/dist/rpc/agent-inline-workspace.js +1 -1
  159. package/node_modules/@comis/daemon/dist/rpc/builtin-provider-guard.js +2 -2
  160. package/node_modules/@comis/daemon/dist/rpc/credential-resolver.js +1 -1
  161. package/node_modules/@comis/daemon/dist/rpc/model-handlers.d.ts +1 -1
  162. package/node_modules/@comis/daemon/dist/rpc/model-handlers.js +2 -2
  163. package/node_modules/@comis/daemon/dist/sub-agent-runner.d.ts +18 -0
  164. package/node_modules/@comis/daemon/dist/sub-agent-runner.js +41 -9
  165. package/node_modules/@comis/daemon/dist/wiring/index.d.ts +2 -0
  166. package/node_modules/@comis/daemon/dist/wiring/index.js +1 -0
  167. package/node_modules/@comis/daemon/dist/wiring/setup-agents.d.ts +36 -2
  168. package/node_modules/@comis/daemon/dist/wiring/setup-agents.js +45 -8
  169. package/node_modules/@comis/daemon/dist/wiring/setup-background-completion-runner.d.ts +28 -9
  170. package/node_modules/@comis/daemon/dist/wiring/setup-background-completion-runner.js +36 -9
  171. package/node_modules/@comis/daemon/dist/wiring/setup-background-tasks.js +2 -2
  172. package/node_modules/@comis/daemon/dist/wiring/setup-channels.d.ts +9 -2
  173. package/node_modules/@comis/daemon/dist/wiring/setup-channels.js +15 -9
  174. package/node_modules/@comis/daemon/dist/wiring/setup-cross-session.d.ts +20 -5
  175. package/node_modules/@comis/daemon/dist/wiring/setup-cross-session.js +20 -15
  176. package/node_modules/@comis/daemon/dist/wiring/setup-delivery.js +14 -2
  177. package/node_modules/@comis/daemon/dist/wiring/setup-gateway.d.ts +4 -6
  178. package/node_modules/@comis/daemon/dist/wiring/setup-gateway.js +3 -5
  179. package/node_modules/@comis/daemon/dist/wiring/setup-heartbeat.d.ts +20 -5
  180. package/node_modules/@comis/daemon/dist/wiring/setup-heartbeat.js +11 -2
  181. package/node_modules/@comis/daemon/dist/wiring/setup-output-retention.d.ts +89 -0
  182. package/node_modules/@comis/daemon/dist/wiring/setup-output-retention.js +212 -0
  183. package/node_modules/@comis/daemon/dist/wiring/setup-tools.d.ts +18 -4
  184. package/node_modules/@comis/daemon/dist/wiring/setup-tools.js +29 -10
  185. package/node_modules/@comis/daemon/dist/wiring/tool-capability-adapter.d.ts +75 -0
  186. package/node_modules/@comis/daemon/dist/wiring/tool-capability-adapter.js +253 -0
  187. package/node_modules/@comis/daemon/package.json +1 -1
  188. package/node_modules/@comis/gateway/dist/webhook/webhook-endpoint.d.ts +0 -4
  189. package/node_modules/@comis/gateway/package.json +1 -1
  190. package/node_modules/@comis/infra/package.json +1 -1
  191. package/node_modules/@comis/memory/package.json +1 -1
  192. package/node_modules/@comis/scheduler/dist/cron/cron-types.d.ts +0 -42
  193. package/node_modules/@comis/scheduler/dist/heartbeat/agent-heartbeat-source.d.ts +29 -8
  194. package/node_modules/@comis/scheduler/dist/heartbeat/agent-heartbeat-source.js +19 -7
  195. package/node_modules/@comis/scheduler/dist/system-events/system-event-types.d.ts +0 -3
  196. package/node_modules/@comis/scheduler/dist/tasks/task-types.d.ts +0 -17
  197. package/node_modules/@comis/scheduler/package.json +1 -1
  198. package/node_modules/@comis/shared/dist/index.d.ts +3 -0
  199. package/node_modules/@comis/shared/dist/index.js +4 -0
  200. package/node_modules/@comis/shared/dist/mcp-tool-name.d.ts +78 -0
  201. package/node_modules/@comis/shared/dist/mcp-tool-name.js +92 -0
  202. package/node_modules/@comis/shared/dist/silent-tokens.d.ts +38 -0
  203. package/node_modules/@comis/shared/dist/silent-tokens.js +51 -0
  204. package/node_modules/@comis/shared/dist/visible-delivery.d.ts +28 -0
  205. package/node_modules/@comis/shared/dist/visible-delivery.js +16 -0
  206. package/node_modules/@comis/shared/package.json +1 -1
  207. package/node_modules/@comis/skills/dist/bridge/mcp-tool-bridge.d.ts +2 -13
  208. package/node_modules/@comis/skills/dist/bridge/mcp-tool-bridge.js +3 -21
  209. package/node_modules/@comis/skills/dist/bridge/tool-metadata-enforcement.js +1 -1
  210. package/node_modules/@comis/skills/dist/bridge/tool-metadata-registry.js +4 -4
  211. package/node_modules/@comis/skills/dist/builtin/exec-tool.d.ts +55 -9
  212. package/node_modules/@comis/skills/dist/builtin/exec-tool.js +383 -19
  213. package/node_modules/@comis/skills/dist/builtin/install-detour.d.ts +67 -0
  214. package/node_modules/@comis/skills/dist/builtin/install-detour.js +342 -0
  215. package/node_modules/@comis/skills/dist/builtin/platform/admin-manage-factory.js +5 -5
  216. package/node_modules/@comis/skills/dist/builtin/platform/agents-manage-tool.d.ts +2 -2
  217. package/node_modules/@comis/skills/dist/builtin/platform/agents-manage-tool.js +2 -2
  218. package/node_modules/@comis/skills/dist/builtin/platform/message-tool.js +18 -0
  219. package/node_modules/@comis/skills/dist/builtin/platform/messaging-factory.d.ts +18 -1
  220. package/node_modules/@comis/skills/dist/builtin/platform/messaging-factory.js +18 -2
  221. package/node_modules/@comis/skills/dist/builtin/platform/models-manage-tool.js +3 -3
  222. package/node_modules/@comis/skills/dist/builtin/process-registry.d.ts +14 -0
  223. package/node_modules/@comis/skills/dist/builtin/process-tool.d.ts +24 -4
  224. package/node_modules/@comis/skills/dist/builtin/process-tool.js +25 -7
  225. package/node_modules/@comis/skills/dist/builtin/sandbox/bwrap-provider.d.ts +1 -1
  226. package/node_modules/@comis/skills/dist/builtin/sandbox/bwrap-provider.js +9 -0
  227. package/node_modules/@comis/skills/dist/index.d.ts +4 -1
  228. package/node_modules/@comis/skills/dist/index.js +3 -1
  229. package/node_modules/@comis/skills/dist/manifest/capability-parser.d.ts +44 -0
  230. package/node_modules/@comis/skills/dist/manifest/capability-parser.js +68 -0
  231. package/node_modules/@comis/skills/dist/manifest/schema.d.ts +44 -37
  232. package/node_modules/@comis/skills/dist/manifest/schema.js +35 -0
  233. package/node_modules/@comis/skills/dist/registry/discovery.d.ts +8 -0
  234. package/node_modules/@comis/skills/dist/registry/discovery.js +10 -3
  235. package/node_modules/@comis/skills/dist/registry/skill-registry.d.ts +45 -1
  236. package/node_modules/@comis/skills/dist/registry/skill-registry.js +70 -7
  237. package/node_modules/@comis/skills/package.json +1 -1
  238. package/node_modules/@comis/web/package.json +1 -1
  239. package/package.json +21 -21
@@ -43,19 +43,15 @@ export type ToolCallArgumentsEncoding = z.infer<typeof ToolCallArgumentsEncoding
43
43
  * Strict object: unknown fields are rejected to catch typos early.
44
44
  */
45
45
  export declare const ModelCompatConfigSchema: z.ZodObject<{
46
- /** Whether this model supports tool use. Undefined = assume yes. */
47
46
  supportsTools: z.ZodOptional<z.ZodBoolean>;
48
- /** Tool schema transformation profile. Undefined = "default". */
49
47
  toolSchemaProfile: z.ZodOptional<z.ZodEnum<{
50
48
  default: "default";
51
49
  xai: "xai";
52
50
  }>>;
53
- /** How the model encodes tool call arguments. Undefined = "json". */
54
51
  toolCallArgumentsEncoding: z.ZodOptional<z.ZodEnum<{
55
52
  json: "json";
56
53
  "html-entities": "html-entities";
57
54
  }>>;
58
- /** Whether the model has a native web search tool (e.g., Perplexity). Undefined = false. */
59
55
  nativeWebSearchTool: z.ZodOptional<z.ZodBoolean>;
60
56
  }, z.core.$strict>;
61
57
  export type ModelCompatConfig = z.infer<typeof ModelCompatConfigSchema>;
@@ -4,9 +4,7 @@ import { z } from "zod";
4
4
  * Voice-specific metadata for voice notes and audio messages.
5
5
  */
6
6
  export declare const VoiceMetaSchema: z.ZodObject<{
7
- /** Base64-encoded waveform amplitude data (256 samples, 0-255) */
8
7
  waveform: z.ZodOptional<z.ZodString>;
9
- /** Audio codec name (e.g., "opus", "vorbis", "aac") */
10
8
  codec: z.ZodOptional<z.ZodString>;
11
9
  }, z.core.$strict>;
12
10
  export type VoiceMeta = z.infer<typeof VoiceMetaSchema>;
@@ -25,18 +23,12 @@ export declare const AttachmentSchema: z.ZodObject<{
25
23
  mimeType: z.ZodOptional<z.ZodString>;
26
24
  fileName: z.ZodOptional<z.ZodString>;
27
25
  sizeBytes: z.ZodOptional<z.ZodNumber>;
28
- /** Audio/video duration in milliseconds */
29
26
  durationMs: z.ZodOptional<z.ZodNumber>;
30
- /** Whether this is a voice note (not regular audio) */
31
27
  isVoiceNote: z.ZodOptional<z.ZodBoolean>;
32
- /** Voice-specific metadata (waveform, codec) */
33
28
  voiceMeta: z.ZodOptional<z.ZodObject<{
34
- /** Base64-encoded waveform amplitude data (256 samples, 0-255) */
35
29
  waveform: z.ZodOptional<z.ZodString>;
36
- /** Audio codec name (e.g., "opus", "vorbis", "aac") */
37
30
  codec: z.ZodOptional<z.ZodString>;
38
31
  }, z.core.$strict>>;
39
- /** Transcription text (filled by STT pipeline) */
40
32
  transcription: z.ZodOptional<z.ZodString>;
41
33
  }, z.core.$strict>;
42
34
  export type Attachment = z.infer<typeof AttachmentSchema>;
@@ -66,22 +58,15 @@ export declare const NormalizedMessageSchema: z.ZodObject<{
66
58
  mimeType: z.ZodOptional<z.ZodString>;
67
59
  fileName: z.ZodOptional<z.ZodString>;
68
60
  sizeBytes: z.ZodOptional<z.ZodNumber>;
69
- /** Audio/video duration in milliseconds */
70
61
  durationMs: z.ZodOptional<z.ZodNumber>;
71
- /** Whether this is a voice note (not regular audio) */
72
62
  isVoiceNote: z.ZodOptional<z.ZodBoolean>;
73
- /** Voice-specific metadata (waveform, codec) */
74
63
  voiceMeta: z.ZodOptional<z.ZodObject<{
75
- /** Base64-encoded waveform amplitude data (256 samples, 0-255) */
76
64
  waveform: z.ZodOptional<z.ZodString>;
77
- /** Audio codec name (e.g., "opus", "vorbis", "aac") */
78
65
  codec: z.ZodOptional<z.ZodString>;
79
66
  }, z.core.$strict>>;
80
- /** Transcription text (filled by STT pipeline) */
81
67
  transcription: z.ZodOptional<z.ZodString>;
82
68
  }, z.core.$strict>>>;
83
69
  replyTo: z.ZodOptional<z.ZodGUID>;
84
- /** Normalized chat type derived from platform metadata. */
85
70
  chatType: z.ZodOptional<z.ZodEnum<{
86
71
  channel: "channel";
87
72
  dm: "dm";
@@ -47,23 +47,17 @@ export type TranscriptToolCallIdMode = z.infer<typeof TranscriptToolCallIdModeSc
47
47
  * Strict object: unknown fields are rejected.
48
48
  */
49
49
  export declare const ProviderCapabilitiesSchema: z.ZodObject<{
50
- /** Provider family for SDK dispatch. Default: "default". */
51
50
  providerFamily: z.ZodDefault<z.ZodEnum<{
52
51
  default: "default";
53
52
  openai: "openai";
54
53
  anthropic: "anthropic";
55
54
  google: "google";
56
55
  }>>;
57
- /** Model name substrings that should have thinking blocks dropped from context.
58
- * Empty array = no special handling. */
59
56
  dropThinkingBlockModelHints: z.ZodDefault<z.ZodArray<z.ZodString>>;
60
- /** How tool_call_id values are formatted in transcripts. Default: "default". */
61
57
  transcriptToolCallIdMode: z.ZodDefault<z.ZodEnum<{
62
58
  default: "default";
63
59
  strict9: "strict9";
64
60
  }>>;
65
- /** Model name substrings that should use strict9 tool_call_id mode.
66
- * Empty array = no special handling. */
67
61
  transcriptToolCallIdModelHints: z.ZodDefault<z.ZodArray<z.ZodString>>;
68
62
  }, z.core.$strict>;
69
63
  export type ProviderCapabilities = z.infer<typeof ProviderCapabilitiesSchema>;
@@ -11,13 +11,9 @@
11
11
  import type { Result } from "@comis/shared";
12
12
  import { z } from "zod";
13
13
  export declare const RichButtonSchema: z.ZodObject<{
14
- /** Button label text */
15
14
  text: z.ZodString;
16
- /** Callback identifier for interactive buttons (64-byte Telegram limit) */
17
15
  callback_data: z.ZodOptional<z.ZodString>;
18
- /** URL for link buttons (mutually exclusive with callback_data) */
19
16
  url: z.ZodOptional<z.ZodString>;
20
- /** Visual style hint for platform rendering */
21
17
  style: z.ZodOptional<z.ZodDefault<z.ZodEnum<{
22
18
  link: "link";
23
19
  primary: "primary";
@@ -32,29 +28,19 @@ export declare const RichCardFieldSchema: z.ZodObject<{
32
28
  inline: z.ZodOptional<z.ZodBoolean>;
33
29
  }, z.core.$strict>;
34
30
  export declare const RichCardSchema: z.ZodObject<{
35
- /** Card title */
36
31
  title: z.ZodOptional<z.ZodString>;
37
- /** Card description/body text */
38
32
  description: z.ZodOptional<z.ZodString>;
39
- /** Image URL for card thumbnail/image */
40
33
  image_url: z.ZodOptional<z.ZodString>;
41
- /** Color as integer (e.g. 0x0099FF) for embed accent */
42
34
  color: z.ZodOptional<z.ZodNumber>;
43
- /** Structured key-value fields */
44
35
  fields: z.ZodOptional<z.ZodArray<z.ZodObject<{
45
36
  name: z.ZodString;
46
37
  value: z.ZodString;
47
38
  inline: z.ZodOptional<z.ZodBoolean>;
48
39
  }, z.core.$strict>>>;
49
- /** Card-level button rows (for Discord embed + button combos) */
50
40
  buttons: z.ZodOptional<z.ZodArray<z.ZodArray<z.ZodObject<{
51
- /** Button label text */
52
41
  text: z.ZodString;
53
- /** Callback identifier for interactive buttons (64-byte Telegram limit) */
54
42
  callback_data: z.ZodOptional<z.ZodString>;
55
- /** URL for link buttons (mutually exclusive with callback_data) */
56
43
  url: z.ZodOptional<z.ZodString>;
57
- /** Visual style hint for platform rendering */
58
44
  style: z.ZodOptional<z.ZodDefault<z.ZodEnum<{
59
45
  link: "link";
60
46
  primary: "primary";
@@ -10,53 +10,31 @@ import { z } from "zod";
10
10
  * `config/schema-security.ts`.
11
11
  */
12
12
  export declare const SubagentContextConfigSchema: z.ZodObject<{
13
- /** Maximum spawn depth (parent -> child -> grandchild). 1 = no nesting. */
14
13
  maxSpawnDepth: z.ZodDefault<z.ZodNumber>;
15
- /** Maximum concurrent active children per parent agent */
16
14
  maxChildrenPerAgent: z.ZodDefault<z.ZodNumber>;
17
- /** Token threshold: below = passthrough (L1), above = LLM condensation (L2) */
18
15
  maxResultTokens: z.ZodDefault<z.ZodNumber>;
19
- /** Result file retention in ms (auto-sweep after this) */
20
16
  resultRetentionMs: z.ZodDefault<z.ZodNumber>;
21
- /** Condensation strategy: "auto" selects level based on token count */
22
17
  condensationStrategy: z.ZodDefault<z.ZodEnum<{
23
18
  never: "never";
24
19
  always: "always";
25
20
  auto: "auto";
26
21
  }>>;
27
- /** Parent history mode: "none" = no parent context, "summary" = LLM summary */
28
22
  includeParentHistory: z.ZodDefault<z.ZodEnum<{
29
23
  none: "none";
30
24
  summary: "summary";
31
25
  }>>;
32
- /** Inject objective statement that survives compaction */
33
26
  objectiveReinforcement: z.ZodDefault<z.ZodBoolean>;
34
- /** Pass artifact references to subagent (file paths, not inline content) */
35
27
  artifactPassthrough: z.ZodDefault<z.ZodBoolean>;
36
- /** Context fill ratio that triggers auto-compaction (0-1) */
37
28
  autoCompactThreshold: z.ZodDefault<z.ZodNumber>;
38
- /** Preserve error details in condensed results */
39
29
  errorPreservation: z.ZodDefault<z.ZodBoolean>;
40
- /** Apply narrative casting tags to subagent results */
41
30
  narrativeCasting: z.ZodDefault<z.ZodBoolean>;
42
- /** Tag prefix for narrative casting of subagent results */
43
31
  resultTagPrefix: z.ZodDefault<z.ZodString>;
44
- /** Maximum tokens for parent context summary (when includeParentHistory = "summary") */
45
32
  parentSummaryMaxTokens: z.ZodDefault<z.ZodNumber>;
46
- /** Maximum queued spawns per caller before true backpressure rejection. 0 disables queuing (preserves old throw behavior). */
47
33
  maxQueuedPerAgent: z.ZodDefault<z.ZodNumber>;
48
- /** How long a queued spawn waits before failing with timeout (ms). */
49
34
  queueTimeoutMs: z.ZodDefault<z.ZodNumber>;
50
- /** Maximum wall-clock time for a single sub-agent run before watchdog force-fail (ms). */
51
35
  maxRunTimeoutMs: z.ZodDefault<z.ZodNumber>;
52
- /** Per-step timeout used to compute dynamic watchdog: min(max_steps * perStepTimeoutMs, maxRunTimeoutMs). */
53
36
  perStepTimeoutMs: z.ZodDefault<z.ZodNumber>;
54
- /** Health-tick stuck kill threshold for graph sub-agents (ms). Graph spawns do multi-step
55
- * analytical work that routinely exceeds the regular threshold. Falls back to
56
- * stuckKillThresholdMs if unset. Set to 0 to disable for graph runs. */
57
37
  graphStuckKillThresholdMs: z.ZodDefault<z.ZodNumber>;
58
- /** Health-tick stuck kill threshold for regular (non-graph) sub-agents (ms).
59
- * Set to 0 to disable. */
60
38
  stuckKillThresholdMs: z.ZodDefault<z.ZodNumber>;
61
39
  }, z.core.$strict>;
62
40
  export type SubagentContextConfig = z.infer<typeof SubagentContextConfigSchema>;
@@ -8,21 +8,13 @@ import { z } from "zod";
8
8
  * Validated at runtime because the result is parsed from LLM output.
9
9
  */
10
10
  export declare const SubagentResultSchema: z.ZodObject<{
11
- /** Whether the subagent completed its task successfully */
12
11
  taskComplete: z.ZodBoolean;
13
- /** Human-readable summary of what was accomplished */
14
12
  summary: z.ZodString;
15
- /** Key conclusions or findings */
16
13
  conclusions: z.ZodArray<z.ZodString>;
17
- /** File paths created or modified */
18
14
  filePaths: z.ZodOptional<z.ZodArray<z.ZodString>>;
19
- /** Next steps the parent should consider */
20
15
  actionableItems: z.ZodOptional<z.ZodArray<z.ZodString>>;
21
- /** Error descriptions encountered */
22
16
  errors: z.ZodOptional<z.ZodArray<z.ZodString>>;
23
- /** Arbitrary structured data for parent consumption */
24
17
  keyData: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
25
- /** Confidence score (0-1) for the conclusions */
26
18
  confidence: z.ZodOptional<z.ZodNumber>;
27
19
  }, z.core.$strict>;
28
20
  export type SubagentResult = z.infer<typeof SubagentResultSchema>;
@@ -118,6 +118,37 @@ export interface AgentEvents {
118
118
  }>;
119
119
  timestamp: number;
120
120
  };
121
+ /**
122
+ * v1.1 capability layer -- install detour detected by exec/process tool.
123
+ * Emission lives in the skills package; this is the type-only declaration.
124
+ *
125
+ * Privacy invariants:
126
+ * - NO raw command text, shell fragments, URLs, VCS specs, local paths,
127
+ * registry credentials, stdout, or stderr.
128
+ * - `commandDigest` is a stable, non-reversible hash (SHA-256).
129
+ * - `packages[].normalizedName` is a registry-safe identifier only.
130
+ */
131
+ "tool:install_detour_detected": {
132
+ readonly agentId?: string;
133
+ readonly sessionKey?: string;
134
+ readonly traceId?: string;
135
+ readonly packageManager: "pip" | "npm" | "pnpm" | "yarn";
136
+ /** Stable, non-reversible hash of normalized command shape. NEVER raw command. */
137
+ readonly commandDigest: string;
138
+ readonly packages: ReadonlyArray<{
139
+ readonly normalizedName: string;
140
+ readonly ecosystem: "python" | "node";
141
+ }>;
142
+ readonly overlaps: ReadonlyArray<{
143
+ readonly packageName: string;
144
+ readonly sourceType: "mcp" | "skill";
145
+ readonly sourceName: string;
146
+ readonly reason: "direct-server-name" | "mcp-operator-alias" | "skill-comis-alias" | "skill-operator-alias";
147
+ }>;
148
+ readonly mode: "observe" | "advise" | "soft-stop";
149
+ readonly action: "observed" | "hinted" | "soft_stopped" | "override_requested" | "overridden" | "override_denied";
150
+ readonly timestamp: number;
151
+ };
121
152
  /** Audit log event for compliance and security monitoring */
122
153
  "audit:event": {
123
154
  timestamp: number;
@@ -433,6 +433,11 @@ export interface InfraEvents {
433
433
  agentId: string;
434
434
  sessionKey: string;
435
435
  hopCount: number;
436
+ /** traceId from task.origin for operator log continuity.
437
+ * null when no trace was active at promote() time. Carried through so
438
+ * subscribers (and operator log lines) preserve the originating trace
439
+ * across the background_task:completed → :reentered boundary. */
440
+ traceId: string | null;
436
441
  timestamp: number;
437
442
  };
438
443
  /** Background task cancelled by user or system */
@@ -1,2 +1,2 @@
1
- export { AppConfigSchema, AgentConfigSchema, AgentsMapSchema, BudgetConfigSchema, CircuitBreakerConfigSchema, DmScopeConfigSchema, ElevatedReplyConfigSchema, ModelRoutesSchema, HeartbeatConfigSchema, HeartbeatTargetSchema, PerAgentConfigSchema, PerAgentCronConfigSchema, PerAgentHeartbeatConfigSchema, PerAgentSchedulerConfigSchema, PruningConfigSchema, RagConfigSchema, ResetPolicyOverrideSchema, RoutingBindingSchema, RoutingConfigSchema, SessionResetPolicySchema, TracingConfigSchema, ChannelConfigSchema, ChannelEntrySchema, ChannelHealthCheckSchema, MemoryConfigSchema, CompactionConfigSchema, RetentionConfigSchema, SecurityConfigSchema, PermissionConfigSchema, ActionConfirmationConfigSchema, AgentToAgentConfigSchema, SkillsConfigSchema, DaemonConfigSchema, LoggingConfigSchema, TracingDefaultsSchema, ConfigWebhookSchema, SchedulerConfigSchema, GatewayConfigSchema, GatewayTlsConfigSchema, GatewayTokenSchema, GatewayRateLimitSchema, IntegrationsConfigSchema, BraveSearchConfigSchema, McpServerEntrySchema, McpConfigSchema, TranscriptionConfigSchema, TtsConfigSchema, TtsAutoModeSchema, ElevenLabsVoiceSettingsSchema, TtsOutputFormatSchema, ImageAnalysisConfigSchema, VisionScopeRuleSchema, VisionConfigSchema, LinkUnderstandingConfigSchema, MediaConfigSchema, DOCUMENT_MIME_WHITELIST, FileExtractionConfigSchema, AutoReplyRuleSchema, AutoReplyConfigSchema, MonitoringConfigSchema, PluginsConfigSchema, PluginEntrySchema, QueueConfigSchema, QueueModeSchema, OverflowPolicySchema, PerChannelQueueConfigSchema, OverflowConfigSchema, DebounceBufferConfigSchema, FollowupConfigSchema, PriorityLaneConfigSchema, LaneAssignmentConfigSchema, StreamingConfigSchema, PerChannelStreamingConfigSchema, TypingModeSchema, ChunkModeSchema, DeliveryMirrorConfigSchema, DeliveryQueueConfigSchema, DeliveryTimingConfigSchema, DeliveryTimingModeSchema, CoalescerConfigSchema, AutoReplyEngineConfigSchema, GroupActivationModeSchema, SendPolicyConfigSchema, SendPolicyRuleSchema, SendActionSchema, EnvelopeConfigSchema, RetryConfigSchema, WebhooksConfigSchema, WebhookMappingConfigSchema, WebhookMappingMatchSchema, AgentSecretsConfigSchema, SecretsConfigSchema, DocumentationConfigSchema, DocumentationLinkSchema, ImageGenerationConfigSchema, NotificationConfigSchema, VerbosityConfigSchema, VerbosityLevelSchema, VerbosityOverrideSchema, ContextEngineConfigSchema, BackgroundTasksConfigSchema, MemoryReviewConfigSchema, ProviderEntrySchema, ProvidersConfigSchema, UserModelSchema, ModelCostSchema, OperationModelEntrySchema, OperationModelsSchema, OAuthConfigSchema, substituteEnvVars, warnSuspiciousEnvValues, findUnresolvedEnvRefs, formatMissingEnvRefError, loadConfigFile, validateConfig, deepMerge, mergeLayered, loadLayered, IMMUTABLE_CONFIG_PREFIXES, MUTABLE_CONFIG_OVERRIDES, isImmutableConfigPath, matchesOverridePattern, getMutableOverridesForSection, MANAGED_SECTIONS, getManagedSectionRedirect, formatRedirectHint, getConfigSchema, getConfigSections, getFieldMetadata, validatePartial, createConfigGitManager, checkApprovalsConfig, } from "../config/index.js";
2
- export type { AppConfig, AgentConfig, BudgetConfig, CircuitBreakerConfig, DmScopeConfig, ElevatedReplyConfig, ModelRoutes, PruningConfig, HeartbeatConfig, HeartbeatTarget, PerAgentConfig, PerAgentCronConfig, PerAgentHeartbeatConfig, PerAgentSchedulerConfig, RagConfig, ResetPolicyOverride, RoutingBinding, RoutingConfig, SessionResetPolicyConfig, TracingConfig, ChannelConfig, ChannelEntry, ChannelHealthCheckConfig, AckReactionConfig, MemoryConfig, CompactionConfig, RetentionConfig, SecurityConfig, PermissionConfig, ActionConfirmationConfig, AgentToAgentConfig, SkillsConfig, DaemonConfig, LoggingConfig, TracingDefaults, ConfigWebhook, SchedulerConfig, GatewayConfig, GatewayTlsConfig, GatewayToken, GatewayRateLimit, IntegrationsConfig, BraveSearchConfig, McpServerEntry, McpConfig, TranscriptionConfig, TtsConfig, TtsAutoMode, ElevenLabsVoiceSettings, TtsOutputFormat, ImageAnalysisConfig, VisionScopeRule, VisionConfig, LinkUnderstandingConfig, MediaConfig, FileExtractionConfig, AutoReplyRule, AutoReplyConfig, MonitoringConfig, DiskMonitorConfig, ResourceMonitorConfig, SystemdMonitorConfig, SecurityUpdateMonitorConfig, GitMonitorConfig, PluginsConfig, PluginEntry, QueueConfig, PerChannelQueueConfig, QueueMode, OverflowPolicy, OverflowConfig, DebounceBufferConfig, FollowupConfig, PriorityLaneConfig, LaneAssignmentConfig, StreamingConfig, PerChannelStreamingConfig, TypingMode, ChunkMode, DeliveryMirrorConfig, DeliveryQueueConfig, DeliveryTimingConfig, DeliveryTimingMode, CoalescerConfig, AutoReplyEngineConfig, GroupActivationMode, SendPolicyConfig, SendPolicyRule, SendAction, EnvelopeConfig, RetryConfig, WebhooksConfig, WebhookMappingConfig, AgentSecretsConfig, SecretsConfig, ConfigError, ConfigErrorCode, FieldMetadata, PartialValidationResult, ConfigGitManager, GitCommitMetadata, HistoryEntry, GitManagerDeps, ExecGitFn, EnvValueWarning, UnresolvedEnvRef, LifecycleReactionsConfig, LifecycleReactionsTimingConfig, SenderTrustDisplayConfig, DocumentationConfig, DocumentationLink, ImageGenerationConfig, NotificationConfig, VerbosityConfig, VerbosityLevel, VerbosityOverride, ContextEngineConfig, BackgroundTasksConfig, MemoryReviewConfig, ProviderEntry, ProvidersConfig, UserModel, ModelCost, OperationModelEntry, OperationModels, ModelOperationType, OAuthConfig, } from "../config/index.js";
1
+ export { AppConfigSchema, AgentConfigSchema, AgentsMapSchema, BudgetConfigSchema, CircuitBreakerConfigSchema, DmScopeConfigSchema, ElevatedReplyConfigSchema, ModelRoutesSchema, HeartbeatConfigSchema, HeartbeatTargetSchema, PerAgentConfigSchema, PerAgentCronConfigSchema, PerAgentHeartbeatConfigSchema, PerAgentSchedulerConfigSchema, PruningConfigSchema, RagConfigSchema, ResetPolicyOverrideSchema, RoutingBindingSchema, RoutingConfigSchema, SessionResetPolicySchema, TracingConfigSchema, ChannelConfigSchema, ChannelEntrySchema, ChannelHealthCheckSchema, MemoryConfigSchema, CompactionConfigSchema, RetentionConfigSchema, SecurityConfigSchema, PermissionConfigSchema, ActionConfirmationConfigSchema, AgentToAgentConfigSchema, SkillsConfigSchema, DaemonConfigSchema, LoggingConfigSchema, TracingDefaultsSchema, ConfigWebhookSchema, SchedulerConfigSchema, GatewayConfigSchema, GatewayTlsConfigSchema, GatewayTokenSchema, GatewayRateLimitSchema, IntegrationsConfigSchema, BraveSearchConfigSchema, McpServerEntrySchema, McpConfigSchema, TranscriptionConfigSchema, TtsConfigSchema, TtsAutoModeSchema, ElevenLabsVoiceSettingsSchema, TtsOutputFormatSchema, ImageAnalysisConfigSchema, VisionScopeRuleSchema, VisionConfigSchema, LinkUnderstandingConfigSchema, MediaConfigSchema, DOCUMENT_MIME_WHITELIST, FileExtractionConfigSchema, AutoReplyRuleSchema, AutoReplyConfigSchema, MonitoringConfigSchema, PluginsConfigSchema, PluginEntrySchema, QueueConfigSchema, QueueModeSchema, OverflowPolicySchema, PerChannelQueueConfigSchema, OverflowConfigSchema, DebounceBufferConfigSchema, FollowupConfigSchema, PriorityLaneConfigSchema, LaneAssignmentConfigSchema, StreamingConfigSchema, PerChannelStreamingConfigSchema, TypingModeSchema, ChunkModeSchema, DeliveryMirrorConfigSchema, DeliveryQueueConfigSchema, DeliveryTimingConfigSchema, DeliveryTimingModeSchema, CoalescerConfigSchema, AutoReplyEngineConfigSchema, GroupActivationModeSchema, SendPolicyConfigSchema, SendPolicyRuleSchema, SendActionSchema, EnvelopeConfigSchema, RetryConfigSchema, WebhooksConfigSchema, WebhookMappingConfigSchema, WebhookMappingMatchSchema, AgentSecretsConfigSchema, SecretsConfigSchema, DocumentationConfigSchema, DocumentationLinkSchema, ImageGenerationConfigSchema, NotificationConfigSchema, VerbosityConfigSchema, VerbosityLevelSchema, VerbosityOverrideSchema, ContextEngineConfigSchema, BackgroundTasksConfigSchema, OutputRetentionConfigSchema, MemoryReviewConfigSchema, ProviderEntrySchema, ProvidersConfigSchema, UserModelSchema, ModelCostSchema, OperationModelEntrySchema, OperationModelsSchema, OAuthConfigSchema, substituteEnvVars, warnSuspiciousEnvValues, findUnresolvedEnvRefs, formatMissingEnvRefError, loadConfigFile, validateConfig, deepMerge, mergeLayered, loadLayered, IMMUTABLE_CONFIG_PREFIXES, MUTABLE_CONFIG_OVERRIDES, isImmutableConfigPath, matchesOverridePattern, getMutableOverridesForSection, MANAGED_SECTIONS, getManagedSectionRedirect, formatRedirectHint, getConfigSchema, getConfigSections, getFieldMetadata, validatePartial, createConfigGitManager, ToolingConfigSchema, DEFAULT_CLUSTER_CONFIG, DEFAULT_BUILTIN_ASSIGNMENTS, checkApprovalsConfig, } from "../config/index.js";
2
+ export type { AppConfig, AgentConfig, BudgetConfig, CircuitBreakerConfig, DmScopeConfig, ElevatedReplyConfig, ModelRoutes, PruningConfig, HeartbeatConfig, HeartbeatTarget, PerAgentConfig, PerAgentCronConfig, PerAgentHeartbeatConfig, PerAgentSchedulerConfig, RagConfig, ResetPolicyOverride, RoutingBinding, RoutingConfig, SessionResetPolicyConfig, TracingConfig, ChannelConfig, ChannelEntry, ChannelHealthCheckConfig, AckReactionConfig, MemoryConfig, CompactionConfig, RetentionConfig, SecurityConfig, PermissionConfig, ActionConfirmationConfig, AgentToAgentConfig, SkillsConfig, DaemonConfig, LoggingConfig, TracingDefaults, ConfigWebhook, SchedulerConfig, GatewayConfig, GatewayTlsConfig, GatewayToken, GatewayRateLimit, IntegrationsConfig, BraveSearchConfig, McpServerEntry, McpConfig, TranscriptionConfig, TtsConfig, TtsAutoMode, ElevenLabsVoiceSettings, TtsOutputFormat, ImageAnalysisConfig, VisionScopeRule, VisionConfig, LinkUnderstandingConfig, MediaConfig, FileExtractionConfig, AutoReplyRule, AutoReplyConfig, MonitoringConfig, DiskMonitorConfig, ResourceMonitorConfig, SystemdMonitorConfig, SecurityUpdateMonitorConfig, GitMonitorConfig, PluginsConfig, PluginEntry, QueueConfig, PerChannelQueueConfig, QueueMode, OverflowPolicy, OverflowConfig, DebounceBufferConfig, FollowupConfig, PriorityLaneConfig, LaneAssignmentConfig, StreamingConfig, PerChannelStreamingConfig, TypingMode, ChunkMode, DeliveryMirrorConfig, DeliveryQueueConfig, DeliveryTimingConfig, DeliveryTimingMode, CoalescerConfig, AutoReplyEngineConfig, GroupActivationMode, SendPolicyConfig, SendPolicyRule, SendAction, EnvelopeConfig, RetryConfig, WebhooksConfig, WebhookMappingConfig, AgentSecretsConfig, SecretsConfig, ConfigError, ConfigErrorCode, FieldMetadata, PartialValidationResult, ConfigGitManager, GitCommitMetadata, HistoryEntry, GitManagerDeps, ExecGitFn, EnvValueWarning, UnresolvedEnvRef, LifecycleReactionsConfig, LifecycleReactionsTimingConfig, SenderTrustDisplayConfig, DocumentationConfig, DocumentationLink, ImageGenerationConfig, NotificationConfig, VerbosityConfig, VerbosityLevel, VerbosityOverride, ContextEngineConfig, BackgroundTasksConfig, OutputRetentionConfig, RetentionClass, MemoryReviewConfig, ProviderEntry, ProvidersConfig, UserModel, ModelCost, OperationModelEntry, OperationModels, ModelOperationType, ToolingConfig, OAuthConfig, } from "../config/index.js";
@@ -1,3 +1,5 @@
1
1
  // SPDX-License-Identifier: Apache-2.0
2
2
  // @comis/core exports — Config (layered configuration with Zod validation)
3
- export { AppConfigSchema, AgentConfigSchema, AgentsMapSchema, BudgetConfigSchema, CircuitBreakerConfigSchema, DmScopeConfigSchema, ElevatedReplyConfigSchema, ModelRoutesSchema, HeartbeatConfigSchema, HeartbeatTargetSchema, PerAgentConfigSchema, PerAgentCronConfigSchema, PerAgentHeartbeatConfigSchema, PerAgentSchedulerConfigSchema, PruningConfigSchema, RagConfigSchema, ResetPolicyOverrideSchema, RoutingBindingSchema, RoutingConfigSchema, SessionResetPolicySchema, TracingConfigSchema, ChannelConfigSchema, ChannelEntrySchema, ChannelHealthCheckSchema, MemoryConfigSchema, CompactionConfigSchema, RetentionConfigSchema, SecurityConfigSchema, PermissionConfigSchema, ActionConfirmationConfigSchema, AgentToAgentConfigSchema, SkillsConfigSchema, DaemonConfigSchema, LoggingConfigSchema, TracingDefaultsSchema, ConfigWebhookSchema, SchedulerConfigSchema, GatewayConfigSchema, GatewayTlsConfigSchema, GatewayTokenSchema, GatewayRateLimitSchema, IntegrationsConfigSchema, BraveSearchConfigSchema, McpServerEntrySchema, McpConfigSchema, TranscriptionConfigSchema, TtsConfigSchema, TtsAutoModeSchema, ElevenLabsVoiceSettingsSchema, TtsOutputFormatSchema, ImageAnalysisConfigSchema, VisionScopeRuleSchema, VisionConfigSchema, LinkUnderstandingConfigSchema, MediaConfigSchema, DOCUMENT_MIME_WHITELIST, FileExtractionConfigSchema, AutoReplyRuleSchema, AutoReplyConfigSchema, MonitoringConfigSchema, PluginsConfigSchema, PluginEntrySchema, QueueConfigSchema, QueueModeSchema, OverflowPolicySchema, PerChannelQueueConfigSchema, OverflowConfigSchema, DebounceBufferConfigSchema, FollowupConfigSchema, PriorityLaneConfigSchema, LaneAssignmentConfigSchema, StreamingConfigSchema, PerChannelStreamingConfigSchema, TypingModeSchema, ChunkModeSchema, DeliveryMirrorConfigSchema, DeliveryQueueConfigSchema, DeliveryTimingConfigSchema, DeliveryTimingModeSchema, CoalescerConfigSchema, AutoReplyEngineConfigSchema, GroupActivationModeSchema, SendPolicyConfigSchema, SendPolicyRuleSchema, SendActionSchema, EnvelopeConfigSchema, RetryConfigSchema, WebhooksConfigSchema, WebhookMappingConfigSchema, WebhookMappingMatchSchema, AgentSecretsConfigSchema, SecretsConfigSchema, DocumentationConfigSchema, DocumentationLinkSchema, ImageGenerationConfigSchema, NotificationConfigSchema, VerbosityConfigSchema, VerbosityLevelSchema, VerbosityOverrideSchema, ContextEngineConfigSchema, BackgroundTasksConfigSchema, MemoryReviewConfigSchema, ProviderEntrySchema, ProvidersConfigSchema, UserModelSchema, ModelCostSchema, OperationModelEntrySchema, OperationModelsSchema, OAuthConfigSchema, substituteEnvVars, warnSuspiciousEnvValues, findUnresolvedEnvRefs, formatMissingEnvRefError, loadConfigFile, validateConfig, deepMerge, mergeLayered, loadLayered, IMMUTABLE_CONFIG_PREFIXES, MUTABLE_CONFIG_OVERRIDES, isImmutableConfigPath, matchesOverridePattern, getMutableOverridesForSection, MANAGED_SECTIONS, getManagedSectionRedirect, formatRedirectHint, getConfigSchema, getConfigSections, getFieldMetadata, validatePartial, createConfigGitManager, checkApprovalsConfig, } from "../config/index.js";
3
+ export { AppConfigSchema, AgentConfigSchema, AgentsMapSchema, BudgetConfigSchema, CircuitBreakerConfigSchema, DmScopeConfigSchema, ElevatedReplyConfigSchema, ModelRoutesSchema, HeartbeatConfigSchema, HeartbeatTargetSchema, PerAgentConfigSchema, PerAgentCronConfigSchema, PerAgentHeartbeatConfigSchema, PerAgentSchedulerConfigSchema, PruningConfigSchema, RagConfigSchema, ResetPolicyOverrideSchema, RoutingBindingSchema, RoutingConfigSchema, SessionResetPolicySchema, TracingConfigSchema, ChannelConfigSchema, ChannelEntrySchema, ChannelHealthCheckSchema, MemoryConfigSchema, CompactionConfigSchema, RetentionConfigSchema, SecurityConfigSchema, PermissionConfigSchema, ActionConfirmationConfigSchema, AgentToAgentConfigSchema, SkillsConfigSchema, DaemonConfigSchema, LoggingConfigSchema, TracingDefaultsSchema, ConfigWebhookSchema, SchedulerConfigSchema, GatewayConfigSchema, GatewayTlsConfigSchema, GatewayTokenSchema, GatewayRateLimitSchema, IntegrationsConfigSchema, BraveSearchConfigSchema, McpServerEntrySchema, McpConfigSchema, TranscriptionConfigSchema, TtsConfigSchema, TtsAutoModeSchema, ElevenLabsVoiceSettingsSchema, TtsOutputFormatSchema, ImageAnalysisConfigSchema, VisionScopeRuleSchema, VisionConfigSchema, LinkUnderstandingConfigSchema, MediaConfigSchema, DOCUMENT_MIME_WHITELIST, FileExtractionConfigSchema, AutoReplyRuleSchema, AutoReplyConfigSchema, MonitoringConfigSchema, PluginsConfigSchema, PluginEntrySchema, QueueConfigSchema, QueueModeSchema, OverflowPolicySchema, PerChannelQueueConfigSchema, OverflowConfigSchema, DebounceBufferConfigSchema, FollowupConfigSchema, PriorityLaneConfigSchema, LaneAssignmentConfigSchema, StreamingConfigSchema, PerChannelStreamingConfigSchema, TypingModeSchema, ChunkModeSchema, DeliveryMirrorConfigSchema, DeliveryQueueConfigSchema, DeliveryTimingConfigSchema, DeliveryTimingModeSchema, CoalescerConfigSchema, AutoReplyEngineConfigSchema, GroupActivationModeSchema, SendPolicyConfigSchema, SendPolicyRuleSchema, SendActionSchema, EnvelopeConfigSchema, RetryConfigSchema, WebhooksConfigSchema, WebhookMappingConfigSchema, WebhookMappingMatchSchema, AgentSecretsConfigSchema, SecretsConfigSchema, DocumentationConfigSchema, DocumentationLinkSchema, ImageGenerationConfigSchema, NotificationConfigSchema, VerbosityConfigSchema, VerbosityLevelSchema, VerbosityOverrideSchema, ContextEngineConfigSchema, BackgroundTasksConfigSchema, OutputRetentionConfigSchema, MemoryReviewConfigSchema, ProviderEntrySchema, ProvidersConfigSchema, UserModelSchema, ModelCostSchema, OperationModelEntrySchema, OperationModelsSchema, OAuthConfigSchema, substituteEnvVars, warnSuspiciousEnvValues, findUnresolvedEnvRefs, formatMissingEnvRefError, loadConfigFile, validateConfig, deepMerge, mergeLayered, loadLayered, IMMUTABLE_CONFIG_PREFIXES, MUTABLE_CONFIG_OVERRIDES, isImmutableConfigPath, matchesOverridePattern, getMutableOverridesForSection, MANAGED_SECTIONS, getManagedSectionRedirect, formatRedirectHint, getConfigSchema, getConfigSections, getFieldMetadata, validatePartial, createConfigGitManager,
4
+ // Tooling subtree (capability layer v1.1)
5
+ ToolingConfigSchema, DEFAULT_CLUSTER_CONFIG, DEFAULT_BUILTIN_ASSIGNMENTS, checkApprovalsConfig, } from "../config/index.js";
@@ -3,4 +3,4 @@ export type { PluginRegistry, PluginRegistryOptions, HookRunner, HookRunnerOptio
3
3
  export { createApprovalGate } from "../approval/index.js";
4
4
  export type { ApprovalGate, ApprovalGateDeps } from "../approval/index.js";
5
5
  export { registerToolMetadata, getToolMetadata, getAllToolMetadata, truncateContentBlocks, } from "../tool-metadata.js";
6
- export type { ComisToolMetadata } from "../tool-metadata.js";
6
+ export type { ComisToolMetadata, ToolCapabilityMetadata } from "../tool-metadata.js";
@@ -1,2 +1,2 @@
1
- export { ChannelCapabilitySchema, createNoOpDeliveryQueue, createNoOpDeliveryMirror, validateProfileId, PROFILE_ID_RE, } from "../ports/index.js";
2
- export type { ChannelPort, MessageHandler, SendMessageOptions, FetchMessagesOptions, FetchedMessage, AttachmentPayload, ChannelPluginPort, ChannelCapability, ChannelStatus, MemoryPort, MemorySearchOptions, MemorySearchResult, MemoryUpdateFields, SkillPort, SkillPermissions, SkillInput, SkillOutput, SkillManifest, EmbeddingPort, TranscriptionPort, TranscriptionOptions, TranscriptionResult, TTSPort, TTSOptions, TTSResult, ImageAnalysisPort, ImageAnalysisOptions, VisionRequest, VideoRequest, VisionResult, VisionProvider, ResolvedMedia, MediaResolverPort, FileClassification, FileExtractionErrorKind, FileExtractionError, FileExtractionInput, FileExtractionResult, FileExtractionPort, HookName, ModifyingHookName, VoidHookName, HookHandlerMap, HookBeforeAgentStartEvent, HookBeforeAgentStartContext, HookBeforeAgentStartResult, HookAgentEndEvent, HookAgentEndContext, HookBeforeToolCallEvent, HookBeforeToolCallContext, HookBeforeToolCallResult, HookAfterToolCallEvent, HookAfterToolCallContext, HookToolResultPersistEvent, HookToolResultPersistContext, HookToolResultPersistResult, HookBeforeCompactionEvent, HookBeforeCompactionContext, HookBeforeCompactionResult, HookAfterCompactionEvent, HookAfterCompactionContext, HookSessionStartEvent, HookSessionStartContext, HookSessionEndEvent, HookSessionEndContext, HookGatewayStartEvent, HookGatewayStartContext, HookGatewayStopEvent, HookGatewayStopContext, PluginPort, PluginRegistryApi, RegisteredHook, PluginToolDefinition, PluginHttpRoute, DeviceIdentity, DeviceIdentityPort, PairingRequest, PairedDevice, OutputGuardPort, OutputGuardFinding, OutputGuardResult, SecretStorePort, SecretMetadata, CredentialMappingPort, OAuthCredentialStorePort, OAuthProfile, DeliveryQueuePort, DeliveryQueueEntry, DeliveryQueueEnqueueInput, DeliveryQueueStatusCounts, DeliveryMirrorPort, DeliveryMirrorEntry, DeliveryMirrorRecordInput, Provider, ImageGenInput, ImageGenOutput, ImageGenerationPort, } from "../ports/index.js";
1
+ export { ChannelCapabilitySchema, createNoOpDeliveryQueue, createNoOpDeliveryMirror, createNoOpCapabilityPort, validateProfileId, PROFILE_ID_RE, } from "../ports/index.js";
2
+ export type { ChannelPort, MessageHandler, SendMessageOptions, FetchMessagesOptions, FetchedMessage, AttachmentPayload, ChannelPluginPort, ChannelCapability, ChannelStatus, MemoryPort, MemorySearchOptions, MemorySearchResult, MemoryUpdateFields, SkillPort, SkillPermissions, SkillInput, SkillOutput, SkillManifest, EmbeddingPort, TranscriptionPort, TranscriptionOptions, TranscriptionResult, TTSPort, TTSOptions, TTSResult, ImageAnalysisPort, ImageAnalysisOptions, VisionRequest, VideoRequest, VisionResult, VisionProvider, ResolvedMedia, MediaResolverPort, FileClassification, FileExtractionErrorKind, FileExtractionError, FileExtractionInput, FileExtractionResult, FileExtractionPort, HookName, ModifyingHookName, VoidHookName, HookHandlerMap, HookBeforeAgentStartEvent, HookBeforeAgentStartContext, HookBeforeAgentStartResult, HookAgentEndEvent, HookAgentEndContext, HookBeforeToolCallEvent, HookBeforeToolCallContext, HookBeforeToolCallResult, HookAfterToolCallEvent, HookAfterToolCallContext, HookToolResultPersistEvent, HookToolResultPersistContext, HookToolResultPersistResult, HookBeforeCompactionEvent, HookBeforeCompactionContext, HookBeforeCompactionResult, HookAfterCompactionEvent, HookAfterCompactionContext, HookSessionStartEvent, HookSessionStartContext, HookSessionEndEvent, HookSessionEndContext, HookGatewayStartEvent, HookGatewayStartContext, HookGatewayStopEvent, HookGatewayStopContext, PluginPort, PluginRegistryApi, RegisteredHook, PluginToolDefinition, PluginHttpRoute, DeviceIdentity, DeviceIdentityPort, PairingRequest, PairedDevice, OutputGuardPort, OutputGuardFinding, OutputGuardResult, SecretStorePort, SecretMetadata, CredentialMappingPort, OAuthCredentialStorePort, OAuthProfile, DeliveryQueuePort, DeliveryQueueEntry, DeliveryQueueEnqueueInput, DeliveryQueueStatusCounts, DeliveryMirrorPort, DeliveryMirrorEntry, DeliveryMirrorRecordInput, Provider, ImageGenInput, ImageGenOutput, ImageGenerationPort, ToolCapabilityPort, PromptSkillCapability, CapabilitySourceRef, ClusterConfig, McpServerHint, SkillHint, } from "../ports/index.js";
@@ -1,3 +1,3 @@
1
1
  // SPDX-License-Identifier: Apache-2.0
2
2
  // @comis/core exports — Port interfaces (hexagonal architecture boundaries)
3
- export { ChannelCapabilitySchema, createNoOpDeliveryQueue, createNoOpDeliveryMirror, validateProfileId, PROFILE_ID_RE, } from "../ports/index.js";
3
+ export { ChannelCapabilitySchema, createNoOpDeliveryQueue, createNoOpDeliveryMirror, createNoOpCapabilityPort, validateProfileId, PROFILE_ID_RE, } from "../ports/index.js";
@@ -2,7 +2,6 @@ import { z } from "zod";
2
2
  import type { PluginPort } from "./plugin.js";
3
3
  import type { ChannelPort } from "./channel.js";
4
4
  export declare const ChannelCapabilitySchema: z.ZodObject<{
5
- /** Chat types this channel supports */
6
5
  chatTypes: z.ZodArray<z.ZodEnum<{
7
6
  channel: "channel";
8
7
  dm: "dm";
@@ -10,7 +9,6 @@ export declare const ChannelCapabilitySchema: z.ZodObject<{
10
9
  thread: "thread";
11
10
  forum: "forum";
12
11
  }>>;
13
- /** Feature flags for optional capabilities */
14
12
  features: z.ZodDefault<z.ZodObject<{
15
13
  reactions: z.ZodDefault<z.ZodBoolean>;
16
14
  editMessages: z.ZodDefault<z.ZodBoolean>;
@@ -20,44 +18,33 @@ export declare const ChannelCapabilitySchema: z.ZodObject<{
20
18
  threads: z.ZodDefault<z.ZodBoolean>;
21
19
  mentions: z.ZodDefault<z.ZodBoolean>;
22
20
  formatting: z.ZodDefault<z.ZodArray<z.ZodString>>;
23
- /** Whether the channel supports interactive buttons */
24
21
  buttons: z.ZodDefault<z.ZodBoolean>;
25
- /** Whether the channel supports rich card embeds */
26
22
  cards: z.ZodDefault<z.ZodBoolean>;
27
- /** Whether the channel supports message delivery effects (spoiler, silent) */
28
23
  effects: z.ZodDefault<z.ZodBoolean>;
29
24
  }, z.core.$strict>>;
30
- /** Platform-specific message and attachment size limits */
31
25
  limits: z.ZodObject<{
32
26
  maxMessageChars: z.ZodNumber;
33
27
  maxAttachmentSizeMb: z.ZodOptional<z.ZodNumber>;
34
28
  }, z.core.$strict>;
35
- /** Streaming support configuration */
36
29
  streaming: z.ZodDefault<z.ZodObject<{
37
30
  supported: z.ZodDefault<z.ZodBoolean>;
38
31
  throttleMs: z.ZodDefault<z.ZodNumber>;
39
32
  maxChars: z.ZodOptional<z.ZodNumber>;
40
- /** Streaming delivery method: "edit" = edit message in-place, "block" = sequential messages, "none" = no streaming */
41
33
  method: z.ZodDefault<z.ZodEnum<{
42
34
  edit: "edit";
43
35
  none: "none";
44
36
  block: "block";
45
37
  }>>;
46
38
  }, z.core.$strict>>;
47
- /** Threading capability metadata (extends features.threads with detail) */
48
39
  threading: z.ZodDefault<z.ZodObject<{
49
- /** Whether threading is supported at all (mirrors features.threads for convenience) */
50
40
  supported: z.ZodDefault<z.ZodBoolean>;
51
- /** Type of threading: "native" = platform threads (Discord), "reply-chain" = thread_ts reply chains (Slack), "none" = no threading */
52
41
  threadType: z.ZodDefault<z.ZodEnum<{
53
42
  none: "none";
54
43
  native: "native";
55
44
  "reply-chain": "reply-chain";
56
45
  }>>;
57
- /** Maximum thread nesting depth (undefined = unlimited within a thread) */
58
46
  maxDepth: z.ZodOptional<z.ZodNumber>;
59
47
  }, z.core.$strict>>;
60
- /** Metadata key used for reply-to references (platform-specific) */
61
48
  replyToMetaKey: z.ZodOptional<z.ZodString>;
62
49
  }, z.core.$strict>;
63
50
  /** Inferred type from ChannelCapabilitySchema */
@@ -23,3 +23,5 @@ export type { DeliveryQueuePort, DeliveryQueueEntry, DeliveryQueueEnqueueInput,
23
23
  export { createNoOpDeliveryQueue } from "./delivery-queue.js";
24
24
  export type { DeliveryMirrorPort, DeliveryMirrorEntry, DeliveryMirrorRecordInput, } from "./delivery-mirror.js";
25
25
  export { createNoOpDeliveryMirror } from "./delivery-mirror.js";
26
+ export type { ToolCapabilityPort, PromptSkillCapability, CapabilitySourceRef, ClusterConfig, McpServerHint, SkillHint, } from "./tool-capability.js";
27
+ export { createNoOpCapabilityPort } from "./no-op-tool-capability.js";
@@ -4,3 +4,7 @@ export { ChannelCapabilitySchema } from "./channel-plugin.js";
4
4
  export { validateProfileId, PROFILE_ID_RE } from "./oauth-credential-store.js";
5
5
  export { createNoOpDeliveryQueue } from "./delivery-queue.js";
6
6
  export { createNoOpDeliveryMirror } from "./delivery-mirror.js";
7
+ export { createNoOpCapabilityPort } from "./no-op-tool-capability.js";
8
+ // NOTE: the test-only stub factory in `__test-helpers/` is intentionally NOT
9
+ // re-exported here. It must NEVER appear on this barrel (the architecture-grep
10
+ // test enforces this).
@@ -0,0 +1,30 @@
1
+ /**
2
+ * Production no-op factory for ToolCapabilityPort.
3
+ *
4
+ * Returns an empty-defaults adapter that is safe to inject from any production
5
+ * code path. Used as the production no-op until the live daemon-side adapter
6
+ * is wired.
7
+ *
8
+ * With the no-op port:
9
+ * - The capability-index renderer sees no clusters/skills/servers -> returns
10
+ * empty text -> executor-prompt-runner.ts filters it out.
11
+ * - The install-detour parser sees no overlaps -> no events emitted, no hints,
12
+ * no soft-stop refusals.
13
+ * Both subsystems are inert but not broken.
14
+ *
15
+ * IMPORTANT -- boundary discipline:
16
+ * Test code must NOT import this. Tests use the test-only stub factory in
17
+ * `__test-helpers/` instead. The architecture-grep test in
18
+ * `packages/<pkg>/src/__tests__/architecture.test.ts` enforces this both ways.
19
+ *
20
+ * @module
21
+ */
22
+ import type { ToolCapabilityPort } from "./tool-capability.js";
23
+ /**
24
+ * Production no-op factory. Production-OK; safe to import from any production
25
+ * code path. Tests must NOT import this -- use the test-only stub factory in
26
+ * `__test-helpers/` instead.
27
+ *
28
+ * @returns A frozen ToolCapabilityPort with empty defaults for all 9 methods.
29
+ */
30
+ export declare function createNoOpCapabilityPort(): ToolCapabilityPort;
@@ -0,0 +1,47 @@
1
+ // SPDX-License-Identifier: Apache-2.0
2
+ /**
3
+ * Production no-op factory for ToolCapabilityPort.
4
+ *
5
+ * Returns an empty-defaults adapter that is safe to inject from any production
6
+ * code path. Used as the production no-op until the live daemon-side adapter
7
+ * is wired.
8
+ *
9
+ * With the no-op port:
10
+ * - The capability-index renderer sees no clusters/skills/servers -> returns
11
+ * empty text -> executor-prompt-runner.ts filters it out.
12
+ * - The install-detour parser sees no overlaps -> no events emitted, no hints,
13
+ * no soft-stop refusals.
14
+ * Both subsystems are inert but not broken.
15
+ *
16
+ * IMPORTANT -- boundary discipline:
17
+ * Test code must NOT import this. Tests use the test-only stub factory in
18
+ * `__test-helpers/` instead. The architecture-grep test in
19
+ * `packages/<pkg>/src/__tests__/architecture.test.ts` enforces this both ways.
20
+ *
21
+ * @module
22
+ */
23
+ // Module-level constants -- returned by every call so callers can rely on
24
+ // reference-stability for cheap equality checks.
25
+ const EMPTY_ALIAS_MAP = new Map();
26
+ const EMPTY_SERVERS = Object.freeze([]);
27
+ const EMPTY_SKILLS = Object.freeze([]);
28
+ /**
29
+ * Production no-op factory. Production-OK; safe to import from any production
30
+ * code path. Tests must NOT import this -- use the test-only stub factory in
31
+ * `__test-helpers/` instead.
32
+ *
33
+ * @returns A frozen ToolCapabilityPort with empty defaults for all 9 methods.
34
+ */
35
+ export function createNoOpCapabilityPort() {
36
+ return Object.freeze({
37
+ isCapabilityIndexEnabled: () => true,
38
+ getInstallDetourMode: () => "advise",
39
+ getBuiltinCluster: () => undefined,
40
+ getClusterConfig: () => undefined,
41
+ getMcpServerHint: () => undefined,
42
+ getSkillHint: () => undefined,
43
+ getPackageAliasMap: () => EMPTY_ALIAS_MAP,
44
+ getConnectedMcpServers: () => EMPTY_SERVERS,
45
+ getPromptSkillCapabilities: () => EMPTY_SKILLS,
46
+ });
47
+ }