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.
- package/dist/agent.js +28713 -0
- package/dist/ai.js +19964 -0
- package/dist/capabilities.js +2730 -0
- package/dist/cli.js +9 -0
- package/dist/connectors-saas.js +3355 -0
- package/dist/index.js +18211 -0
- package/dist/interop.js +3247 -0
- package/dist/llmgateway.js +3343 -0
- package/dist/mcp.js +2448 -0
- package/dist/memory.js +0 -0
- package/dist/react-host/index.js +101 -0
- package/dist/react-host/ink.js +97 -0
- package/dist/react-host/jsx-runtime.js +95 -0
- package/dist/react-ink.js +3834 -0
- package/dist/runtime.js +4521 -0
- package/dist/sarvam-mcp.js +960 -0
- package/dist/shell-app.js +12435 -0
- package/dist/smithy.js +8133 -0
- package/dist/swarm.js +8918 -0
- package/dist/tracing.js +761 -0
- package/dist/tui.js +2213 -0
- package/dist/types/capabilities/backends/index.d.ts +10 -0
- package/dist/types/capabilities/backends/node-backends.d.ts +30 -0
- package/dist/types/capabilities/capabilities.test.d.ts +14 -0
- package/dist/types/capabilities/files/diff.d.ts +49 -0
- package/dist/types/capabilities/files/edit.d.ts +21 -0
- package/dist/types/capabilities/files/ls.d.ts +16 -0
- package/dist/types/capabilities/files/read-state-gate.d.ts +69 -0
- package/dist/types/capabilities/files/read-state-gate.test.d.ts +14 -0
- package/dist/types/capabilities/files/read.d.ts +15 -0
- package/dist/types/capabilities/files/write.d.ts +16 -0
- package/dist/types/capabilities/index.d.ts +29 -0
- package/dist/types/capabilities/kernel/backends.d.ts +119 -0
- package/dist/types/capabilities/kernel/context.d.ts +52 -0
- package/dist/types/capabilities/kernel/index.d.ts +24 -0
- package/dist/types/capabilities/kernel/output.d.ts +40 -0
- package/dist/types/capabilities/kernel/registry.d.ts +61 -0
- package/dist/types/capabilities/kernel/spec.d.ts +168 -0
- package/dist/types/capabilities/planning/todo.d.ts +62 -0
- package/dist/types/capabilities/registry.d.ts +44 -0
- package/dist/types/capabilities/search/find.d.ts +33 -0
- package/dist/types/capabilities/search/grep.d.ts +30 -0
- package/dist/types/capabilities/shell/bash.d.ts +18 -0
- package/dist/types/capabilities/shell/process.d.ts +33 -0
- package/dist/types/capabilities/web/webfetch.d.ts +25 -0
- package/dist/types/capabilities/web/websearch.d.ts +23 -0
- package/dist/types/connectors-saas/connectors-saas.test.d.ts +12 -0
- package/dist/types/connectors-saas/index.d.ts +16 -0
- package/dist/types/connectors-saas/saas/adapter/composio-backend.d.ts +60 -0
- package/dist/types/connectors-saas/saas/control/connect.d.ts +114 -0
- package/dist/types/connectors-saas/saas/control/tools.d.ts +67 -0
- package/dist/types/connectors-saas/saas/core/builder.d.ts +86 -0
- package/dist/types/connectors-saas/saas/core/cache.d.ts +53 -0
- package/dist/types/connectors-saas/saas/core/index.d.ts +14 -0
- package/dist/types/connectors-saas/saas/core/port.d.ts +157 -0
- package/dist/types/connectors-saas/saas/core/scope-planner.d.ts +74 -0
- package/dist/types/connectors-saas/saas/gateway.d.ts +133 -0
- package/dist/types/connectors-saas/saas/render/format.d.ts +54 -0
- package/dist/types/connectors-saas/saas/render/index.d.ts +19 -0
- package/dist/types/connectors-saas/saas/render/summarizers.d.ts +58 -0
- package/dist/types/connectors-sarvam/connect.d.ts +14 -0
- package/dist/types/connectors-sarvam/connectors-sarvam.test.d.ts +14 -0
- package/dist/types/connectors-sarvam/index.d.ts +14 -0
- package/dist/types/connectors-sarvam/toolbox.d.ts +19 -0
- package/dist/types/connectors-sarvam/types.d.ts +49 -0
- package/dist/types/connectors-zoho/connect.d.ts +22 -0
- package/dist/types/connectors-zoho/connectors-zoho.test.d.ts +10 -0
- package/dist/types/connectors-zoho/index.d.ts +13 -0
- package/dist/types/connectors-zoho/toolbox.d.ts +19 -0
- package/dist/types/connectors-zoho/types.d.ts +56 -0
- package/dist/types/facade/agent.d.ts +1 -0
- package/dist/types/facade/ai.d.ts +1 -0
- package/dist/types/facade/bot/actions/bash.d.ts +71 -0
- package/dist/types/facade/bot/actions/bash.test.d.ts +1 -0
- package/dist/types/facade/bot/actions/checkpoint.d.ts +49 -0
- package/dist/types/facade/bot/actions/checkpoint.test.d.ts +1 -0
- package/dist/types/facade/bot/actions/composio/accounts.d.ts +22 -0
- package/dist/types/facade/bot/actions/composio/client.d.ts +39 -0
- package/dist/types/facade/bot/actions/composio/connect.d.ts +19 -0
- package/dist/types/facade/bot/actions/composio/enable.d.ts +25 -0
- package/dist/types/facade/bot/actions/composio/execute.d.ts +26 -0
- package/dist/types/facade/bot/actions/composio/helpers.d.ts +16 -0
- package/dist/types/facade/bot/actions/composio/index.d.ts +9 -0
- package/dist/types/facade/bot/actions/composio/provider.d.ts +8 -0
- package/dist/types/facade/bot/actions/composio/toolkits.d.ts +22 -0
- package/dist/types/facade/bot/actions/composio/tools.d.ts +28 -0
- package/dist/types/facade/bot/actions/composio/types.d.ts +137 -0
- package/dist/types/facade/bot/actions/crew/activity-tracker.d.ts +65 -0
- package/dist/types/facade/bot/actions/crew/cleanup.d.ts +50 -0
- package/dist/types/facade/bot/actions/crew/fs-lock.d.ts +11 -0
- package/dist/types/facade/bot/actions/crew/index.d.ts +11 -0
- package/dist/types/facade/bot/actions/crew/mailbox.d.ts +20 -0
- package/dist/types/facade/bot/actions/crew/model-policy.d.ts +22 -0
- package/dist/types/facade/bot/actions/crew/names.d.ts +27 -0
- package/dist/types/facade/bot/actions/crew/protocol.d.ts +74 -0
- package/dist/types/facade/bot/actions/crew/task-store.d.ts +88 -0
- package/dist/types/facade/bot/actions/crew/team-attach-claim.d.ts +35 -0
- package/dist/types/facade/bot/actions/crew/team-config.d.ts +54 -0
- package/dist/types/facade/bot/actions/crew/worktree.d.ts +39 -0
- package/dist/types/facade/bot/actions/edit-diff.d.ts +66 -0
- package/dist/types/facade/bot/actions/edit-utils.d.ts +86 -0
- package/dist/types/facade/bot/actions/edit.d.ts +59 -0
- package/dist/types/facade/bot/actions/edit.test.d.ts +1 -0
- package/dist/types/facade/bot/actions/find.d.ts +27 -0
- package/dist/types/facade/bot/actions/find.test.d.ts +1 -0
- package/dist/types/facade/bot/actions/grep.d.ts +53 -0
- package/dist/types/facade/bot/actions/grep.test.d.ts +1 -0
- package/dist/types/facade/bot/actions/index.d.ts +316 -0
- package/dist/types/facade/bot/actions/kit/hook-runner.d.ts +12 -0
- package/dist/types/facade/bot/actions/kit/image-resize.d.ts +19 -0
- package/dist/types/facade/bot/actions/kit/mime.d.ts +1 -0
- package/dist/types/facade/bot/actions/kit/shell.d.ts +12 -0
- package/dist/types/facade/bot/actions/ls.d.ts +41 -0
- package/dist/types/facade/bot/actions/path-utils.d.ts +8 -0
- package/dist/types/facade/bot/actions/process-controller.d.ts +14 -0
- package/dist/types/facade/bot/actions/process-manager.d.ts +59 -0
- package/dist/types/facade/bot/actions/process-types.d.ts +73 -0
- package/dist/types/facade/bot/actions/process.d.ts +37 -0
- package/dist/types/facade/bot/actions/read-state.d.ts +83 -0
- package/dist/types/facade/bot/actions/read-state.test.d.ts +1 -0
- package/dist/types/facade/bot/actions/read.d.ts +43 -0
- package/dist/types/facade/bot/actions/read.test.d.ts +1 -0
- package/dist/types/facade/bot/actions/registry.d.ts +20 -0
- package/dist/types/facade/bot/actions/sandbox-backend.d.ts +99 -0
- package/dist/types/facade/bot/actions/sandbox-backend.test.d.ts +1 -0
- package/dist/types/facade/bot/actions/todo-store.d.ts +76 -0
- package/dist/types/facade/bot/actions/todo-types.d.ts +72 -0
- package/dist/types/facade/bot/actions/todo.d.ts +76 -0
- package/dist/types/facade/bot/actions/truncate.d.ts +78 -0
- package/dist/types/facade/bot/actions/webfetch.d.ts +35 -0
- package/dist/types/facade/bot/actions/websearch.d.ts +37 -0
- package/dist/types/facade/bot/actions/websearch.test.d.ts +1 -0
- package/dist/types/facade/bot/actions/write.d.ts +45 -0
- package/dist/types/facade/bot/agent-loop.d.ts +30 -0
- package/dist/types/facade/bot/agent-loop.test.d.ts +1 -0
- package/dist/types/facade/bot/agent.d.ts +140 -0
- package/dist/types/facade/bot/error-handler.d.ts +7 -0
- package/dist/types/facade/bot/event-bus.d.ts +8 -0
- package/dist/types/facade/bot/index.d.ts +7 -0
- package/dist/types/facade/bot/messages.d.ts +83 -0
- package/dist/types/facade/bot/permission-gate.test.d.ts +1 -0
- package/dist/types/facade/bot/proxy.d.ts +70 -0
- package/dist/types/facade/bot/session-manager.d.ts +409 -0
- package/dist/types/facade/bot/state-manager.d.ts +21 -0
- package/dist/types/facade/bot/telemetry.d.ts +6 -0
- package/dist/types/facade/bot/types.d.ts +267 -0
- package/dist/types/facade/mcp-core/client-pool.d.ts +105 -0
- package/dist/types/facade/mcp-core/client.d.ts +245 -0
- package/dist/types/facade/mcp-core/client.test.d.ts +18 -0
- package/dist/types/facade/mcp-core/config.d.ts +60 -0
- package/dist/types/facade/mcp-core/errors.d.ts +103 -0
- package/dist/types/facade/mcp-core/index.d.ts +59 -0
- package/dist/types/facade/mcp-core/oauth/flow.d.ts +72 -0
- package/dist/types/facade/mcp-core/oauth/index.d.ts +18 -0
- package/dist/types/facade/mcp-core/oauth/oauth.test.d.ts +8 -0
- package/dist/types/facade/mcp-core/oauth/provider.d.ts +51 -0
- package/dist/types/facade/mcp-core/oauth/token-store.d.ts +31 -0
- package/dist/types/facade/mcp-core/oauth/types.d.ts +96 -0
- package/dist/types/facade/mcp-core/schema-converter.d.ts +67 -0
- package/dist/types/facade/mcp-core/server.d.ts +110 -0
- package/dist/types/facade/mcp-core/tool-factory.d.ts +62 -0
- package/dist/types/facade/mcp-core/toolbox-bridge.d.ts +46 -0
- package/dist/types/facade/mcp-core/toolbox-bridge.test.d.ts +8 -0
- package/dist/types/facade/mcp-core/types.d.ts +298 -0
- package/dist/types/facade/mcp.d.ts +1 -0
- package/dist/types/facade/memory.d.ts +1 -0
- package/dist/types/facade/ml/adapters/amazon-bedrock.d.ts +32 -0
- package/dist/types/facade/ml/adapters/anthropic-retry.test.d.ts +1 -0
- package/dist/types/facade/ml/adapters/anthropic.d.ts +78 -0
- package/dist/types/facade/ml/adapters/azure-openai-responses.d.ts +14 -0
- package/dist/types/facade/ml/adapters/google-shared.d.ts +99 -0
- package/dist/types/facade/ml/adapters/google-vertex.d.ts +14 -0
- package/dist/types/facade/ml/adapters/google.d.ts +15 -0
- package/dist/types/facade/ml/adapters/kimi.d.ts +21 -0
- package/dist/types/facade/ml/adapters/mock.d.ts +9 -0
- package/dist/types/facade/ml/adapters/nvidia.d.ts +12 -0
- package/dist/types/facade/ml/adapters/openai-codex-responses.d.ts +8 -0
- package/dist/types/facade/ml/adapters/openai-completions.d.ts +24 -0
- package/dist/types/facade/ml/adapters/openai-responses-shared.d.ts +25 -0
- package/dist/types/facade/ml/adapters/openai-responses.d.ts +12 -0
- package/dist/types/facade/ml/adapters/openai-scaffold.d.ts +3 -0
- package/dist/types/facade/ml/adapters/register-builtins.d.ts +2 -0
- package/dist/types/facade/ml/adapters/simple-options.d.ts +39 -0
- package/dist/types/facade/ml/adapters/simple-options.test.d.ts +1 -0
- package/dist/types/facade/ml/adapters/transform-messages.d.ts +23 -0
- package/dist/types/facade/ml/api-registry.d.ts +49 -0
- package/dist/types/facade/ml/cli.d.ts +2 -0
- package/dist/types/facade/ml/env-api-keys.d.ts +19 -0
- package/dist/types/facade/ml/index.d.ts +27 -0
- package/dist/types/facade/ml/kit/auth/anthropic.d.ts +17 -0
- package/dist/types/facade/ml/kit/auth/github-copilot.d.ts +22 -0
- package/dist/types/facade/ml/kit/auth/index.d.ts +50 -0
- package/dist/types/facade/ml/kit/auth/kimi.d.ts +23 -0
- package/dist/types/facade/ml/kit/auth/oauth-page.d.ts +2 -0
- package/dist/types/facade/ml/kit/auth/openai-codex.d.ts +36 -0
- package/dist/types/facade/ml/kit/auth/pkce.d.ts +12 -0
- package/dist/types/facade/ml/kit/auth/types.d.ts +67 -0
- package/dist/types/facade/ml/kit/base-stream-handler.d.ts +30 -0
- package/dist/types/facade/ml/kit/event-stream.d.ts +63 -0
- package/dist/types/facade/ml/kit/index.d.ts +14 -0
- package/dist/types/facade/ml/kit/json-parse.d.ts +23 -0
- package/dist/types/facade/ml/kit/message-transform.d.ts +32 -0
- package/dist/types/facade/ml/kit/output-factory.d.ts +8 -0
- package/dist/types/facade/ml/kit/overflow.d.ts +9 -0
- package/dist/types/facade/ml/kit/provider-adapter.d.ts +56 -0
- package/dist/types/facade/ml/kit/provider-client-builder.d.ts +36 -0
- package/dist/types/facade/ml/kit/provider-consolidation.d.ts +3 -0
- package/dist/types/facade/ml/kit/provider-constants.d.ts +34 -0
- package/dist/types/facade/ml/kit/provider-errors.d.ts +52 -0
- package/dist/types/facade/ml/kit/sanitize-unicode.d.ts +2 -0
- package/dist/types/facade/ml/kit/stream-event-helper.d.ts +38 -0
- package/dist/types/facade/ml/kit/stream-handler-types.d.ts +46 -0
- package/dist/types/facade/ml/kit/streaming-state-manager.d.ts +42 -0
- package/dist/types/facade/ml/kit/tool-converter.d.ts +49 -0
- package/dist/types/facade/ml/kit/typebox-helpers.d.ts +24 -0
- package/dist/types/facade/ml/kit/validation.d.ts +26 -0
- package/dist/types/facade/ml/models.d.ts +41 -0
- package/dist/types/facade/ml/models.generated.d.ts +12405 -0
- package/dist/types/facade/ml/stream.d.ts +27 -0
- package/dist/types/facade/ml/types.d.ts +269 -0
- package/dist/types/index.d.ts +18 -0
- package/dist/types/interop/index.d.ts +12 -0
- package/dist/types/interop/interop.test.d.ts +19 -0
- package/dist/types/interop/protocol-bridge/bridge.d.ts +52 -0
- package/dist/types/interop/protocol-bridge/contract.d.ts +249 -0
- package/dist/types/interop/protocol-bridge/endpoint.d.ts +124 -0
- package/dist/types/interop/protocol-bridge/fleet.d.ts +92 -0
- package/dist/types/interop/protocol-bridge/host.d.ts +61 -0
- package/dist/types/interop/protocol-bridge/index.d.ts +16 -0
- package/dist/types/interop/protocol-bridge/schema.d.ts +29 -0
- package/dist/types/llmgateway/catalog/cards.d.ts +18 -0
- package/dist/types/llmgateway/catalog/cost.d.ts +15 -0
- package/dist/types/llmgateway/catalog/index.d.ts +7 -0
- package/dist/types/llmgateway/catalog/query.d.ts +40 -0
- package/dist/types/llmgateway/connectors/anthropic.d.ts +35 -0
- package/dist/types/llmgateway/connectors/azure-openai.d.ts +33 -0
- package/dist/types/llmgateway/connectors/bedrock.d.ts +113 -0
- package/dist/types/llmgateway/connectors/google-vertex.d.ts +38 -0
- package/dist/types/llmgateway/connectors/google.d.ts +40 -0
- package/dist/types/llmgateway/connectors/index.d.ts +26 -0
- package/dist/types/llmgateway/connectors/kimi.d.ts +28 -0
- package/dist/types/llmgateway/connectors/mock.d.ts +37 -0
- package/dist/types/llmgateway/connectors/nvidia.d.ts +27 -0
- package/dist/types/llmgateway/connectors/ollama.d.ts +45 -0
- package/dist/types/llmgateway/connectors/openai-chat.d.ts +25 -0
- package/dist/types/llmgateway/connectors/openai-responses.d.ts +49 -0
- package/dist/types/llmgateway/contract/connector.d.ts +32 -0
- package/dist/types/llmgateway/contract/conversation.d.ts +86 -0
- package/dist/types/llmgateway/contract/emission.d.ts +55 -0
- package/dist/types/llmgateway/contract/errors.d.ts +27 -0
- package/dist/types/llmgateway/contract/index.d.ts +13 -0
- package/dist/types/llmgateway/contract/model-card.d.ts +42 -0
- package/dist/types/llmgateway/contract/options.d.ts +31 -0
- package/dist/types/llmgateway/contract/reply.d.ts +33 -0
- package/dist/types/llmgateway/conversion/index.d.ts +10 -0
- package/dist/types/llmgateway/conversion/mappers.d.ts +65 -0
- package/dist/types/llmgateway/conversion/openai-compatible.d.ts +46 -0
- package/dist/types/llmgateway/conversion/reduce.d.ts +20 -0
- package/dist/types/llmgateway/credentials/oauth.d.ts +73 -0
- package/dist/types/llmgateway/credentials/pkce.d.ts +52 -0
- package/dist/types/llmgateway/credentials/secrets.d.ts +76 -0
- package/dist/types/llmgateway/gateway.d.ts +34 -0
- package/dist/types/llmgateway/gateway.test.d.ts +14 -0
- package/dist/types/llmgateway/index.d.ts +11 -0
- package/dist/types/llmgateway/streaming/channel.d.ts +24 -0
- package/dist/types/llmgateway/streaming/index.d.ts +10 -0
- package/dist/types/llmgateway/streaming/ndjson.d.ts +17 -0
- package/dist/types/llmgateway/streaming/sse.d.ts +31 -0
- package/dist/types/react-host/index.d.ts +9 -0
- package/dist/types/react-host/ink.d.ts +5 -0
- package/dist/types/react-host/jsx-runtime.d.ts +4 -0
- package/dist/types/react-host/loader.d.ts +3 -0
- package/dist/types/react-ink/components/ChangelogBlock.d.ts +8 -0
- package/dist/types/react-ink/components/DisplayBlockView.d.ts +8 -0
- package/dist/types/react-ink/components/Footer.d.ts +11 -0
- package/dist/types/react-ink/components/MessageList.d.ts +14 -0
- package/dist/types/react-ink/components/MessageRow.d.ts +13 -0
- package/dist/types/react-ink/components/StatusLine.d.ts +18 -0
- package/dist/types/react-ink/components/TaskPanel.d.ts +11 -0
- package/dist/types/react-ink/components/ToolEventBlock.d.ts +48 -0
- package/dist/types/react-ink/components/ToolEventBlock.test.d.ts +1 -0
- package/dist/types/react-ink/components/dialogs/DialogFrame.d.ts +8 -0
- package/dist/types/react-ink/components/dialogs/LoginDialog.d.ts +14 -0
- package/dist/types/react-ink/components/dialogs/ModelDialog.d.ts +9 -0
- package/dist/types/react-ink/components/dialogs/OAuthDialog.d.ts +9 -0
- package/dist/types/react-ink/components/dialogs/ScopedModelsDialog.d.ts +9 -0
- package/dist/types/react-ink/components/dialogs/SelectableDialog.d.ts +22 -0
- package/dist/types/react-ink/components/dialogs/SessionDialog.d.ts +13 -0
- package/dist/types/react-ink/components/dialogs/SettingsDialog.d.ts +14 -0
- package/dist/types/react-ink/components/dialogs/StartupSessionPicker.d.ts +9 -0
- package/dist/types/react-ink/components/dialogs/ThemeDialog.d.ts +26 -0
- package/dist/types/react-ink/components/dialogs/TreeDialog.d.ts +8 -0
- package/dist/types/react-ink/components/dialogs/UserMessageDialog.d.ts +8 -0
- package/dist/types/react-ink/components/messages/AssistantMessage.d.ts +12 -0
- package/dist/types/react-ink/components/messages/BashMessage.d.ts +8 -0
- package/dist/types/react-ink/components/messages/BranchSummaryMessage.d.ts +8 -0
- package/dist/types/react-ink/components/messages/CompactionMessage.d.ts +8 -0
- package/dist/types/react-ink/components/messages/CustomMessage.d.ts +9 -0
- package/dist/types/react-ink/components/messages/SkillInvocationMessage.d.ts +7 -0
- package/dist/types/react-ink/components/messages/ToolCallMessage.d.ts +8 -0
- package/dist/types/react-ink/components/messages/ToolResultBlock.d.ts +12 -0
- package/dist/types/react-ink/components/messages/UserMessage.d.ts +9 -0
- package/dist/types/react-ink/diff/Diff.d.ts +22 -0
- package/dist/types/react-ink/diff/diff.test.d.ts +1 -0
- package/dist/types/react-ink/diff/structured.d.ts +41 -0
- package/dist/types/react-ink/diff/word-diff.d.ts +27 -0
- package/dist/types/react-ink/index.d.ts +42 -0
- package/dist/types/react-ink/markdown/Markdown.d.ts +23 -0
- package/dist/types/react-ink/markdown/MarkdownTable.d.ts +19 -0
- package/dist/types/react-ink/markdown/StreamingMarkdown.d.ts +34 -0
- package/dist/types/react-ink/markdown/format-token.d.ts +39 -0
- package/dist/types/react-ink/markdown/highlight.d.ts +31 -0
- package/dist/types/react-ink/theme-adapter.d.ts +66 -0
- package/dist/types/react-ink/types.d.ts +133 -0
- package/dist/types/react-ink/utils/message-groups.d.ts +25 -0
- package/dist/types/react-ink/utils/selection-dialog.d.ts +2 -0
- package/dist/types/react-ink/utils/session-browser.d.ts +27 -0
- package/dist/types/react-ink/utils/tool-display.d.ts +37 -0
- package/dist/types/runtime/cadence/cadence.test.d.ts +6 -0
- package/dist/types/runtime/cadence/fold.d.ts +48 -0
- package/dist/types/runtime/cadence/index.d.ts +12 -0
- package/dist/types/runtime/cadence/reducer.d.ts +44 -0
- package/dist/types/runtime/conductor/agent.d.ts +71 -0
- package/dist/types/runtime/conductor/index.d.ts +11 -0
- package/dist/types/runtime/contract/config.d.ts +44 -0
- package/dist/types/runtime/contract/effect.d.ts +41 -0
- package/dist/types/runtime/contract/errors.d.ts +22 -0
- package/dist/types/runtime/contract/events.d.ts +63 -0
- package/dist/types/runtime/contract/index.d.ts +18 -0
- package/dist/types/runtime/contract/run-state.d.ts +57 -0
- package/dist/types/runtime/contract/session.d.ts +42 -0
- package/dist/types/runtime/contract/signal.d.ts +49 -0
- package/dist/types/runtime/contract/tools.d.ts +45 -0
- package/dist/types/runtime/dispatch/index.d.ts +9 -0
- package/dist/types/runtime/dispatch/scheduler.d.ts +53 -0
- package/dist/types/runtime/index.d.ts +22 -0
- package/dist/types/runtime/ledger/accumulator.d.ts +44 -0
- package/dist/types/runtime/ledger/bus.d.ts +50 -0
- package/dist/types/runtime/ledger/index.d.ts +11 -0
- package/dist/types/runtime/memory/compactor.d.ts +56 -0
- package/dist/types/runtime/memory/estimate.d.ts +21 -0
- package/dist/types/runtime/memory/index.d.ts +8 -0
- package/dist/types/runtime/runtime.test.d.ts +15 -0
- package/dist/types/runtime/store/dag.d.ts +72 -0
- package/dist/types/runtime/store/hash.d.ts +18 -0
- package/dist/types/runtime/store/index.d.ts +12 -0
- package/dist/types/runtime/store/persist.d.ts +49 -0
- package/dist/types/runtime/turn/driver.d.ts +32 -0
- package/dist/types/runtime/turn/index.d.ts +8 -0
- package/dist/types/runtime/wire/index.d.ts +10 -0
- package/dist/types/runtime/wire/projectors.d.ts +53 -0
- package/dist/types/shell-app/auth-cli/index.d.ts +9 -0
- package/dist/types/shell-app/auth-cli/oauth-cli.d.ts +73 -0
- package/dist/types/shell-app/boot/context.d.ts +108 -0
- package/dist/types/shell-app/boot/index.d.ts +13 -0
- package/dist/types/shell-app/boot/pipeline.d.ts +66 -0
- package/dist/types/shell-app/boot/stages.d.ts +77 -0
- package/dist/types/shell-app/cli.d.ts +75 -0
- package/dist/types/shell-app/config/index.d.ts +11 -0
- package/dist/types/shell-app/config/locator.d.ts +85 -0
- package/dist/types/shell-app/config/settings.d.ts +91 -0
- package/dist/types/shell-app/index.d.ts +26 -0
- package/dist/types/shell-app/invocation/flags.d.ts +89 -0
- package/dist/types/shell-app/invocation/parse.d.ts +89 -0
- package/dist/types/shell-app/locate/brand.d.ts +71 -0
- package/dist/types/shell-app/locate/index.d.ts +12 -0
- package/dist/types/shell-app/locate/locator.d.ts +122 -0
- package/dist/types/shell-app/runners/contract.d.ts +116 -0
- package/dist/types/shell-app/runners/index.d.ts +15 -0
- package/dist/types/shell-app/runners/one-shot.d.ts +21 -0
- package/dist/types/shell-app/runners/registry.d.ts +34 -0
- package/dist/types/shell-app/runners/repl.d.ts +51 -0
- package/dist/types/shell-app/runners/wire.d.ts +34 -0
- package/dist/types/shell-app/shell-app.test.d.ts +14 -0
- package/dist/types/shell-app/upgrade/index.d.ts +9 -0
- package/dist/types/shell-app/upgrade/upgrades.d.ts +62 -0
- package/dist/types/smithy/config/flag-reader.d.ts +128 -0
- package/dist/types/smithy/config/index.d.ts +9 -0
- package/dist/types/smithy/forge.d.ts +135 -0
- package/dist/types/smithy/index.d.ts +36 -0
- package/dist/types/smithy/knowledge/index.d.ts +10 -0
- package/dist/types/smithy/knowledge/loader.d.ts +64 -0
- package/dist/types/smithy/persona/blueprint.d.ts +75 -0
- package/dist/types/smithy/persona/define-agent.d.ts +51 -0
- package/dist/types/smithy/persona/index.d.ts +14 -0
- package/dist/types/smithy/persona/profiles.d.ts +44 -0
- package/dist/types/smithy/runtime/index.d.ts +9 -0
- package/dist/types/smithy/runtime/tool-ledger.d.ts +130 -0
- package/dist/types/smithy/smithy.test.d.ts +20 -0
- package/dist/types/smithy/ui/index.d.ts +11 -0
- package/dist/types/smithy/ui/transcript.d.ts +183 -0
- package/dist/types/swarm/coordinator.d.ts +192 -0
- package/dist/types/swarm/index.d.ts +33 -0
- package/dist/types/swarm/isolation/index.d.ts +14 -0
- package/dist/types/swarm/isolation/runner.d.ts +61 -0
- package/dist/types/swarm/isolation/worktree.d.ts +142 -0
- package/dist/types/swarm/kernel/faults.d.ts +52 -0
- package/dist/types/swarm/kernel/ids.d.ts +25 -0
- package/dist/types/swarm/kernel/index.d.ts +26 -0
- package/dist/types/swarm/kernel/json-cell.d.ts +113 -0
- package/dist/types/swarm/kernel/jsonl-log.d.ts +81 -0
- package/dist/types/swarm/postbox/channel.d.ts +88 -0
- package/dist/types/swarm/postbox/codecs.d.ts +253 -0
- package/dist/types/swarm/postbox/index.d.ts +16 -0
- package/dist/types/swarm/roster/index.d.ts +16 -0
- package/dist/types/swarm/roster/manifest.d.ts +185 -0
- package/dist/types/swarm/swarm.test.d.ts +24 -0
- package/dist/types/swarm/telemetry/activity.d.ts +143 -0
- package/dist/types/swarm/workboard/board.d.ts +174 -0
- package/dist/types/swarm/workboard/dep-graph.d.ts +77 -0
- package/dist/types/swarm/workboard/index.d.ts +12 -0
- package/dist/types/tracing/adapter/index.d.ts +12 -0
- package/dist/types/tracing/adapter/runtime-trace.d.ts +54 -0
- package/dist/types/tracing/channel/index.d.ts +9 -0
- package/dist/types/tracing/channel/signal.d.ts +93 -0
- package/dist/types/tracing/index.d.ts +25 -0
- package/dist/types/tracing/recorder/index.d.ts +12 -0
- package/dist/types/tracing/recorder/recorder.d.ts +75 -0
- package/dist/types/tracing/recorder/sampling.d.ts +55 -0
- package/dist/types/tracing/redaction/index.d.ts +8 -0
- package/dist/types/tracing/redaction/secret-scrubber.d.ts +95 -0
- package/dist/types/tracing/registry/hub.d.ts +57 -0
- package/dist/types/tracing/registry/index.d.ts +7 -0
- package/dist/types/tracing/signal/handle.d.ts +73 -0
- package/dist/types/tracing/signal/index.d.ts +12 -0
- package/dist/types/tracing/signal/segment.d.ts +124 -0
- package/dist/types/tracing/sinks/base.d.ts +51 -0
- package/dist/types/tracing/sinks/console.d.ts +44 -0
- package/dist/types/tracing/sinks/file.d.ts +47 -0
- package/dist/types/tracing/sinks/index.d.ts +16 -0
- package/dist/types/tracing/sinks/stream.d.ts +46 -0
- package/dist/types/tracing/tracing.test.d.ts +7 -0
- package/dist/types/ui/autocomplete.d.ts +59 -0
- package/dist/types/ui/contracts.d.ts +38 -0
- package/dist/types/ui/editor-component.d.ts +100 -0
- package/dist/types/ui/fuzzy.d.ts +29 -0
- package/dist/types/ui/index.d.ts +8 -0
- package/dist/types/ui/keybindings.d.ts +62 -0
- package/dist/types/ui/keys.d.ts +171 -0
- package/dist/types/ui/theme-types.d.ts +36 -0
- package/dist/types/ui/utils.d.ts +101 -0
- package/dist/types/ui-bridge/InteractiveApp.d.ts +38 -0
- package/dist/types/ui-bridge/adapter.d.ts +90 -0
- package/dist/types/ui-bridge/index.d.ts +37 -0
- package/dist/zoho.js +1451 -0
- package/package.json +48 -48
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import type { InkThemeAdapter } from "../theme-adapter.js";
|
|
2
|
+
type ToolEventStatus = "running" | "success" | "error";
|
|
3
|
+
interface ToolEventBlockProps {
|
|
4
|
+
title: string;
|
|
5
|
+
summary?: string;
|
|
6
|
+
detail?: string;
|
|
7
|
+
emptyText?: string;
|
|
8
|
+
status: ToolEventStatus;
|
|
9
|
+
theme: InkThemeAdapter;
|
|
10
|
+
indent?: number;
|
|
11
|
+
marginBottom?: number;
|
|
12
|
+
showTitle?: boolean;
|
|
13
|
+
showSummaryInline?: boolean;
|
|
14
|
+
maxContentLines?: number;
|
|
15
|
+
/**
|
|
16
|
+
* Appended to the "… N more line(s)" overflow marker (e.g. "ctrl+o to
|
|
17
|
+
* expand"), so the user can discover how to reveal the folded output. Omitted
|
|
18
|
+
* → the bare count is shown.
|
|
19
|
+
*/
|
|
20
|
+
moreHint?: string;
|
|
21
|
+
/**
|
|
22
|
+
* When true the detail body already carries syntax-highlight ANSI; render it
|
|
23
|
+
* verbatim instead of stripping the escapes. stripAnsi is still used for the
|
|
24
|
+
* visible-width / line-count measurements so wrapping and clamping stay
|
|
25
|
+
* correct against the escape-free text.
|
|
26
|
+
*/
|
|
27
|
+
preformatted?: boolean;
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* How many content lines a collapsed tool event shows before the rest is folded
|
|
31
|
+
* behind a "… N more line(s)" affordance. Kept deliberately small so a tool reads
|
|
32
|
+
* as a tight two-to-three-line block (the ● action header plus a summary line),
|
|
33
|
+
* not a multi-line output dump; expanding a tool lifts this cap. Callers that
|
|
34
|
+
* render tool bodies (ToolResultBlock, TaskPanel) share this so the collapsed
|
|
35
|
+
* height is consistent everywhere.
|
|
36
|
+
*/
|
|
37
|
+
export declare const COLLAPSED_CONTENT_LINES = 2;
|
|
38
|
+
/**
|
|
39
|
+
* How many content lines an *expanded* tool event shows (Ctrl+O). A bounded
|
|
40
|
+
* reveal — enough to actually read what a tool read/wrote/ran (10–20 lines)
|
|
41
|
+
* without flooding the transcript with a whole file; anything past it stays
|
|
42
|
+
* folded behind the "… N more" marker. Toggling Ctrl+O again collapses back to
|
|
43
|
+
* {@link COLLAPSED_CONTENT_LINES}.
|
|
44
|
+
*/
|
|
45
|
+
export declare const EXPANDED_CONTENT_LINES = 20;
|
|
46
|
+
export declare function statusColorKey(status: ToolEventStatus): string;
|
|
47
|
+
export declare function ToolEventBlock({ detail, emptyText, indent, marginBottom, maxContentLines, moreHint, preformatted, showSummaryInline, showTitle, status, summary, theme, title, }: ToolEventBlockProps): JSX.Element;
|
|
48
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { PropsWithChildren, ReactNode } from "indusagi/react-host";
|
|
2
|
+
interface DialogFrameProps extends PropsWithChildren {
|
|
3
|
+
title: string;
|
|
4
|
+
subtitle?: string;
|
|
5
|
+
footer?: ReactNode;
|
|
6
|
+
}
|
|
7
|
+
export declare function DialogFrame({ children, footer, subtitle, title }: DialogFrameProps): JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { LoginProviderOption, SavedAccountOption } from "../../types.js";
|
|
2
|
+
type LoginDialogProps = {
|
|
3
|
+
mode: "login";
|
|
4
|
+
providers: LoginProviderOption[];
|
|
5
|
+
onClose: () => void;
|
|
6
|
+
onSelect: (provider: LoginProviderOption) => void | Promise<void>;
|
|
7
|
+
} | {
|
|
8
|
+
mode: "logout";
|
|
9
|
+
accounts: SavedAccountOption[];
|
|
10
|
+
onClose: () => void;
|
|
11
|
+
onSelect: (account: SavedAccountOption) => void | Promise<void>;
|
|
12
|
+
};
|
|
13
|
+
export declare function LoginDialog(props: LoginDialogProps): JSX.Element;
|
|
14
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { Model } from "indusagi/ai";
|
|
2
|
+
interface ModelDialogProps {
|
|
3
|
+
models: Model<any>[];
|
|
4
|
+
search?: string;
|
|
5
|
+
onClose: () => void;
|
|
6
|
+
onSelect: (model: Model<any>) => void | Promise<void>;
|
|
7
|
+
}
|
|
8
|
+
export declare function ModelDialog({ models, onClose, onSelect, search }: ModelDialogProps): JSX.Element;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { OAuthOverlayState } from "../../types.js";
|
|
2
|
+
interface OAuthDialogProps {
|
|
3
|
+
state: OAuthOverlayState;
|
|
4
|
+
onClose: () => void;
|
|
5
|
+
onChange: (next: Partial<OAuthOverlayState>) => void;
|
|
6
|
+
onSubmit: () => void | Promise<void>;
|
|
7
|
+
}
|
|
8
|
+
export declare function OAuthDialog({ onChange, onClose, onSubmit, state }: OAuthDialogProps): JSX.Element;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { Model } from "indusagi/ai";
|
|
2
|
+
interface ScopedModelsDialogProps {
|
|
3
|
+
models: Model<any>[];
|
|
4
|
+
selectedIds: string[];
|
|
5
|
+
onClose: () => void;
|
|
6
|
+
onSave: (selectedIds: string[]) => void | Promise<void>;
|
|
7
|
+
}
|
|
8
|
+
export declare function ScopedModelsDialog({ models, onClose, onSave, selectedIds }: ScopedModelsDialogProps): JSX.Element;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { ReactNode } from "indusagi/react-host";
|
|
2
|
+
interface SelectableDialogProps<T> {
|
|
3
|
+
title: string;
|
|
4
|
+
subtitle?: string;
|
|
5
|
+
items: T[];
|
|
6
|
+
isActive?: boolean;
|
|
7
|
+
searchEnabled?: boolean;
|
|
8
|
+
emptyText: string;
|
|
9
|
+
noSearchResultsText?: string;
|
|
10
|
+
onClose: () => void;
|
|
11
|
+
onSelect: (item: T) => void | Promise<void>;
|
|
12
|
+
/**
|
|
13
|
+
* Fired whenever the highlighted item changes (including on first mount), so a
|
|
14
|
+
* caller can live-preview the currently-focused choice before it is committed
|
|
15
|
+
* with Enter. Distinct from {@link onSelect}, which fires only on Enter.
|
|
16
|
+
*/
|
|
17
|
+
onHighlight?: (item: T, index: number) => void;
|
|
18
|
+
getSearchText?: (item: T) => string;
|
|
19
|
+
renderItem: (item: T, selected: boolean, index: number) => ReactNode;
|
|
20
|
+
}
|
|
21
|
+
export declare function SelectableDialog<T>({ title, subtitle, items, isActive, searchEnabled, emptyText, noSearchResultsText, onClose, onSelect, onHighlight, getSearchText, renderItem, }: SelectableDialogProps<T>): JSX.Element;
|
|
22
|
+
export {};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { SessionInfo } from "../../types.js";
|
|
2
|
+
import { type SessionBrowserProgress } from "../../utils/session-browser.js";
|
|
3
|
+
interface SessionDialogProps {
|
|
4
|
+
currentSessions: SessionInfo[];
|
|
5
|
+
currentSessionPath?: string;
|
|
6
|
+
onClose: () => void;
|
|
7
|
+
onSelect: (session: SessionInfo) => void | Promise<void>;
|
|
8
|
+
onLoadAllSessions: (onProgress?: (progress: SessionBrowserProgress) => void) => Promise<SessionInfo[]>;
|
|
9
|
+
onDeleteSession?: (session: SessionInfo) => void | Promise<void>;
|
|
10
|
+
onRenameSession?: (session: SessionInfo, name: string) => void | Promise<void>;
|
|
11
|
+
}
|
|
12
|
+
export declare function SessionDialog({ currentSessionPath, currentSessions, onClose, onDeleteSession, onLoadAllSessions, onRenameSession, onSelect, }: SessionDialogProps): JSX.Element;
|
|
13
|
+
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export interface SettingsDialogItem {
|
|
2
|
+
id: string;
|
|
3
|
+
label: string;
|
|
4
|
+
description: string;
|
|
5
|
+
value: string;
|
|
6
|
+
values: string[];
|
|
7
|
+
onChange: (value: string) => void | Promise<void>;
|
|
8
|
+
}
|
|
9
|
+
interface SettingsDialogProps {
|
|
10
|
+
items: SettingsDialogItem[];
|
|
11
|
+
onClose: () => void;
|
|
12
|
+
}
|
|
13
|
+
export declare function SettingsDialog({ items, onClose }: SettingsDialogProps): JSX.Element;
|
|
14
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { SessionInfo } from "../../types.js";
|
|
2
|
+
interface StartupSessionPickerProps {
|
|
3
|
+
sessions: SessionInfo[];
|
|
4
|
+
totalCount: number;
|
|
5
|
+
onClose: () => void;
|
|
6
|
+
onSelect: (session: SessionInfo) => void | Promise<void>;
|
|
7
|
+
}
|
|
8
|
+
export declare function StartupSessionPicker({ onClose, onSelect, sessions, totalCount }: StartupSessionPickerProps): JSX.Element;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A single selectable scheme row. The `id` is the scheme token committed/
|
|
3
|
+
* previewed; `label` and `description` are the human-readable strings shown.
|
|
4
|
+
*/
|
|
5
|
+
export interface ThemeDialogItem {
|
|
6
|
+
id: string;
|
|
7
|
+
label: string;
|
|
8
|
+
description?: string;
|
|
9
|
+
}
|
|
10
|
+
interface ThemeDialogProps {
|
|
11
|
+
/**
|
|
12
|
+
* The schemes to offer. Either bare scheme tokens (label == token) or rich
|
|
13
|
+
* items carrying a friendly label + description.
|
|
14
|
+
*/
|
|
15
|
+
themes: Array<string | ThemeDialogItem>;
|
|
16
|
+
onClose: () => void;
|
|
17
|
+
/** Fired on Enter: the chosen scheme token. */
|
|
18
|
+
onSelect: (themeName: string) => void | Promise<void>;
|
|
19
|
+
/**
|
|
20
|
+
* Fired on every highlight move (and on mount): the focused scheme token, so
|
|
21
|
+
* the caller can live-preview a scheme before it is committed.
|
|
22
|
+
*/
|
|
23
|
+
onHighlight?: (themeName: string) => void;
|
|
24
|
+
}
|
|
25
|
+
export declare function ThemeDialog({ themes, onClose, onSelect, onHighlight }: ThemeDialogProps): JSX.Element;
|
|
26
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { SessionTreeOption } from "../../types.js";
|
|
2
|
+
interface TreeDialogProps {
|
|
3
|
+
items: SessionTreeOption[];
|
|
4
|
+
onClose: () => void;
|
|
5
|
+
onSelect: (item: SessionTreeOption) => void | Promise<void>;
|
|
6
|
+
}
|
|
7
|
+
export declare function TreeDialog({ items, onClose, onSelect }: TreeDialogProps): JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { UserMessageOption } from "../../types.js";
|
|
2
|
+
interface UserMessageDialogProps {
|
|
3
|
+
items: UserMessageOption[];
|
|
4
|
+
onClose: () => void;
|
|
5
|
+
onSelect: (item: UserMessageOption) => void | Promise<void>;
|
|
6
|
+
}
|
|
7
|
+
export declare function UserMessageDialog({ items, onClose, onSelect }: UserMessageDialogProps): JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { AssistantMessage, ToolResultMessage } from "indusagi/ai";
|
|
2
|
+
import type { InkThemeAdapter } from "../../theme-adapter.js";
|
|
3
|
+
interface AssistantMessageProps {
|
|
4
|
+
message: AssistantMessage;
|
|
5
|
+
showImages: boolean;
|
|
6
|
+
showThinking: boolean;
|
|
7
|
+
expandToolOutputs?: boolean;
|
|
8
|
+
theme: InkThemeAdapter;
|
|
9
|
+
toolResults?: ToolResultMessage[];
|
|
10
|
+
}
|
|
11
|
+
export declare function AssistantMessageView({ expandToolOutputs, message, showImages, showThinking, theme, toolResults, }: AssistantMessageProps): JSX.Element;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { BashExecutionMessage } from "indusagi/agent";
|
|
2
|
+
import type { InkThemeAdapter } from "../../theme-adapter.js";
|
|
3
|
+
interface BashMessageProps {
|
|
4
|
+
message: BashExecutionMessage;
|
|
5
|
+
theme: InkThemeAdapter;
|
|
6
|
+
}
|
|
7
|
+
export declare function BashMessageView({ message, theme }: BashMessageProps): JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { BranchSummaryMessage } from "indusagi/agent";
|
|
2
|
+
import type { InkThemeAdapter } from "../../theme-adapter.js";
|
|
3
|
+
interface BranchSummaryMessageProps {
|
|
4
|
+
message: BranchSummaryMessage;
|
|
5
|
+
theme: InkThemeAdapter;
|
|
6
|
+
}
|
|
7
|
+
export declare function BranchSummaryMessageView({ message, theme }: BranchSummaryMessageProps): JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { CompactionSummaryMessage } from "indusagi/agent";
|
|
2
|
+
import type { InkThemeAdapter } from "../../theme-adapter.js";
|
|
3
|
+
interface CompactionMessageProps {
|
|
4
|
+
message: CompactionSummaryMessage;
|
|
5
|
+
theme: InkThemeAdapter;
|
|
6
|
+
}
|
|
7
|
+
export declare function CompactionMessageView({ message, theme }: CompactionMessageProps): JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { CustomMessage } from "indusagi/agent";
|
|
2
|
+
import type { InkThemeAdapter } from "../../theme-adapter.js";
|
|
3
|
+
interface CustomMessageProps {
|
|
4
|
+
message: CustomMessage;
|
|
5
|
+
showImages: boolean;
|
|
6
|
+
theme: InkThemeAdapter;
|
|
7
|
+
}
|
|
8
|
+
export declare function CustomMessageView({ message, showImages, theme }: CustomMessageProps): JSX.Element | null;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { InkThemeAdapter } from "../../theme-adapter.js";
|
|
2
|
+
interface SkillInvocationMessageProps {
|
|
3
|
+
content: string;
|
|
4
|
+
theme: InkThemeAdapter;
|
|
5
|
+
}
|
|
6
|
+
export declare function SkillInvocationMessage({ content, theme }: SkillInvocationMessageProps): JSX.Element | null;
|
|
7
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { ToolCall } from "indusagi/ai";
|
|
2
|
+
import type { InkThemeAdapter } from "../../theme-adapter.js";
|
|
3
|
+
interface ToolCallMessageProps {
|
|
4
|
+
toolCall: ToolCall;
|
|
5
|
+
theme: InkThemeAdapter;
|
|
6
|
+
}
|
|
7
|
+
export declare function ToolCallMessage({ theme, toolCall }: ToolCallMessageProps): JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { ToolCall, ToolResultMessage } from "indusagi/ai";
|
|
2
|
+
import type { InkThemeAdapter } from "../../theme-adapter.js";
|
|
3
|
+
interface ToolResultBlockProps {
|
|
4
|
+
message: ToolResultMessage;
|
|
5
|
+
showImages: boolean;
|
|
6
|
+
theme: InkThemeAdapter;
|
|
7
|
+
expanded?: boolean;
|
|
8
|
+
nested?: boolean;
|
|
9
|
+
toolCall?: ToolCall;
|
|
10
|
+
}
|
|
11
|
+
export declare function ToolResultBlock({ expanded, message, nested, showImages, theme, toolCall }: ToolResultBlockProps): JSX.Element;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { UserMessage } from "indusagi/ai";
|
|
2
|
+
import type { InkThemeAdapter } from "../../theme-adapter.js";
|
|
3
|
+
interface UserMessageProps {
|
|
4
|
+
message: UserMessage;
|
|
5
|
+
theme: InkThemeAdapter;
|
|
6
|
+
showImages: boolean;
|
|
7
|
+
}
|
|
8
|
+
export declare function UserMessageView({ message, showImages, theme }: UserMessageProps): JSX.Element;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { ReactNode } from "indusagi/react-host";
|
|
2
|
+
import type { InkThemeAdapter } from "../theme-adapter.js";
|
|
3
|
+
import type { StructuredDiff } from "./structured.js";
|
|
4
|
+
interface DiffProps {
|
|
5
|
+
diff: StructuredDiff;
|
|
6
|
+
theme: InkThemeAdapter;
|
|
7
|
+
/** Left margin (columns) applied to the whole block. */
|
|
8
|
+
indent?: number;
|
|
9
|
+
marginBottom?: number;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* A minimal, pure-Ink colored diff block.
|
|
13
|
+
*
|
|
14
|
+
* Renders each hunk's classified lines with a right-aligned line-number gutter,
|
|
15
|
+
* themed add/remove backgrounds, and word-level intra-line emphasis (only the
|
|
16
|
+
* changed sub-ranges are bolded; suppressed above the change threshold upstream
|
|
17
|
+
* in {@link buildStructuredDiff}). Multiple hunks are separated by a dim `...`
|
|
18
|
+
* marker. No state, no effects — colors survive to the terminal because nothing
|
|
19
|
+
* strips the ANSI on this path.
|
|
20
|
+
*/
|
|
21
|
+
export declare function Diff({ diff, theme, indent, marginBottom }: DiffProps): ReactNode;
|
|
22
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { type WordSpan } from "./word-diff.js";
|
|
2
|
+
/** Lines of unchanged context kept around each change, matching git's default. */
|
|
3
|
+
export declare const CONTEXT_LINES = 3;
|
|
4
|
+
/** A single rendered diff line, already classified and numbered. */
|
|
5
|
+
export interface DiffLine {
|
|
6
|
+
kind: "context" | "added" | "removed";
|
|
7
|
+
/** The old-file line number, or undefined for added lines. */
|
|
8
|
+
oldLine?: number;
|
|
9
|
+
/** The new-file line number, or undefined for removed lines. */
|
|
10
|
+
newLine?: number;
|
|
11
|
+
/** The line text without its `+`/`-`/space diff prefix. */
|
|
12
|
+
text: string;
|
|
13
|
+
/**
|
|
14
|
+
* Word-level segments for intra-line highlighting. Present only on added /
|
|
15
|
+
* removed lines that were paired with their counterpart; context lines and
|
|
16
|
+
* unpaired changes leave this undefined (render the whole line one colour).
|
|
17
|
+
*/
|
|
18
|
+
spans?: WordSpan[];
|
|
19
|
+
}
|
|
20
|
+
/** One contiguous change region: classified lines plus a hunk header marker. */
|
|
21
|
+
export interface DiffHunk {
|
|
22
|
+
oldStart: number;
|
|
23
|
+
newStart: number;
|
|
24
|
+
lines: DiffLine[];
|
|
25
|
+
}
|
|
26
|
+
export interface StructuredDiff {
|
|
27
|
+
hunks: DiffHunk[];
|
|
28
|
+
addedCount: number;
|
|
29
|
+
removedCount: number;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Build a structured diff between `oldStr` and `newStr` using the `diff`
|
|
33
|
+
* package's {@link structuredPatch} with {@link CONTEXT_LINES} of context.
|
|
34
|
+
*
|
|
35
|
+
* The raw hunk `lines` (prefixed `+`/`-`/space) are walked into typed
|
|
36
|
+
* {@link DiffLine}s carrying gutter line numbers. Adjacent removed→added runs
|
|
37
|
+
* are paired index-for-index and handed to {@link wordDiffLine} so the renderer
|
|
38
|
+
* can emphasise only the changed sub-range of each line. Returns `null` when
|
|
39
|
+
* there is nothing to show (identical input or an empty patch).
|
|
40
|
+
*/
|
|
41
|
+
export declare function buildStructuredDiff(oldStr: string, newStr: string, filePath?: string): StructuredDiff | null;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Above this fraction of a line changing, intra-line word highlighting reads as
|
|
3
|
+
* noise — almost every span is "changed", so a flat whole-line colour is
|
|
4
|
+
* clearer. Below it we paint only the genuinely altered sub-ranges brighter.
|
|
5
|
+
*/
|
|
6
|
+
export declare const CHANGE_THRESHOLD = 0.4;
|
|
7
|
+
/** One contiguous run of a removed/added line, flagged whether it changed. */
|
|
8
|
+
export interface WordSpan {
|
|
9
|
+
text: string;
|
|
10
|
+
/** True when this run differs between the old and new line. */
|
|
11
|
+
changed: boolean;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Pair a removed line with the added line that replaced it and return the
|
|
15
|
+
* per-segment word diff for ONE side.
|
|
16
|
+
*
|
|
17
|
+
* `side` selects which line's segments we want: a removed-line render wants the
|
|
18
|
+
* segments present in the old text (unchanged + removed), an added-line render
|
|
19
|
+
* wants the segments present in the new text (unchanged + added). The other
|
|
20
|
+
* side's segments are dropped so the caller paints exactly the line it is on.
|
|
21
|
+
*
|
|
22
|
+
* Word highlighting is suppressed — the whole line is returned as a single
|
|
23
|
+
* `changed: true` span — when the changed character fraction exceeds
|
|
24
|
+
* {@link CHANGE_THRESHOLD}, where scattered word spans read worse than a flat
|
|
25
|
+
* line colour. The returned spans always concatenate back to the original line.
|
|
26
|
+
*/
|
|
27
|
+
export declare function wordDiffLine(oldLine: string, newLine: string, side: "removed" | "added"): WordSpan[];
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
export * from "./types.js";
|
|
2
|
+
export * from "./theme-adapter.js";
|
|
3
|
+
export * from "./components/ChangelogBlock.js";
|
|
4
|
+
export * from "./components/DisplayBlockView.js";
|
|
5
|
+
export * from "./components/Footer.js";
|
|
6
|
+
export * from "./components/MessageList.js";
|
|
7
|
+
export * from "./components/MessageRow.js";
|
|
8
|
+
export * from "./components/StatusLine.js";
|
|
9
|
+
export * from "./components/TaskPanel.js";
|
|
10
|
+
export * from "./components/ToolEventBlock.js";
|
|
11
|
+
export * from "./components/dialogs/DialogFrame.js";
|
|
12
|
+
export * from "./components/dialogs/LoginDialog.js";
|
|
13
|
+
export * from "./components/dialogs/ModelDialog.js";
|
|
14
|
+
export * from "./components/dialogs/OAuthDialog.js";
|
|
15
|
+
export * from "./components/dialogs/ScopedModelsDialog.js";
|
|
16
|
+
export * from "./components/dialogs/SelectableDialog.js";
|
|
17
|
+
export * from "./components/dialogs/SessionDialog.js";
|
|
18
|
+
export * from "./components/dialogs/SettingsDialog.js";
|
|
19
|
+
export * from "./components/dialogs/StartupSessionPicker.js";
|
|
20
|
+
export * from "./components/dialogs/ThemeDialog.js";
|
|
21
|
+
export * from "./components/dialogs/TreeDialog.js";
|
|
22
|
+
export * from "./components/dialogs/UserMessageDialog.js";
|
|
23
|
+
export * from "./components/messages/AssistantMessage.js";
|
|
24
|
+
export * from "./components/messages/BashMessage.js";
|
|
25
|
+
export * from "./components/messages/BranchSummaryMessage.js";
|
|
26
|
+
export * from "./components/messages/CompactionMessage.js";
|
|
27
|
+
export * from "./components/messages/CustomMessage.js";
|
|
28
|
+
export * from "./components/messages/SkillInvocationMessage.js";
|
|
29
|
+
export * from "./components/messages/ToolCallMessage.js";
|
|
30
|
+
export * from "./components/messages/ToolResultBlock.js";
|
|
31
|
+
export * from "./components/messages/UserMessage.js";
|
|
32
|
+
export * from "./diff/Diff.js";
|
|
33
|
+
export * from "./diff/structured.js";
|
|
34
|
+
export * from "./diff/word-diff.js";
|
|
35
|
+
export * from "./markdown/Markdown.js";
|
|
36
|
+
export * from "./markdown/MarkdownTable.js";
|
|
37
|
+
export * from "./markdown/StreamingMarkdown.js";
|
|
38
|
+
export * from "./markdown/format-token.js";
|
|
39
|
+
export * from "./markdown/highlight.js";
|
|
40
|
+
export * from "./utils/message-groups.js";
|
|
41
|
+
export * from "./utils/selection-dialog.js";
|
|
42
|
+
export * from "./utils/tool-display.js";
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import type { ReactNode } from "indusagi/react-host";
|
|
2
|
+
import type { InkThemeAdapter } from "../theme-adapter.js";
|
|
3
|
+
interface MarkdownProps {
|
|
4
|
+
/** The raw markdown source to render. */
|
|
5
|
+
children: string;
|
|
6
|
+
/** The theme adapter colours resolve against. */
|
|
7
|
+
theme: InkThemeAdapter;
|
|
8
|
+
/** When false, fenced code is rendered plain (no syntax highlighting). */
|
|
9
|
+
highlightCode?: boolean;
|
|
10
|
+
/** Render every text run dim (used for de-emphasised content). */
|
|
11
|
+
dim?: boolean;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Render markdown as styled terminal output.
|
|
15
|
+
*
|
|
16
|
+
* Tables become real flexbox columns ({@link MarkdownTable}); every other token
|
|
17
|
+
* is formatted to a chalk-ANSI string via {@link formatToken} and accumulated
|
|
18
|
+
* into a single `<Text>` run. Ink passes embedded ANSI straight to the terminal,
|
|
19
|
+
* so the chalk escapes render as colour. The `theme` is passed explicitly — the
|
|
20
|
+
* rebuild has no `useTheme()` hook.
|
|
21
|
+
*/
|
|
22
|
+
export declare function Markdown({ children, theme, highlightCode, dim }: MarkdownProps): ReactNode;
|
|
23
|
+
export {};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { Tokens } from "marked";
|
|
2
|
+
import type { InkThemeAdapter } from "../theme-adapter.js";
|
|
3
|
+
import type { CliHighlight } from "./highlight.js";
|
|
4
|
+
interface MarkdownTableProps {
|
|
5
|
+
token: Tokens.Table;
|
|
6
|
+
theme: InkThemeAdapter;
|
|
7
|
+
highlight?: CliHighlight | null;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Render a GFM table token as aligned flexbox columns.
|
|
11
|
+
*
|
|
12
|
+
* Each column's width is measured from the stripAnsi'd display text (so embedded
|
|
13
|
+
* ANSI styling does not inflate the column), the header row is bold, a dash rule
|
|
14
|
+
* separates header from body, and every cell is padded per its column alignment.
|
|
15
|
+
* Cells render as `<Box>` columns inside `<Box flexDirection="row">` rows, so Ink
|
|
16
|
+
* lays them out as real columns rather than a raw `| a | b |` pipe string.
|
|
17
|
+
*/
|
|
18
|
+
export declare function MarkdownTable({ token, theme, highlight }: MarkdownTableProps): JSX.Element;
|
|
19
|
+
export {};
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import type { ReactNode } from "indusagi/react-host";
|
|
2
|
+
import type { InkThemeAdapter } from "../theme-adapter.js";
|
|
3
|
+
interface StreamingMarkdownProps {
|
|
4
|
+
/** The accumulated answer text so far (grows monotonically per delta). */
|
|
5
|
+
children: string;
|
|
6
|
+
/** The theme adapter colours resolve against. */
|
|
7
|
+
theme: InkThemeAdapter;
|
|
8
|
+
/** When false, fenced code is rendered plain (no syntax highlighting). */
|
|
9
|
+
highlightCode?: boolean;
|
|
10
|
+
/** Render every text run dim. */
|
|
11
|
+
dim?: boolean;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Streaming-aware markdown renderer with a monotonic stable-prefix boundary.
|
|
15
|
+
*
|
|
16
|
+
* On every delta the accumulated answer grows. Re-lexing the whole answer each
|
|
17
|
+
* time would re-parse (and reflow/flicker) content that is already settled. To
|
|
18
|
+
* avoid that, we split the answer at the last completed block boundary:
|
|
19
|
+
*
|
|
20
|
+
* - **stable prefix** — every block above the boundary. Memoised on its own
|
|
21
|
+
* content, so once a block settles its `<Markdown>` is parsed once and never
|
|
22
|
+
* re-renders as later deltas arrive.
|
|
23
|
+
* - **unstable suffix** — the still-growing last block. Re-lexed every delta
|
|
24
|
+
* (cheap: it is one block, and `Markdown`'s own LRU cache + fast-path absorb
|
|
25
|
+
* the cost).
|
|
26
|
+
*
|
|
27
|
+
* The boundary only ever moves forward (it is recomputed from `content`, which
|
|
28
|
+
* grows monotonically, and `lastStableBoundary` is monotonic in its input), so
|
|
29
|
+
* completed blocks never re-flicker. When the turn ends and the finalized
|
|
30
|
+
* assistant message takes over rendering, the same `<Markdown>` pipeline draws
|
|
31
|
+
* identical output, so the hand-off is seamless.
|
|
32
|
+
*/
|
|
33
|
+
export declare function StreamingMarkdown({ children, theme, highlightCode, dim, }: StreamingMarkdownProps): ReactNode;
|
|
34
|
+
export {};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { type Token } from "marked";
|
|
2
|
+
import type { InkThemeAdapter } from "../theme-adapter.js";
|
|
3
|
+
import type { CliHighlight } from "./highlight.js";
|
|
4
|
+
/**
|
|
5
|
+
* Configure the shared `marked` instance exactly once. The only customisation is
|
|
6
|
+
* disabling strikethrough: models frequently write `~` for "approximate"
|
|
7
|
+
* (e.g. `~100`) and almost never intend an actual strike, so we keep `~` literal.
|
|
8
|
+
*/
|
|
9
|
+
export declare function configureMarked(): void;
|
|
10
|
+
/**
|
|
11
|
+
* Fast structural check for whether `text` contains any markdown syntax. Samples
|
|
12
|
+
* the first 500 chars — markdown markers (headings, fences, list bullets) cluster
|
|
13
|
+
* at the start, while long plain tails (tool output) stay markdown-free.
|
|
14
|
+
*/
|
|
15
|
+
export declare function hasMarkdownSyntax(text: string): boolean;
|
|
16
|
+
/**
|
|
17
|
+
* Lex `content` into marked tokens, hitting the LRU cache and the plain-text
|
|
18
|
+
* fast-path. Plain text (no markdown syntax) returns a single synthetic
|
|
19
|
+
* paragraph token and is intentionally not cached — reconstruction is one
|
|
20
|
+
* allocation and caching would retain the content for no benefit.
|
|
21
|
+
*/
|
|
22
|
+
export declare function cachedLexer(content: string): Token[];
|
|
23
|
+
/**
|
|
24
|
+
* Render a single marked token to a chalk-ANSI string, painting via the
|
|
25
|
+
* framework {@link InkThemeAdapter}. Tables are handled out-of-band by the
|
|
26
|
+
* `Markdown` component (rendered as flexbox), so this returns an empty string
|
|
27
|
+
* for `table` tokens — the caller never funnels a table through here.
|
|
28
|
+
*/
|
|
29
|
+
export declare function formatToken(token: Token, theme: InkThemeAdapter, highlight?: CliHighlight | null, listDepth?: number, orderedListNumber?: number | null, parent?: Token | null): string;
|
|
30
|
+
/** Pick the list-marker style for a depth: 1./2. → a./b. → i./ii. → numeric. */
|
|
31
|
+
export declare function getListNumber(listDepth: number, orderedListNumber: number): string;
|
|
32
|
+
/**
|
|
33
|
+
* Pad `content` to `targetWidth` per alignment. `displayWidth` is the visible
|
|
34
|
+
* width of `content` (caller computes it on stripAnsi'd text so embedded ANSI
|
|
35
|
+
* codes do not skew the padding).
|
|
36
|
+
*/
|
|
37
|
+
export declare function padAligned(content: string, displayWidth: number, targetWidth: number, align: "left" | "center" | "right" | null | undefined): string;
|
|
38
|
+
/** Measure a string's visible terminal width (ANSI-aware), for table layout. */
|
|
39
|
+
export declare function stringWidth(text: string): number;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import type { InkThemeAdapter } from "../theme-adapter.js";
|
|
2
|
+
/**
|
|
3
|
+
* The shape {@link formatToken} (and the tool-body highlighter) consume. It is a
|
|
4
|
+
* deliberately small surface: ask whether a language is known, then hand back a
|
|
5
|
+
* chalk-ANSI rendering of the code. Keeping it behind an interface means the
|
|
6
|
+
* markdown formatter never imports highlight.js directly and a caller can pass
|
|
7
|
+
* `null` to disable highlighting entirely.
|
|
8
|
+
*/
|
|
9
|
+
export interface CliHighlight {
|
|
10
|
+
/** Whether highlight.js has a grammar registered for `language`. */
|
|
11
|
+
supportsLanguage: (language: string) => boolean;
|
|
12
|
+
/** Render `code` as a chalk-ANSI string, colouring scopes via the theme. */
|
|
13
|
+
highlight: (code: string, options: {
|
|
14
|
+
language: string;
|
|
15
|
+
}) => string;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* Build a {@link CliHighlight} bound to a theme. The returned object paints each
|
|
19
|
+
* highlight.js scope via the theme's syntax roles ({@link ThemeRole}); unknown
|
|
20
|
+
* languages and any internal failure fall back to the raw code, never throwing.
|
|
21
|
+
*/
|
|
22
|
+
export declare function createHighlighter(theme: InkThemeAdapter): CliHighlight;
|
|
23
|
+
/**
|
|
24
|
+
* Highlight `code` keyed on a file path's extension. Used by the read/write/edit
|
|
25
|
+
* tool bodies, which know the file but not a fenced ```lang tag. Resolves the
|
|
26
|
+
* extension to a highlight.js language, falling back to the plain code when the
|
|
27
|
+
* extension is unknown or unsupported.
|
|
28
|
+
*/
|
|
29
|
+
export declare function highlightByPath(code: string, filePath: string, theme: InkThemeAdapter): string;
|
|
30
|
+
/** Resolve a file path to a highlight.js language id, or null when unknown. */
|
|
31
|
+
export declare function languageFromPath(filePath: string): string | null;
|