indusagi 0.13.7 → 0.13.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 (446) hide show
  1. package/dist/agent.js +28713 -0
  2. package/dist/ai.js +19964 -0
  3. package/dist/capabilities.js +2730 -0
  4. package/dist/cli.js +9 -0
  5. package/dist/connectors-saas.js +3355 -0
  6. package/dist/index.js +18211 -0
  7. package/dist/interop.js +3247 -0
  8. package/dist/llmgateway.js +3343 -0
  9. package/dist/mcp.js +2448 -0
  10. package/dist/memory.js +0 -0
  11. package/dist/react-host/index.js +101 -0
  12. package/dist/react-host/ink.js +97 -0
  13. package/dist/react-host/jsx-runtime.js +95 -0
  14. package/dist/react-ink.js +3834 -0
  15. package/dist/runtime.js +4521 -0
  16. package/dist/sarvam-mcp.js +960 -0
  17. package/dist/shell-app.js +12435 -0
  18. package/dist/smithy.js +8133 -0
  19. package/dist/swarm.js +8918 -0
  20. package/dist/tracing.js +761 -0
  21. package/dist/tui.js +2213 -0
  22. package/dist/types/capabilities/backends/index.d.ts +10 -0
  23. package/dist/types/capabilities/backends/node-backends.d.ts +30 -0
  24. package/dist/types/capabilities/capabilities.test.d.ts +14 -0
  25. package/dist/types/capabilities/files/diff.d.ts +49 -0
  26. package/dist/types/capabilities/files/edit.d.ts +21 -0
  27. package/dist/types/capabilities/files/ls.d.ts +16 -0
  28. package/dist/types/capabilities/files/read-state-gate.d.ts +69 -0
  29. package/dist/types/capabilities/files/read-state-gate.test.d.ts +14 -0
  30. package/dist/types/capabilities/files/read.d.ts +15 -0
  31. package/dist/types/capabilities/files/write.d.ts +16 -0
  32. package/dist/types/capabilities/index.d.ts +29 -0
  33. package/dist/types/capabilities/kernel/backends.d.ts +119 -0
  34. package/dist/types/capabilities/kernel/context.d.ts +52 -0
  35. package/dist/types/capabilities/kernel/index.d.ts +24 -0
  36. package/dist/types/capabilities/kernel/output.d.ts +40 -0
  37. package/dist/types/capabilities/kernel/registry.d.ts +61 -0
  38. package/dist/types/capabilities/kernel/spec.d.ts +168 -0
  39. package/dist/types/capabilities/planning/todo.d.ts +62 -0
  40. package/dist/types/capabilities/registry.d.ts +44 -0
  41. package/dist/types/capabilities/search/find.d.ts +33 -0
  42. package/dist/types/capabilities/search/grep.d.ts +30 -0
  43. package/dist/types/capabilities/shell/bash.d.ts +18 -0
  44. package/dist/types/capabilities/shell/process.d.ts +33 -0
  45. package/dist/types/capabilities/web/webfetch.d.ts +25 -0
  46. package/dist/types/capabilities/web/websearch.d.ts +23 -0
  47. package/dist/types/connectors-saas/connectors-saas.test.d.ts +12 -0
  48. package/dist/types/connectors-saas/index.d.ts +16 -0
  49. package/dist/types/connectors-saas/saas/adapter/composio-backend.d.ts +60 -0
  50. package/dist/types/connectors-saas/saas/control/connect.d.ts +114 -0
  51. package/dist/types/connectors-saas/saas/control/tools.d.ts +67 -0
  52. package/dist/types/connectors-saas/saas/core/builder.d.ts +86 -0
  53. package/dist/types/connectors-saas/saas/core/cache.d.ts +53 -0
  54. package/dist/types/connectors-saas/saas/core/index.d.ts +14 -0
  55. package/dist/types/connectors-saas/saas/core/port.d.ts +157 -0
  56. package/dist/types/connectors-saas/saas/core/scope-planner.d.ts +74 -0
  57. package/dist/types/connectors-saas/saas/gateway.d.ts +133 -0
  58. package/dist/types/connectors-saas/saas/render/format.d.ts +54 -0
  59. package/dist/types/connectors-saas/saas/render/index.d.ts +19 -0
  60. package/dist/types/connectors-saas/saas/render/summarizers.d.ts +58 -0
  61. package/dist/types/connectors-sarvam/connect.d.ts +14 -0
  62. package/dist/types/connectors-sarvam/connectors-sarvam.test.d.ts +14 -0
  63. package/dist/types/connectors-sarvam/index.d.ts +14 -0
  64. package/dist/types/connectors-sarvam/toolbox.d.ts +19 -0
  65. package/dist/types/connectors-sarvam/types.d.ts +49 -0
  66. package/dist/types/connectors-zoho/connect.d.ts +22 -0
  67. package/dist/types/connectors-zoho/connectors-zoho.test.d.ts +10 -0
  68. package/dist/types/connectors-zoho/index.d.ts +13 -0
  69. package/dist/types/connectors-zoho/toolbox.d.ts +19 -0
  70. package/dist/types/connectors-zoho/types.d.ts +56 -0
  71. package/dist/types/facade/agent.d.ts +1 -0
  72. package/dist/types/facade/ai.d.ts +1 -0
  73. package/dist/types/facade/bot/actions/bash.d.ts +71 -0
  74. package/dist/types/facade/bot/actions/bash.test.d.ts +1 -0
  75. package/dist/types/facade/bot/actions/checkpoint.d.ts +49 -0
  76. package/dist/types/facade/bot/actions/checkpoint.test.d.ts +1 -0
  77. package/dist/types/facade/bot/actions/composio/accounts.d.ts +22 -0
  78. package/dist/types/facade/bot/actions/composio/client.d.ts +39 -0
  79. package/dist/types/facade/bot/actions/composio/connect.d.ts +19 -0
  80. package/dist/types/facade/bot/actions/composio/enable.d.ts +25 -0
  81. package/dist/types/facade/bot/actions/composio/execute.d.ts +26 -0
  82. package/dist/types/facade/bot/actions/composio/helpers.d.ts +16 -0
  83. package/dist/types/facade/bot/actions/composio/index.d.ts +9 -0
  84. package/dist/types/facade/bot/actions/composio/provider.d.ts +8 -0
  85. package/dist/types/facade/bot/actions/composio/toolkits.d.ts +22 -0
  86. package/dist/types/facade/bot/actions/composio/tools.d.ts +28 -0
  87. package/dist/types/facade/bot/actions/composio/types.d.ts +137 -0
  88. package/dist/types/facade/bot/actions/crew/activity-tracker.d.ts +65 -0
  89. package/dist/types/facade/bot/actions/crew/cleanup.d.ts +50 -0
  90. package/dist/types/facade/bot/actions/crew/fs-lock.d.ts +11 -0
  91. package/dist/types/facade/bot/actions/crew/index.d.ts +11 -0
  92. package/dist/types/facade/bot/actions/crew/mailbox.d.ts +20 -0
  93. package/dist/types/facade/bot/actions/crew/model-policy.d.ts +22 -0
  94. package/dist/types/facade/bot/actions/crew/names.d.ts +27 -0
  95. package/dist/types/facade/bot/actions/crew/protocol.d.ts +74 -0
  96. package/dist/types/facade/bot/actions/crew/task-store.d.ts +88 -0
  97. package/dist/types/facade/bot/actions/crew/team-attach-claim.d.ts +35 -0
  98. package/dist/types/facade/bot/actions/crew/team-config.d.ts +54 -0
  99. package/dist/types/facade/bot/actions/crew/worktree.d.ts +39 -0
  100. package/dist/types/facade/bot/actions/edit-diff.d.ts +66 -0
  101. package/dist/types/facade/bot/actions/edit-utils.d.ts +86 -0
  102. package/dist/types/facade/bot/actions/edit.d.ts +59 -0
  103. package/dist/types/facade/bot/actions/edit.test.d.ts +1 -0
  104. package/dist/types/facade/bot/actions/find.d.ts +27 -0
  105. package/dist/types/facade/bot/actions/find.test.d.ts +1 -0
  106. package/dist/types/facade/bot/actions/grep.d.ts +53 -0
  107. package/dist/types/facade/bot/actions/grep.test.d.ts +1 -0
  108. package/dist/types/facade/bot/actions/index.d.ts +316 -0
  109. package/dist/types/facade/bot/actions/kit/hook-runner.d.ts +12 -0
  110. package/dist/types/facade/bot/actions/kit/image-resize.d.ts +19 -0
  111. package/dist/types/facade/bot/actions/kit/mime.d.ts +1 -0
  112. package/dist/types/facade/bot/actions/kit/shell.d.ts +12 -0
  113. package/dist/types/facade/bot/actions/ls.d.ts +41 -0
  114. package/dist/types/facade/bot/actions/path-utils.d.ts +8 -0
  115. package/dist/types/facade/bot/actions/process-controller.d.ts +14 -0
  116. package/dist/types/facade/bot/actions/process-manager.d.ts +59 -0
  117. package/dist/types/facade/bot/actions/process-types.d.ts +73 -0
  118. package/dist/types/facade/bot/actions/process.d.ts +37 -0
  119. package/dist/types/facade/bot/actions/read-state.d.ts +83 -0
  120. package/dist/types/facade/bot/actions/read-state.test.d.ts +1 -0
  121. package/dist/types/facade/bot/actions/read.d.ts +43 -0
  122. package/dist/types/facade/bot/actions/read.test.d.ts +1 -0
  123. package/dist/types/facade/bot/actions/registry.d.ts +20 -0
  124. package/dist/types/facade/bot/actions/sandbox-backend.d.ts +99 -0
  125. package/dist/types/facade/bot/actions/sandbox-backend.test.d.ts +1 -0
  126. package/dist/types/facade/bot/actions/todo-store.d.ts +76 -0
  127. package/dist/types/facade/bot/actions/todo-types.d.ts +72 -0
  128. package/dist/types/facade/bot/actions/todo.d.ts +76 -0
  129. package/dist/types/facade/bot/actions/truncate.d.ts +78 -0
  130. package/dist/types/facade/bot/actions/webfetch.d.ts +35 -0
  131. package/dist/types/facade/bot/actions/websearch.d.ts +37 -0
  132. package/dist/types/facade/bot/actions/websearch.test.d.ts +1 -0
  133. package/dist/types/facade/bot/actions/write.d.ts +45 -0
  134. package/dist/types/facade/bot/agent-loop.d.ts +30 -0
  135. package/dist/types/facade/bot/agent-loop.test.d.ts +1 -0
  136. package/dist/types/facade/bot/agent.d.ts +140 -0
  137. package/dist/types/facade/bot/error-handler.d.ts +7 -0
  138. package/dist/types/facade/bot/event-bus.d.ts +8 -0
  139. package/dist/types/facade/bot/index.d.ts +7 -0
  140. package/dist/types/facade/bot/messages.d.ts +83 -0
  141. package/dist/types/facade/bot/permission-gate.test.d.ts +1 -0
  142. package/dist/types/facade/bot/proxy.d.ts +70 -0
  143. package/dist/types/facade/bot/session-manager.d.ts +409 -0
  144. package/dist/types/facade/bot/state-manager.d.ts +21 -0
  145. package/dist/types/facade/bot/telemetry.d.ts +6 -0
  146. package/dist/types/facade/bot/types.d.ts +267 -0
  147. package/dist/types/facade/mcp-core/client-pool.d.ts +105 -0
  148. package/dist/types/facade/mcp-core/client.d.ts +245 -0
  149. package/dist/types/facade/mcp-core/client.test.d.ts +18 -0
  150. package/dist/types/facade/mcp-core/config.d.ts +60 -0
  151. package/dist/types/facade/mcp-core/errors.d.ts +103 -0
  152. package/dist/types/facade/mcp-core/index.d.ts +59 -0
  153. package/dist/types/facade/mcp-core/oauth/flow.d.ts +72 -0
  154. package/dist/types/facade/mcp-core/oauth/index.d.ts +18 -0
  155. package/dist/types/facade/mcp-core/oauth/oauth.test.d.ts +8 -0
  156. package/dist/types/facade/mcp-core/oauth/provider.d.ts +51 -0
  157. package/dist/types/facade/mcp-core/oauth/token-store.d.ts +31 -0
  158. package/dist/types/facade/mcp-core/oauth/types.d.ts +96 -0
  159. package/dist/types/facade/mcp-core/schema-converter.d.ts +67 -0
  160. package/dist/types/facade/mcp-core/server.d.ts +110 -0
  161. package/dist/types/facade/mcp-core/tool-factory.d.ts +62 -0
  162. package/dist/types/facade/mcp-core/toolbox-bridge.d.ts +46 -0
  163. package/dist/types/facade/mcp-core/toolbox-bridge.test.d.ts +8 -0
  164. package/dist/types/facade/mcp-core/types.d.ts +298 -0
  165. package/dist/types/facade/mcp.d.ts +1 -0
  166. package/dist/types/facade/memory.d.ts +1 -0
  167. package/dist/types/facade/ml/adapters/amazon-bedrock.d.ts +32 -0
  168. package/dist/types/facade/ml/adapters/anthropic-retry.test.d.ts +1 -0
  169. package/dist/types/facade/ml/adapters/anthropic.d.ts +78 -0
  170. package/dist/types/facade/ml/adapters/azure-openai-responses.d.ts +14 -0
  171. package/dist/types/facade/ml/adapters/google-shared.d.ts +99 -0
  172. package/dist/types/facade/ml/adapters/google-vertex.d.ts +14 -0
  173. package/dist/types/facade/ml/adapters/google.d.ts +15 -0
  174. package/dist/types/facade/ml/adapters/kimi.d.ts +21 -0
  175. package/dist/types/facade/ml/adapters/mock.d.ts +9 -0
  176. package/dist/types/facade/ml/adapters/nvidia.d.ts +12 -0
  177. package/dist/types/facade/ml/adapters/openai-codex-responses.d.ts +8 -0
  178. package/dist/types/facade/ml/adapters/openai-completions.d.ts +24 -0
  179. package/dist/types/facade/ml/adapters/openai-responses-shared.d.ts +25 -0
  180. package/dist/types/facade/ml/adapters/openai-responses.d.ts +12 -0
  181. package/dist/types/facade/ml/adapters/openai-scaffold.d.ts +3 -0
  182. package/dist/types/facade/ml/adapters/register-builtins.d.ts +2 -0
  183. package/dist/types/facade/ml/adapters/simple-options.d.ts +39 -0
  184. package/dist/types/facade/ml/adapters/simple-options.test.d.ts +1 -0
  185. package/dist/types/facade/ml/adapters/transform-messages.d.ts +23 -0
  186. package/dist/types/facade/ml/api-registry.d.ts +49 -0
  187. package/dist/types/facade/ml/cli.d.ts +2 -0
  188. package/dist/types/facade/ml/env-api-keys.d.ts +19 -0
  189. package/dist/types/facade/ml/index.d.ts +27 -0
  190. package/dist/types/facade/ml/kit/auth/anthropic.d.ts +17 -0
  191. package/dist/types/facade/ml/kit/auth/github-copilot.d.ts +22 -0
  192. package/dist/types/facade/ml/kit/auth/index.d.ts +50 -0
  193. package/dist/types/facade/ml/kit/auth/kimi.d.ts +23 -0
  194. package/dist/types/facade/ml/kit/auth/oauth-page.d.ts +2 -0
  195. package/dist/types/facade/ml/kit/auth/openai-codex.d.ts +36 -0
  196. package/dist/types/facade/ml/kit/auth/pkce.d.ts +12 -0
  197. package/dist/types/facade/ml/kit/auth/types.d.ts +67 -0
  198. package/dist/types/facade/ml/kit/base-stream-handler.d.ts +30 -0
  199. package/dist/types/facade/ml/kit/event-stream.d.ts +63 -0
  200. package/dist/types/facade/ml/kit/index.d.ts +14 -0
  201. package/dist/types/facade/ml/kit/json-parse.d.ts +23 -0
  202. package/dist/types/facade/ml/kit/message-transform.d.ts +32 -0
  203. package/dist/types/facade/ml/kit/output-factory.d.ts +8 -0
  204. package/dist/types/facade/ml/kit/overflow.d.ts +9 -0
  205. package/dist/types/facade/ml/kit/provider-adapter.d.ts +56 -0
  206. package/dist/types/facade/ml/kit/provider-client-builder.d.ts +36 -0
  207. package/dist/types/facade/ml/kit/provider-consolidation.d.ts +3 -0
  208. package/dist/types/facade/ml/kit/provider-constants.d.ts +34 -0
  209. package/dist/types/facade/ml/kit/provider-errors.d.ts +52 -0
  210. package/dist/types/facade/ml/kit/sanitize-unicode.d.ts +2 -0
  211. package/dist/types/facade/ml/kit/stream-event-helper.d.ts +38 -0
  212. package/dist/types/facade/ml/kit/stream-handler-types.d.ts +46 -0
  213. package/dist/types/facade/ml/kit/streaming-state-manager.d.ts +42 -0
  214. package/dist/types/facade/ml/kit/tool-converter.d.ts +49 -0
  215. package/dist/types/facade/ml/kit/typebox-helpers.d.ts +24 -0
  216. package/dist/types/facade/ml/kit/validation.d.ts +26 -0
  217. package/dist/types/facade/ml/models.d.ts +41 -0
  218. package/dist/types/facade/ml/models.generated.d.ts +12405 -0
  219. package/dist/types/facade/ml/stream.d.ts +27 -0
  220. package/dist/types/facade/ml/types.d.ts +269 -0
  221. package/dist/types/index.d.ts +18 -0
  222. package/dist/types/interop/index.d.ts +12 -0
  223. package/dist/types/interop/interop.test.d.ts +19 -0
  224. package/dist/types/interop/protocol-bridge/bridge.d.ts +52 -0
  225. package/dist/types/interop/protocol-bridge/contract.d.ts +249 -0
  226. package/dist/types/interop/protocol-bridge/endpoint.d.ts +124 -0
  227. package/dist/types/interop/protocol-bridge/fleet.d.ts +92 -0
  228. package/dist/types/interop/protocol-bridge/host.d.ts +61 -0
  229. package/dist/types/interop/protocol-bridge/index.d.ts +16 -0
  230. package/dist/types/interop/protocol-bridge/schema.d.ts +29 -0
  231. package/dist/types/llmgateway/catalog/cards.d.ts +18 -0
  232. package/dist/types/llmgateway/catalog/cost.d.ts +15 -0
  233. package/dist/types/llmgateway/catalog/index.d.ts +7 -0
  234. package/dist/types/llmgateway/catalog/query.d.ts +40 -0
  235. package/dist/types/llmgateway/connectors/anthropic.d.ts +35 -0
  236. package/dist/types/llmgateway/connectors/azure-openai.d.ts +33 -0
  237. package/dist/types/llmgateway/connectors/bedrock.d.ts +113 -0
  238. package/dist/types/llmgateway/connectors/google-vertex.d.ts +38 -0
  239. package/dist/types/llmgateway/connectors/google.d.ts +40 -0
  240. package/dist/types/llmgateway/connectors/index.d.ts +26 -0
  241. package/dist/types/llmgateway/connectors/kimi.d.ts +28 -0
  242. package/dist/types/llmgateway/connectors/mock.d.ts +37 -0
  243. package/dist/types/llmgateway/connectors/nvidia.d.ts +27 -0
  244. package/dist/types/llmgateway/connectors/ollama.d.ts +45 -0
  245. package/dist/types/llmgateway/connectors/openai-chat.d.ts +25 -0
  246. package/dist/types/llmgateway/connectors/openai-responses.d.ts +49 -0
  247. package/dist/types/llmgateway/contract/connector.d.ts +32 -0
  248. package/dist/types/llmgateway/contract/conversation.d.ts +86 -0
  249. package/dist/types/llmgateway/contract/emission.d.ts +55 -0
  250. package/dist/types/llmgateway/contract/errors.d.ts +27 -0
  251. package/dist/types/llmgateway/contract/index.d.ts +13 -0
  252. package/dist/types/llmgateway/contract/model-card.d.ts +42 -0
  253. package/dist/types/llmgateway/contract/options.d.ts +31 -0
  254. package/dist/types/llmgateway/contract/reply.d.ts +33 -0
  255. package/dist/types/llmgateway/conversion/index.d.ts +10 -0
  256. package/dist/types/llmgateway/conversion/mappers.d.ts +65 -0
  257. package/dist/types/llmgateway/conversion/openai-compatible.d.ts +46 -0
  258. package/dist/types/llmgateway/conversion/reduce.d.ts +20 -0
  259. package/dist/types/llmgateway/credentials/oauth.d.ts +73 -0
  260. package/dist/types/llmgateway/credentials/pkce.d.ts +52 -0
  261. package/dist/types/llmgateway/credentials/secrets.d.ts +76 -0
  262. package/dist/types/llmgateway/gateway.d.ts +34 -0
  263. package/dist/types/llmgateway/gateway.test.d.ts +14 -0
  264. package/dist/types/llmgateway/index.d.ts +11 -0
  265. package/dist/types/llmgateway/streaming/channel.d.ts +24 -0
  266. package/dist/types/llmgateway/streaming/index.d.ts +10 -0
  267. package/dist/types/llmgateway/streaming/ndjson.d.ts +17 -0
  268. package/dist/types/llmgateway/streaming/sse.d.ts +31 -0
  269. package/dist/types/react-host/index.d.ts +9 -0
  270. package/dist/types/react-host/ink.d.ts +5 -0
  271. package/dist/types/react-host/jsx-runtime.d.ts +4 -0
  272. package/dist/types/react-host/loader.d.ts +3 -0
  273. package/dist/types/react-ink/components/ChangelogBlock.d.ts +8 -0
  274. package/dist/types/react-ink/components/DisplayBlockView.d.ts +8 -0
  275. package/dist/types/react-ink/components/Footer.d.ts +11 -0
  276. package/dist/types/react-ink/components/MessageList.d.ts +14 -0
  277. package/dist/types/react-ink/components/MessageRow.d.ts +13 -0
  278. package/dist/types/react-ink/components/StatusLine.d.ts +18 -0
  279. package/dist/types/react-ink/components/TaskPanel.d.ts +11 -0
  280. package/dist/types/react-ink/components/ToolEventBlock.d.ts +48 -0
  281. package/dist/types/react-ink/components/ToolEventBlock.test.d.ts +1 -0
  282. package/dist/types/react-ink/components/dialogs/DialogFrame.d.ts +8 -0
  283. package/dist/types/react-ink/components/dialogs/LoginDialog.d.ts +14 -0
  284. package/dist/types/react-ink/components/dialogs/ModelDialog.d.ts +9 -0
  285. package/dist/types/react-ink/components/dialogs/OAuthDialog.d.ts +9 -0
  286. package/dist/types/react-ink/components/dialogs/ScopedModelsDialog.d.ts +9 -0
  287. package/dist/types/react-ink/components/dialogs/SelectableDialog.d.ts +22 -0
  288. package/dist/types/react-ink/components/dialogs/SessionDialog.d.ts +13 -0
  289. package/dist/types/react-ink/components/dialogs/SettingsDialog.d.ts +14 -0
  290. package/dist/types/react-ink/components/dialogs/StartupSessionPicker.d.ts +9 -0
  291. package/dist/types/react-ink/components/dialogs/ThemeDialog.d.ts +26 -0
  292. package/dist/types/react-ink/components/dialogs/TreeDialog.d.ts +8 -0
  293. package/dist/types/react-ink/components/dialogs/UserMessageDialog.d.ts +8 -0
  294. package/dist/types/react-ink/components/messages/AssistantMessage.d.ts +12 -0
  295. package/dist/types/react-ink/components/messages/BashMessage.d.ts +8 -0
  296. package/dist/types/react-ink/components/messages/BranchSummaryMessage.d.ts +8 -0
  297. package/dist/types/react-ink/components/messages/CompactionMessage.d.ts +8 -0
  298. package/dist/types/react-ink/components/messages/CustomMessage.d.ts +9 -0
  299. package/dist/types/react-ink/components/messages/SkillInvocationMessage.d.ts +7 -0
  300. package/dist/types/react-ink/components/messages/ToolCallMessage.d.ts +8 -0
  301. package/dist/types/react-ink/components/messages/ToolResultBlock.d.ts +12 -0
  302. package/dist/types/react-ink/components/messages/UserMessage.d.ts +9 -0
  303. package/dist/types/react-ink/diff/Diff.d.ts +22 -0
  304. package/dist/types/react-ink/diff/diff.test.d.ts +1 -0
  305. package/dist/types/react-ink/diff/structured.d.ts +41 -0
  306. package/dist/types/react-ink/diff/word-diff.d.ts +27 -0
  307. package/dist/types/react-ink/index.d.ts +42 -0
  308. package/dist/types/react-ink/markdown/Markdown.d.ts +23 -0
  309. package/dist/types/react-ink/markdown/MarkdownTable.d.ts +19 -0
  310. package/dist/types/react-ink/markdown/StreamingMarkdown.d.ts +34 -0
  311. package/dist/types/react-ink/markdown/format-token.d.ts +39 -0
  312. package/dist/types/react-ink/markdown/highlight.d.ts +31 -0
  313. package/dist/types/react-ink/theme-adapter.d.ts +66 -0
  314. package/dist/types/react-ink/types.d.ts +133 -0
  315. package/dist/types/react-ink/utils/message-groups.d.ts +25 -0
  316. package/dist/types/react-ink/utils/selection-dialog.d.ts +2 -0
  317. package/dist/types/react-ink/utils/session-browser.d.ts +27 -0
  318. package/dist/types/react-ink/utils/tool-display.d.ts +37 -0
  319. package/dist/types/runtime/cadence/cadence.test.d.ts +6 -0
  320. package/dist/types/runtime/cadence/fold.d.ts +48 -0
  321. package/dist/types/runtime/cadence/index.d.ts +12 -0
  322. package/dist/types/runtime/cadence/reducer.d.ts +44 -0
  323. package/dist/types/runtime/conductor/agent.d.ts +71 -0
  324. package/dist/types/runtime/conductor/index.d.ts +11 -0
  325. package/dist/types/runtime/contract/config.d.ts +44 -0
  326. package/dist/types/runtime/contract/effect.d.ts +41 -0
  327. package/dist/types/runtime/contract/errors.d.ts +22 -0
  328. package/dist/types/runtime/contract/events.d.ts +63 -0
  329. package/dist/types/runtime/contract/index.d.ts +18 -0
  330. package/dist/types/runtime/contract/run-state.d.ts +57 -0
  331. package/dist/types/runtime/contract/session.d.ts +42 -0
  332. package/dist/types/runtime/contract/signal.d.ts +49 -0
  333. package/dist/types/runtime/contract/tools.d.ts +45 -0
  334. package/dist/types/runtime/dispatch/index.d.ts +9 -0
  335. package/dist/types/runtime/dispatch/scheduler.d.ts +53 -0
  336. package/dist/types/runtime/index.d.ts +22 -0
  337. package/dist/types/runtime/ledger/accumulator.d.ts +44 -0
  338. package/dist/types/runtime/ledger/bus.d.ts +50 -0
  339. package/dist/types/runtime/ledger/index.d.ts +11 -0
  340. package/dist/types/runtime/memory/compactor.d.ts +56 -0
  341. package/dist/types/runtime/memory/estimate.d.ts +21 -0
  342. package/dist/types/runtime/memory/index.d.ts +8 -0
  343. package/dist/types/runtime/runtime.test.d.ts +15 -0
  344. package/dist/types/runtime/store/dag.d.ts +72 -0
  345. package/dist/types/runtime/store/hash.d.ts +18 -0
  346. package/dist/types/runtime/store/index.d.ts +12 -0
  347. package/dist/types/runtime/store/persist.d.ts +49 -0
  348. package/dist/types/runtime/turn/driver.d.ts +32 -0
  349. package/dist/types/runtime/turn/index.d.ts +8 -0
  350. package/dist/types/runtime/wire/index.d.ts +10 -0
  351. package/dist/types/runtime/wire/projectors.d.ts +53 -0
  352. package/dist/types/shell-app/auth-cli/index.d.ts +9 -0
  353. package/dist/types/shell-app/auth-cli/oauth-cli.d.ts +73 -0
  354. package/dist/types/shell-app/boot/context.d.ts +108 -0
  355. package/dist/types/shell-app/boot/index.d.ts +13 -0
  356. package/dist/types/shell-app/boot/pipeline.d.ts +66 -0
  357. package/dist/types/shell-app/boot/stages.d.ts +77 -0
  358. package/dist/types/shell-app/cli.d.ts +75 -0
  359. package/dist/types/shell-app/config/index.d.ts +11 -0
  360. package/dist/types/shell-app/config/locator.d.ts +85 -0
  361. package/dist/types/shell-app/config/settings.d.ts +91 -0
  362. package/dist/types/shell-app/index.d.ts +26 -0
  363. package/dist/types/shell-app/invocation/flags.d.ts +89 -0
  364. package/dist/types/shell-app/invocation/parse.d.ts +89 -0
  365. package/dist/types/shell-app/locate/brand.d.ts +71 -0
  366. package/dist/types/shell-app/locate/index.d.ts +12 -0
  367. package/dist/types/shell-app/locate/locator.d.ts +122 -0
  368. package/dist/types/shell-app/runners/contract.d.ts +116 -0
  369. package/dist/types/shell-app/runners/index.d.ts +15 -0
  370. package/dist/types/shell-app/runners/one-shot.d.ts +21 -0
  371. package/dist/types/shell-app/runners/registry.d.ts +34 -0
  372. package/dist/types/shell-app/runners/repl.d.ts +51 -0
  373. package/dist/types/shell-app/runners/wire.d.ts +34 -0
  374. package/dist/types/shell-app/shell-app.test.d.ts +14 -0
  375. package/dist/types/shell-app/upgrade/index.d.ts +9 -0
  376. package/dist/types/shell-app/upgrade/upgrades.d.ts +62 -0
  377. package/dist/types/smithy/config/flag-reader.d.ts +128 -0
  378. package/dist/types/smithy/config/index.d.ts +9 -0
  379. package/dist/types/smithy/forge.d.ts +135 -0
  380. package/dist/types/smithy/index.d.ts +36 -0
  381. package/dist/types/smithy/knowledge/index.d.ts +10 -0
  382. package/dist/types/smithy/knowledge/loader.d.ts +64 -0
  383. package/dist/types/smithy/persona/blueprint.d.ts +75 -0
  384. package/dist/types/smithy/persona/define-agent.d.ts +51 -0
  385. package/dist/types/smithy/persona/index.d.ts +14 -0
  386. package/dist/types/smithy/persona/profiles.d.ts +44 -0
  387. package/dist/types/smithy/runtime/index.d.ts +9 -0
  388. package/dist/types/smithy/runtime/tool-ledger.d.ts +130 -0
  389. package/dist/types/smithy/smithy.test.d.ts +20 -0
  390. package/dist/types/smithy/ui/index.d.ts +11 -0
  391. package/dist/types/smithy/ui/transcript.d.ts +183 -0
  392. package/dist/types/swarm/coordinator.d.ts +192 -0
  393. package/dist/types/swarm/index.d.ts +33 -0
  394. package/dist/types/swarm/isolation/index.d.ts +14 -0
  395. package/dist/types/swarm/isolation/runner.d.ts +61 -0
  396. package/dist/types/swarm/isolation/worktree.d.ts +142 -0
  397. package/dist/types/swarm/kernel/faults.d.ts +52 -0
  398. package/dist/types/swarm/kernel/ids.d.ts +25 -0
  399. package/dist/types/swarm/kernel/index.d.ts +26 -0
  400. package/dist/types/swarm/kernel/json-cell.d.ts +113 -0
  401. package/dist/types/swarm/kernel/jsonl-log.d.ts +81 -0
  402. package/dist/types/swarm/postbox/channel.d.ts +88 -0
  403. package/dist/types/swarm/postbox/codecs.d.ts +253 -0
  404. package/dist/types/swarm/postbox/index.d.ts +16 -0
  405. package/dist/types/swarm/roster/index.d.ts +16 -0
  406. package/dist/types/swarm/roster/manifest.d.ts +185 -0
  407. package/dist/types/swarm/swarm.test.d.ts +24 -0
  408. package/dist/types/swarm/telemetry/activity.d.ts +143 -0
  409. package/dist/types/swarm/workboard/board.d.ts +174 -0
  410. package/dist/types/swarm/workboard/dep-graph.d.ts +77 -0
  411. package/dist/types/swarm/workboard/index.d.ts +12 -0
  412. package/dist/types/tracing/adapter/index.d.ts +12 -0
  413. package/dist/types/tracing/adapter/runtime-trace.d.ts +54 -0
  414. package/dist/types/tracing/channel/index.d.ts +9 -0
  415. package/dist/types/tracing/channel/signal.d.ts +93 -0
  416. package/dist/types/tracing/index.d.ts +25 -0
  417. package/dist/types/tracing/recorder/index.d.ts +12 -0
  418. package/dist/types/tracing/recorder/recorder.d.ts +75 -0
  419. package/dist/types/tracing/recorder/sampling.d.ts +55 -0
  420. package/dist/types/tracing/redaction/index.d.ts +8 -0
  421. package/dist/types/tracing/redaction/secret-scrubber.d.ts +95 -0
  422. package/dist/types/tracing/registry/hub.d.ts +57 -0
  423. package/dist/types/tracing/registry/index.d.ts +7 -0
  424. package/dist/types/tracing/signal/handle.d.ts +73 -0
  425. package/dist/types/tracing/signal/index.d.ts +12 -0
  426. package/dist/types/tracing/signal/segment.d.ts +124 -0
  427. package/dist/types/tracing/sinks/base.d.ts +51 -0
  428. package/dist/types/tracing/sinks/console.d.ts +44 -0
  429. package/dist/types/tracing/sinks/file.d.ts +47 -0
  430. package/dist/types/tracing/sinks/index.d.ts +16 -0
  431. package/dist/types/tracing/sinks/stream.d.ts +46 -0
  432. package/dist/types/tracing/tracing.test.d.ts +7 -0
  433. package/dist/types/ui/autocomplete.d.ts +59 -0
  434. package/dist/types/ui/contracts.d.ts +38 -0
  435. package/dist/types/ui/editor-component.d.ts +100 -0
  436. package/dist/types/ui/fuzzy.d.ts +29 -0
  437. package/dist/types/ui/index.d.ts +8 -0
  438. package/dist/types/ui/keybindings.d.ts +62 -0
  439. package/dist/types/ui/keys.d.ts +171 -0
  440. package/dist/types/ui/theme-types.d.ts +36 -0
  441. package/dist/types/ui/utils.d.ts +101 -0
  442. package/dist/types/ui-bridge/InteractiveApp.d.ts +38 -0
  443. package/dist/types/ui-bridge/adapter.d.ts +90 -0
  444. package/dist/types/ui-bridge/index.d.ts +37 -0
  445. package/dist/zoho.js +1451 -0
  446. package/package.json +48 -48
@@ -0,0 +1,58 @@
1
+ /**
2
+ * The pluggable result-summarizer registry.
3
+ *
4
+ * When a remote operation returns, the bridge wants *one short line* describing
5
+ * what came back — for a log entry, a status header, or a glance in the tool list.
6
+ * Different toolkits want different one-liners: a mail send is best summarized by
7
+ * its recipient, a list endpoint by its row count, a search by its top hit. Rather
8
+ * than bake a tower of `if (toolkit === …)` branches into one formatter, the choice
9
+ * is a lookup: {@link SUMMARIZERS} maps a toolkit slug (or a `prefix:*` glob) to a
10
+ * `(result) => string`, and {@link summarizeResult} picks the most specific match,
11
+ * falling back to a generic compact JSON preview.
12
+ *
13
+ * The default summarizer is the interesting one. It produces a short preview of the
14
+ * payload while **deduping repeated blobs**: large structured responses often carry
15
+ * the same nested object many times (the same author on every row, the same schema
16
+ * on every field), and naively previewing them buries the signal. So the default
17
+ * walks the payload *iteratively* — an explicit stack, never recursion, so a deep or
18
+ * cyclic response can never blow the call stack — content-hashes every object and
19
+ * array it meets, and replaces any repeat with a back-reference to where it first
20
+ * appeared. The result is a compact, de-duplicated sketch of the shape.
21
+ */
22
+ import type { RemoteResult } from "../core/port";
23
+ /**
24
+ * A function that renders one {@link RemoteResult} into a single human-readable
25
+ * line. Registered against a toolkit slug or a `prefix:*` pattern in
26
+ * {@link SUMMARIZERS} and selected by {@link summarizeResult}.
27
+ */
28
+ export type Summarizer = (result: RemoteResult) => string;
29
+ /**
30
+ * The toolkit slug a `<toolkit>_<operation>` (or `<toolkit>.<operation>`) tool name
31
+ * implies, lower-cased. Plain names with no separator are returned whole. This is
32
+ * what {@link summarizeResult} keys the registry lookup on.
33
+ */
34
+ export declare function toolkitOf(toolName: string): string;
35
+ /**
36
+ * The fallback summarizer used when no toolkit-specific entry matches.
37
+ *
38
+ * A failure renders as its error line; a success renders as a deduped JSON preview
39
+ * of its payload (see {@link previewPayload}). The line is always length-clamped.
40
+ */
41
+ export declare function defaultSummarizer(result: RemoteResult): string;
42
+ /**
43
+ * The summarizer registry: toolkit slug (or `prefix:*` glob) → {@link Summarizer}.
44
+ *
45
+ * Exact slugs win over globs, and globs win over the built-in default. Entries are
46
+ * added here (or at runtime via the exported map) to teach the bridge how to phrase
47
+ * a given product's results. The starter rows below are illustrative, declarative
48
+ * data — extend the table, don't fork the formatter.
49
+ */
50
+ export declare const SUMMARIZERS: Map<string, Summarizer>;
51
+ /**
52
+ * Summarize one operation's result in a single line.
53
+ *
54
+ * Selection is most-specific-first: an exact toolkit-slug entry, then a `prefix:*`
55
+ * glob whose prefix the slug starts with (longest prefix wins), then the built-in
56
+ * {@link defaultSummarizer}. The chosen summarizer is handed the raw result.
57
+ */
58
+ export declare function summarizeResult(toolName: string, result: RemoteResult): string;
@@ -0,0 +1,14 @@
1
+ /**
2
+ * Connect to Sarvam AI via the official `uvx sarvam-mcp` stdio server.
3
+ *
4
+ * No OAuth — auth is the `SARVAM_API_KEY` env var. We spawn the subprocess
5
+ * with the SDK-backed {@link MCPClient} (which already supports stdio),
6
+ * list the remote tools, and project them into a runtime {@link ToolBox}
7
+ * via {@link mcpClientToToolBox} using `options.id` (default `"sarvam"`)
8
+ * as the tool-name prefix so two MCP servers can never collide.
9
+ */
10
+ import type { ConnectSarvamMcpOptions, SarvamMcpConnection } from "./types.js";
11
+ /**
12
+ * Open a Sarvam MCP stdio connection and return a ready-to-use toolbox + client.
13
+ */
14
+ export declare function connectSarvamMcp(options: ConnectSarvamMcpOptions): Promise<SarvamMcpConnection>;
@@ -0,0 +1,14 @@
1
+ /**
2
+ * Tests for {@link connectSarvamMcp}.
3
+ *
4
+ * A small `FakeMCPClient` stands in for the SDK-backed client. We use
5
+ * `vi.mock` to redirect the `MCPClient` import in `./connect.js` to a
6
+ * factory that returns our fake — no subprocess, no `uvx` download, no
7
+ * Sarvam network call, no monkey-patching of live modules. The mock
8
+ * captures every constructor invocation into a shared holder so the
9
+ * assertions can pin exactly what the connector passed to `new MCPClient`.
10
+ *
11
+ * Mirrors the structure of {@link ../connectors-zoho/connectors-zoho.test.ts}
12
+ * so the two connectors share one test idiom.
13
+ */
14
+ export {};
@@ -0,0 +1,14 @@
1
+ /**
2
+ * Public barrel for the Sarvam MCP connector.
3
+ *
4
+ * - {@link connectSarvamMcp} — the high-level "give me a working toolbox"
5
+ * entry point that takes a Sarvam API key (or env var) and spawns
6
+ * `uvx sarvam-mcp` over stdio.
7
+ * - {@link sarvamToolBoxFromClient} — the lower-level adapter for callers
8
+ * who already hold a connected {@link MCPClient}.
9
+ * - {@link ConnectSarvamMcpOptions} / {@link SarvamMcpConnection} — the
10
+ * public types for those two entry points.
11
+ */
12
+ export { connectSarvamMcp } from "./connect.js";
13
+ export { sarvamToolBoxFromClient } from "./toolbox.js";
14
+ export type { ConnectSarvamMcpOptions, SarvamMcpConnection } from "./types.js";
@@ -0,0 +1,19 @@
1
+ /**
2
+ * Thin re-export wrapper so power users can also import just the toolbox
3
+ * adapter without going through {@link connectSarvamMcp}.
4
+ *
5
+ * `sarvamToolBoxFromClient` is equivalent to
6
+ * `mcpClientToToolBox(client, { namePrefix: options.id ?? "sarvam", ... })`
7
+ * — it just defaults the prefix to the Sarvam id.
8
+ */
9
+ import type { McpToToolBoxOptions } from "../facade/mcp-core/toolbox-bridge.js";
10
+ import type { MCPClient } from "../facade/mcp-core/client.js";
11
+ import type { ToolBox } from "../runtime/contract/index.js";
12
+ /**
13
+ * Wrap a connected {@link MCPClient} as a runtime {@link ToolBox} with a
14
+ * Sarvam-friendly prefix. Equivalent to
15
+ * `mcpClientToToolBox(client, { namePrefix: options.id ?? "sarvam", ... })`.
16
+ */
17
+ export declare function sarvamToolBoxFromClient(client: MCPClient, options?: {
18
+ id?: string;
19
+ } & Omit<McpToToolBoxOptions, "namePrefix">): Promise<ToolBox>;
@@ -0,0 +1,49 @@
1
+ /**
2
+ * Public types for the Sarvam MCP integration.
3
+ *
4
+ * The Sarvam DX exposes an MCP server that runs as a stdio subprocess
5
+ * (`uvx sarvam-mcp`). Auth is a single dashboard-issued API key passed via
6
+ * the `SARVAM_API_KEY` environment variable. These types describe how a
7
+ * caller hands that key — plus a few cosmetic knobs — to
8
+ * {@link connectSarvamMcp} and gets back a runtime {@link ToolBox} ready to
9
+ * drop into `createAgent({ tools })`.
10
+ */
11
+ import type { ToolBox } from "../runtime/contract/index.js";
12
+ import type { MCPClient } from "../facade/mcp-core/client.js";
13
+ /** Options for {@link connectSarvamMcp}. */
14
+ export interface ConnectSarvamMcpOptions {
15
+ /** Sarvam dashboard API key. Falls back to process.env.SARVAM_API_KEY. */
16
+ readonly apiKey?: string;
17
+ /** Stable id used for tool-name prefixing (default: "sarvam"). */
18
+ readonly id?: string;
19
+ /** Override Sarvam API base URL. Falls back to SARVAM_API_BASE_URL env, then "https://api.sarvam.ai". */
20
+ readonly baseUrl?: string;
21
+ /** Override where the Sarvam MCP server writes audio/docs files. Falls back to SARVAM_MCP_BASE_PATH env, then "~/Desktop". */
22
+ readonly basePath?: string;
23
+ /** Subprocess command. Default: "uvx". */
24
+ readonly command?: string;
25
+ /** Subprocess args. Default: ["sarvam-mcp"]. */
26
+ readonly args?: readonly string[];
27
+ /** Extra env for the subprocess. SARVAM_API_KEY and the *_BASE_URL/_BASE_PATH vars above are merged on top. */
28
+ readonly env?: Readonly<Record<string, string>>;
29
+ /** Connect timeout in ms (default 60_000 — uvx may download on first run). */
30
+ readonly timeoutMs?: number;
31
+ /** Optional logger for diagnostics. */
32
+ readonly logger?: {
33
+ debug(msg: string): void;
34
+ error(msg: string, err?: unknown): void;
35
+ };
36
+ }
37
+ /** The handle returned by {@link connectSarvamMcp}. */
38
+ export interface SarvamMcpConnection {
39
+ /** Stable id used for tool prefixing. */
40
+ readonly id: string;
41
+ /** Runtime ToolBox ready for `createAgent({ tools: sarvam.toolBox })`. */
42
+ readonly toolBox: ToolBox;
43
+ /** Names of every remote tool (already prefixed). */
44
+ readonly toolNames: readonly string[];
45
+ /** Underlying MCPClient (escape hatch). */
46
+ readonly client: MCPClient;
47
+ /** Disconnect and kill the spawned uvx child. Idempotent. */
48
+ close(): Promise<void>;
49
+ }
@@ -0,0 +1,22 @@
1
+ /**
2
+ * Connect to a Zoho MCP server.
3
+ *
4
+ * Validates the URL, builds an HTTP-backed {@link MCPClient} (Streamable HTTP by
5
+ * default, legacy SSE when `useSse: true`), wires an OAuth 2.1 + PKCE auth
6
+ * provider for the transport when `auth` is `"auto"` (default) or `"oauth"`,
7
+ * opens the connection, then bridges the remote tool catalog into a runtime
8
+ * {@link ToolBox} via {@link mcpClientToToolBox} using `options.id` (default
9
+ * `"zoho"`) as the tool-name prefix so two servers can never collide.
10
+ *
11
+ * On 401 from Zoho:
12
+ * 1. SDK discovers the auth server (RFC 9728 / 8414)
13
+ * 2. Browser opens for PKCE login
14
+ * 3. Local callback captures the code
15
+ * 4. `transport.finishAuth(code)` exchanges tokens
16
+ * 5. Reconnect with Bearer token
17
+ *
18
+ * Tokens persist to `~/.config/indusagi/credentials/mcp/<id>.json` (mode 0600).
19
+ */
20
+ import type { ConnectZohoMcpOptions, ZohoMcpConnection } from "./types.js";
21
+ /** Open a Zoho MCP connection and return a ready-to-use toolbox + client. */
22
+ export declare function connectZohoMcp(options: ConnectZohoMcpOptions): Promise<ZohoMcpConnection>;
@@ -0,0 +1,10 @@
1
+ /**
2
+ * Tests for {@link connectZohoMcp}.
3
+ *
4
+ * A small `FakeMCPClient` stands in for the SDK-backed client. We use
5
+ * `vi.mock` to redirect the `MCPClient` import in `./connect.js` to a
6
+ * factory that returns our fake — no network, no vendor SDK, no
7
+ * monkey-patching of live modules. The fake records every method call so
8
+ * assertions can pin exactly what the connector did.
9
+ */
10
+ export {};
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Public barrel for the Zoho MCP connector.
3
+ *
4
+ * - {@link connectZohoMcp} — the high-level "give me a working toolbox"
5
+ * entry point that takes a Zoho console URL.
6
+ * - {@link zohoToolBoxFromClient} — the lower-level adapter for callers who
7
+ * already hold a connected {@link MCPClient}.
8
+ * - {@link ConnectZohoMcpOptions} / {@link ZohoMcpConnection} — the public
9
+ * types for those two entry points.
10
+ */
11
+ export { connectZohoMcp } from "./connect.js";
12
+ export { zohoToolBoxFromClient } from "./toolbox.js";
13
+ export type { ConnectZohoMcpOptions, ZohoMcpConnection } from "./types.js";
@@ -0,0 +1,19 @@
1
+ /**
2
+ * Thin re-export wrapper so power users can also import just the toolbox
3
+ * adapter without going through {@link connectZohoMcp}.
4
+ *
5
+ * `zohoToolBoxFromClient` is equivalent to
6
+ * `mcpClientToToolBox(client, { namePrefix: options.id ?? "zoho", ... })`
7
+ * — it just defaults the prefix to the Zoho id.
8
+ */
9
+ import type { McpToToolBoxOptions } from "../facade/mcp-core/toolbox-bridge.js";
10
+ import type { MCPClient } from "../facade/mcp-core/client.js";
11
+ import type { ToolBox } from "../runtime/contract/index.js";
12
+ /**
13
+ * Wrap a connected {@link MCPClient} as a runtime {@link ToolBox} with a
14
+ * Zoho-friendly prefix. Equivalent to
15
+ * `mcpClientToToolBox(client, { namePrefix: options.id ?? "zoho", ... })`.
16
+ */
17
+ export declare function zohoToolBoxFromClient(client: MCPClient, options?: {
18
+ id?: string;
19
+ } & Omit<McpToToolBoxOptions, "namePrefix">): Promise<ToolBox>;
@@ -0,0 +1,56 @@
1
+ /**
2
+ * Public types for the Zoho MCP integration.
3
+ *
4
+ * The Zoho DX exposes a remote MCP server URL from the Zoho developer console.
5
+ * These types describe how a caller hands that URL — plus a few cosmetic
6
+ * knobs — to {@link connectZohoMcp} and gets back a runtime
7
+ * {@link ToolBox} ready to drop into `createAgent({ tools })`.
8
+ */
9
+ /** Options for {@link connectZohoMcp}. */
10
+ export interface ConnectZohoMcpOptions {
11
+ /** The MCP server URL from Zoho console → Connect tab. */
12
+ readonly url: string;
13
+ /** Stable id used for tool-name prefixing (default: "zoho"). */
14
+ readonly id?: string;
15
+ /**
16
+ * Auth mode:
17
+ * - "auto" (default): wire OAuth 2.1 + PKCE; let the SDK drive discovery and
18
+ * token refresh on 401. Persists tokens to `~/.config/indusagi/credentials/mcp/<id>.json`.
19
+ * - "oauth": same as "auto", explicit.
20
+ * - "none": no client OAuth; pass the URL through as-is (Zoho may have
21
+ * embedded a token, or you may have set a bearer via `headers`).
22
+ */
23
+ readonly auth?: "auto" | "oauth" | "none";
24
+ /** Optional static headers (e.g. Authorization). Use with care. */
25
+ readonly headers?: Readonly<Record<string, string>>;
26
+ /** Request timeout in ms (default 30_000). */
27
+ readonly timeoutMs?: number;
28
+ /** Use the legacy SSE transport instead of Streamable HTTP. Default: false. */
29
+ readonly useSse?: boolean;
30
+ /** Override the credentials directory (default: `~/.config/indusagi/credentials/mcp/`). */
31
+ readonly tokenStorePath?: string;
32
+ /** Override the OAuth redirect URI (default: `http://127.0.0.1:<random>/callback`). */
33
+ readonly redirectUrl?: string;
34
+ /** Open the browser for the OAuth round (default: true in TTY, false in CI). */
35
+ readonly openBrowser?: boolean;
36
+ /** OAuth scopes to request (default: server-advertised). */
37
+ readonly scopes?: readonly string[];
38
+ /** Optional logger for diagnostics. */
39
+ readonly logger?: {
40
+ debug(msg: string): void;
41
+ error(msg: string, err?: unknown): void;
42
+ };
43
+ }
44
+ /** The handle returned by {@link connectZohoMcp}. */
45
+ export interface ZohoMcpConnection {
46
+ /** Stable id used for tool prefixing. */
47
+ readonly id: string;
48
+ /** Runtime ToolBox ready for `createAgent({ tools: zoho.toolBox })`. */
49
+ readonly toolBox: import("../runtime/contract/index.js").ToolBox;
50
+ /** Names of every remote tool (already prefixed). */
51
+ readonly toolNames: readonly string[];
52
+ /** Underlying MCPClient (escape hatch). */
53
+ readonly client: import("../facade/mcp-core/client.js").MCPClient;
54
+ /** Disconnect from the MCP server. Idempotent. */
55
+ close(): Promise<void>;
56
+ }
@@ -0,0 +1 @@
1
+ export * from "./bot/index";
@@ -0,0 +1 @@
1
+ export * from "./ml/index";
@@ -0,0 +1,71 @@
1
+ import type { AgentTool } from "../types.js";
2
+ import type { HookRunner } from "./kit/hook-runner.js";
3
+ import { type SandboxConfig } from "./sandbox-backend.js";
4
+ import { type TruncationResult } from "./truncate.js";
5
+ export interface BashSecurityConfig {
6
+ /** Patterns that, when matched, stop a command from running. */
7
+ blockedPatterns?: RegExp[];
8
+ }
9
+ declare const bashSchema: import("@sinclair/typebox").TObject<{
10
+ command: import("@sinclair/typebox").TString;
11
+ timeout: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
12
+ }>;
13
+ export interface BashToolDetails {
14
+ truncation?: TruncationResult;
15
+ fullOutputPath?: string;
16
+ }
17
+ /**
18
+ * Pluggable execution backend for the bash tool. Provide a custom implementation
19
+ * to dispatch commands somewhere other than the local shell, for instance to a
20
+ * remote host over a transport layer.
21
+ */
22
+ export interface BashOperations {
23
+ /**
24
+ * Execute a command, relaying its output back through a callback as it streams in.
25
+ * @param command - The command line to execute
26
+ * @param cwd - Working directory for the command
27
+ * @param options - Streaming callback, cancellation signal, timeout, and env overrides
28
+ * @returns A promise resolving to the exit code, or null if the process was terminated
29
+ */
30
+ exec: (command: string, cwd: string, options: {
31
+ onData: (data: Buffer) => void;
32
+ signal?: AbortSignal;
33
+ timeout?: number;
34
+ env?: NodeJS.ProcessEnv;
35
+ }) => Promise<{
36
+ exitCode: number | null;
37
+ }>;
38
+ }
39
+ export interface BashToolOptions {
40
+ /** Backend hook for running commands. When omitted, the local shell is used. */
41
+ operations?: BashOperations;
42
+ /** Text glued to the front of every command (e.g. "shopt -s expand_aliases" to enable aliases). */
43
+ commandPrefix?: string;
44
+ /** Dispatcher consulted for the shell.env hook so callers can inject env vars. */
45
+ hookRunner?: HookRunner;
46
+ /** Settings that decide which commands are allowed to run. */
47
+ security?: BashSecurityConfig;
48
+ /**
49
+ * OPT-IN OS sandbox. OFF by default: when omitted or `enabled` is false the
50
+ * bash tool spawns exactly as before. When enabled, each command is wrapped
51
+ * in the platform's OS sandbox (macOS `sandbox-exec`, Linux `bwrap`); if no
52
+ * sandbox tool is available the command runs un-sandboxed and a note is
53
+ * recorded via `onSandboxNote` rather than silently claiming sandboxing.
54
+ */
55
+ sandbox?: SandboxConfig;
56
+ /** Receives an honest note describing whether the sandbox was applied or skipped. */
57
+ onSandboxNote?: (note: string) => void;
58
+ /** Optional log that collects the commands as they are issued. */
59
+ commandHistory?: string[];
60
+ /** Time budget, in seconds, applied when the model omits `timeout`. Defaults to 120s. */
61
+ defaultTimeoutSeconds?: number;
62
+ /** Hard ceiling, in seconds, that any supplied `timeout` is clamped to. Defaults to 600s (and is never lower than the default). */
63
+ maxTimeoutSeconds?: number;
64
+ }
65
+ export declare function createBashTool(cwd: string, options?: BashToolOptions): AgentTool<typeof bashSchema>;
66
+ /** Ready-made bash tool bound to the process working directory. */
67
+ export declare const bashTool: AgentTool<import("@sinclair/typebox").TObject<{
68
+ command: import("@sinclair/typebox").TString;
69
+ timeout: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
70
+ }>, any>;
71
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,49 @@
1
+ /**
2
+ * File-checkpoint hook for the WIRED facade tool layer.
3
+ *
4
+ * This is the framework half of the rewind feature. The product (the coding
5
+ * agent) constructs a `CheckpointStore`, exposes a small duck-typed
6
+ * {@link CheckpointHandle} on the shared `ctx.framework` bag under the literal
7
+ * key `'checkpoint'`, and passes it into the `write` / `edit` factories — the
8
+ * same place the read-before-edit gate's `readState` handle is wired. When a
9
+ * handle is present, every mutating file tool captures the file's pre-mutation
10
+ * on-disk content EXACTLY ONCE per mutated path, so a later rewind can roll the
11
+ * working tree back to that snapshot.
12
+ *
13
+ * Like the read-edit gate, the whole mechanism is *additive*: with no handle
14
+ * present every helper here is a no-op and the tools behave exactly as they did
15
+ * before. The handle is duck-typed so the host and these factories agree on
16
+ * shape without a cross-package type import.
17
+ */
18
+ /**
19
+ * Duck-typed sink the host injects to receive pre-mutation snapshots.
20
+ *
21
+ * `record` is called once per mutated path, before the write lands, with the
22
+ * file's OLD on-disk content — or `null` when the file did not exist on disk
23
+ * before this mutation (so a rewind that visits this snapshot knows to DELETE
24
+ * the file rather than restore stale bytes).
25
+ */
26
+ export interface CheckpointHandle {
27
+ /**
28
+ * Capture the pre-mutation state of `absPath`.
29
+ *
30
+ * @param absPath Absolute path of the file about to be written.
31
+ * @param previous The file's content before this mutation, or `null` if the
32
+ * file did not exist on disk beforehand.
33
+ */
34
+ record(absPath: string, previous: string | null): void;
35
+ }
36
+ /**
37
+ * Read the CURRENT on-disk content of `absPath` and hand it to the checkpoint
38
+ * handle, capturing the PRE-mutation state.
39
+ *
40
+ * This MUST be invoked synchronously-ordered immediately before the write so the
41
+ * captured snapshot is the OLD content (no read/write race). When the file does
42
+ * not exist on disk, `null` is recorded so a rewind knows to delete it.
43
+ *
44
+ * No-op when no handle is present. A read/stat failure that is NOT a plain
45
+ * "missing file" is swallowed: checkpointing is best-effort and must never mask
46
+ * the real operation's outcome. (A genuine ENOENT is reported as `null`, the
47
+ * meaningful "file absent" snapshot.)
48
+ */
49
+ export declare function recordCheckpoint(handle: CheckpointHandle | undefined, absPath: string): void;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,22 @@
1
+ import type { AgentTool } from "../../types.js";
2
+ import { ComposioService } from "./client.js";
3
+ import type { ComposioToolFactoryOptions } from "./types.js";
4
+ declare const composioAccountsSchema: import("@sinclair/typebox").TObject<{
5
+ toolkits: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
6
+ statuses: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
7
+ limit: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
8
+ cursor: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
9
+ authConfigIds: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
10
+ }>;
11
+ export type ComposioAccountsToolDetails = Awaited<ReturnType<ComposioService["listAccounts"]>> & {
12
+ userId: string;
13
+ };
14
+ export declare function createComposioAccountsTool(options?: ComposioToolFactoryOptions): AgentTool<typeof composioAccountsSchema, ComposioAccountsToolDetails>;
15
+ export declare const composioAccountsTool: AgentTool<import("@sinclair/typebox").TObject<{
16
+ toolkits: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
17
+ statuses: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
18
+ limit: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TNumber>;
19
+ cursor: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
20
+ authConfigIds: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
21
+ }>, ComposioAccountsToolDetails>;
22
+ export {};
@@ -0,0 +1,39 @@
1
+ import type { ConnectedAccountListParams, ConnectedAccountListResponse, ToolListParams, ToolkitConnectionsDetails, ToolRouterSessionSearchResponse } from "@composio/core";
2
+ import type { ComposioAgentTool, ComposioAgentToolsOptions, ComposioBaseOptions, ComposioConnectResult, ComposioExecuteResult, ComposioRawTool, ComposioToolListResult } from "./types.js";
3
+ export declare class ComposioService {
4
+ private readonly options;
5
+ private readonly provider;
6
+ private clientPromise;
7
+ private readonly rawToolCache;
8
+ private readonly sessionCache;
9
+ constructor(options?: ComposioBaseOptions);
10
+ resolveUserId(): Promise<string>;
11
+ private resolveApiKey;
12
+ private getClient;
13
+ getRawToolBySlug(slug: string): Promise<ComposioRawTool>;
14
+ listRawTools(filters: ToolListParams): Promise<ComposioToolListResult>;
15
+ private resolveToolListFilters;
16
+ private resolveSessionSelection;
17
+ private getSession;
18
+ listToolkits(input: {
19
+ toolkits?: string[];
20
+ search?: string;
21
+ limit?: number;
22
+ nextCursor?: string;
23
+ isConnected?: boolean;
24
+ }): Promise<ToolkitConnectionsDetails>;
25
+ searchTools(query: string, toolkits?: string[]): Promise<ToolRouterSessionSearchResponse>;
26
+ createAgentTools(options: ComposioAgentToolsOptions): Promise<ComposioAgentTool[]>;
27
+ executeTool(options: ComposioAgentToolsOptions & {
28
+ toolSlug: string;
29
+ arguments?: Record<string, unknown>;
30
+ }): Promise<ComposioExecuteResult>;
31
+ listAccounts(filters?: ConnectedAccountListParams): Promise<ConnectedAccountListResponse>;
32
+ connectAccount(options: {
33
+ toolkit?: string;
34
+ connectedAccountId?: string;
35
+ authConfigId?: string;
36
+ callbackUrl?: string;
37
+ }): Promise<ComposioConnectResult>;
38
+ }
39
+ export declare function createComposioAgentTools(options: ComposioAgentToolsOptions): Promise<ComposioAgentTool[]>;
@@ -0,0 +1,19 @@
1
+ import type { AgentTool } from "../../types.js";
2
+ import type { ComposioConnectResult, ComposioToolFactoryOptions } from "./types.js";
3
+ declare const composioConnectSchema: import("@sinclair/typebox").TObject<{
4
+ toolkit: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
5
+ connectedAccountId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
6
+ authConfigId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
7
+ callbackUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
8
+ }>;
9
+ export interface ComposioConnectToolDetails extends ComposioConnectResult {
10
+ userId: string;
11
+ }
12
+ export declare function createComposioConnectTool(options?: ComposioToolFactoryOptions): AgentTool<typeof composioConnectSchema, ComposioConnectToolDetails>;
13
+ export declare const composioConnectTool: AgentTool<import("@sinclair/typebox").TObject<{
14
+ toolkit: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
15
+ connectedAccountId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
16
+ authConfigId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
17
+ callbackUrl: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
18
+ }>, ComposioConnectToolDetails>;
19
+ export {};
@@ -0,0 +1,25 @@
1
+ import type { AgentTool } from "../../types.js";
2
+ import type { ComposioToolFactoryOptions, ComposioToolMetadata } from "./types.js";
3
+ declare const composioEnableSchema: import("@sinclair/typebox").TObject<{
4
+ toolkits: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
5
+ toolSlugs: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
6
+ authConfigs: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TRecord<import("@sinclair/typebox").TString, import("@sinclair/typebox").TString>>;
7
+ connectedAccounts: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TRecord<import("@sinclair/typebox").TString, import("@sinclair/typebox").TString>>;
8
+ authConfigId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
9
+ connectedAccountId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
10
+ }>;
11
+ export interface ComposioEnableToolDetails {
12
+ userId: string;
13
+ enabledTools: ComposioToolMetadata[];
14
+ activationApplied: boolean;
15
+ }
16
+ export declare function createComposioEnableTool(options?: ComposioToolFactoryOptions): AgentTool<typeof composioEnableSchema, ComposioEnableToolDetails>;
17
+ export declare const composioEnableTool: AgentTool<import("@sinclair/typebox").TObject<{
18
+ toolkits: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
19
+ toolSlugs: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
20
+ authConfigs: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TRecord<import("@sinclair/typebox").TString, import("@sinclair/typebox").TString>>;
21
+ connectedAccounts: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TRecord<import("@sinclair/typebox").TString, import("@sinclair/typebox").TString>>;
22
+ authConfigId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
23
+ connectedAccountId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
24
+ }>, ComposioEnableToolDetails>;
25
+ export {};
@@ -0,0 +1,26 @@
1
+ import type { AgentTool } from "../../types.js";
2
+ import type { ComposioExecuteResult, ComposioToolFactoryOptions } from "./types.js";
3
+ declare const composioExecuteSchema: import("@sinclair/typebox").TObject<{
4
+ toolSlug: import("@sinclair/typebox").TString;
5
+ arguments: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TRecord<import("@sinclair/typebox").TString, import("@sinclair/typebox").TUnknown>>;
6
+ toolkits: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
7
+ authConfigs: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TRecord<import("@sinclair/typebox").TString, import("@sinclair/typebox").TString>>;
8
+ connectedAccounts: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TRecord<import("@sinclair/typebox").TString, import("@sinclair/typebox").TString>>;
9
+ authConfigId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
10
+ connectedAccountId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
11
+ }>;
12
+ export interface ComposioExecuteToolDetails extends ComposioExecuteResult {
13
+ userId: string;
14
+ toolSlug: string;
15
+ }
16
+ export declare function createComposioExecuteTool(options?: ComposioToolFactoryOptions): AgentTool<typeof composioExecuteSchema, ComposioExecuteToolDetails>;
17
+ export declare const composioExecuteTool: AgentTool<import("@sinclair/typebox").TObject<{
18
+ toolSlug: import("@sinclair/typebox").TString;
19
+ arguments: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TRecord<import("@sinclair/typebox").TString, import("@sinclair/typebox").TUnknown>>;
20
+ toolkits: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TArray<import("@sinclair/typebox").TString>>;
21
+ authConfigs: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TRecord<import("@sinclair/typebox").TString, import("@sinclair/typebox").TString>>;
22
+ connectedAccounts: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TRecord<import("@sinclair/typebox").TString, import("@sinclair/typebox").TString>>;
23
+ authConfigId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
24
+ connectedAccountId: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
25
+ }>, ComposioExecuteToolDetails>;
26
+ export {};
@@ -0,0 +1,16 @@
1
+ import type { ConnectedAccountListResponse, Tool as ComposioRawTool, ToolRouterSessionSearchResponse, ToolkitConnectionsDetails } from "@composio/core";
2
+ import type { ComposioConnectResult, ComposioExecuteResult, ComposioToolMetadata } from "./types.js";
3
+ export declare const DEFAULT_COMPOSIO_USER_ID = "default";
4
+ export declare function buildComposioToolName(slug: string): string;
5
+ export declare function buildComposioToolDescription(tool: ComposioRawTool): string;
6
+ export declare function extractToolMetadata(tool: Pick<ComposioRawTool, "slug" | "name" | "toolkit" | "isNoAuth" | "version">): ComposioToolMetadata;
7
+ export declare function safeJsonStringify(value: unknown): string;
8
+ export declare function formatExecutionPayload(data: unknown, fallback?: string): string;
9
+ export declare function formatExecuteResult(result: ComposioExecuteResult): string;
10
+ export declare function formatToolkitList(toolkits: ToolkitConnectionsDetails): string;
11
+ export declare function formatRawToolList(items: ComposioRawTool[]): string;
12
+ export declare function formatSearchResults(result: ToolRouterSessionSearchResponse): string;
13
+ export declare function formatConnectedAccounts(accounts: ConnectedAccountListResponse): string;
14
+ export declare function formatConnectResult(result: ComposioConnectResult): string;
15
+ export declare function stableStringify(value: unknown): string;
16
+ export declare function uniqueStrings(values: readonly string[] | undefined): string[];
@@ -0,0 +1,9 @@
1
+ export { ComposioService, createComposioAgentTools } from "./client.js";
2
+ export { IndusagiComposioProvider } from "./provider.js";
3
+ export { createComposioToolkitsTool, composioToolkitsTool, type ComposioToolkitsToolDetails, } from "./toolkits.js";
4
+ export { createComposioToolsTool, composioToolsTool, type ComposioToolsToolDetails, } from "./tools.js";
5
+ export { createComposioConnectTool, composioConnectTool, type ComposioConnectToolDetails, } from "./connect.js";
6
+ export { createComposioExecuteTool, composioExecuteTool, type ComposioExecuteToolDetails, } from "./execute.js";
7
+ export { createComposioEnableTool, composioEnableTool, type ComposioEnableToolDetails, } from "./enable.js";
8
+ export { createComposioAccountsTool, composioAccountsTool, type ComposioAccountsToolDetails, } from "./accounts.js";
9
+ export type { ComposioAgentTool, ComposioAgentToolsOptions, ComposioBaseOptions, ComposioClientFactory, ComposioConnectResult, ComposioEnableHandler, ComposioExecuteResult, ComposioServiceLike, ComposioToolExecutionDetails, ComposioToolFactoryOptions, ComposioToolListResult, ComposioToolMetadata, ComposioToolSelection, } from "./types.js";
@@ -0,0 +1,8 @@
1
+ import type { Tool as ComposioRawTool, ToolExecuteResponse } from "@composio/core";
2
+ import { BaseAgenticProvider } from "@composio/core";
3
+ import type { ComposioAgentTool } from "./types.js";
4
+ export declare class IndusagiComposioProvider extends BaseAgenticProvider<ComposioAgentTool[], ComposioAgentTool, unknown> {
5
+ readonly name = "indusagi-framework";
6
+ wrapTool(tool: ComposioRawTool, executeTool: (toolSlug: string, input: Record<string, unknown>) => Promise<ToolExecuteResponse>): ComposioAgentTool;
7
+ wrapTools(tools: ComposioRawTool[], executeTool: (toolSlug: string, input: Record<string, unknown>) => Promise<ToolExecuteResponse>): ComposioAgentTool[];
8
+ }