dexto 1.3.0 → 1.5.0
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/README.md +87 -22
- package/dist/agents/agent-registry.json +9 -0
- package/dist/agents/agent-template.yml +2 -2
- package/dist/agents/coding-agent/coding-agent.yml +27 -16
- package/dist/agents/database-agent/database-agent.yml +2 -2
- package/dist/agents/default-agent.yml +9 -7
- package/dist/agents/github-agent/github-agent.yml +2 -2
- package/dist/agents/product-name-researcher/product-name-researcher.yml +2 -2
- package/dist/agents/talk2pdf-agent/talk2pdf-agent.yml +2 -2
- package/dist/analytics/events.d.ts +13 -6
- package/dist/analytics/events.d.ts.map +1 -1
- package/dist/analytics/index.d.ts +1 -1
- package/dist/analytics/index.d.ts.map +1 -1
- package/dist/analytics/index.js +6 -2
- package/dist/api/server-hono.d.ts.map +1 -1
- package/dist/api/server-hono.js +65 -9
- package/dist/cli/cli-subscriber.d.ts +4 -0
- package/dist/cli/cli-subscriber.d.ts.map +1 -1
- package/dist/cli/cli-subscriber.js +47 -3
- package/dist/cli/commands/create-app.d.ts +16 -14
- package/dist/cli/commands/create-app.d.ts.map +1 -1
- package/dist/cli/commands/create-app.js +626 -102
- package/dist/cli/commands/create-image.d.ts +7 -0
- package/dist/cli/commands/create-image.d.ts.map +1 -0
- package/dist/cli/commands/create-image.js +201 -0
- package/dist/cli/commands/helpers/formatters.d.ts.map +1 -1
- package/dist/cli/commands/helpers/formatters.js +9 -8
- package/dist/cli/commands/index.d.ts +2 -1
- package/dist/cli/commands/index.d.ts.map +1 -1
- package/dist/cli/commands/index.js +2 -1
- package/dist/cli/commands/init-app.js +7 -7
- package/dist/cli/commands/install.d.ts +0 -3
- package/dist/cli/commands/install.d.ts.map +1 -1
- package/dist/cli/commands/install.js +19 -70
- package/dist/cli/commands/interactive-commands/command-parser.d.ts +17 -14
- package/dist/cli/commands/interactive-commands/command-parser.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/command-parser.js +7 -22
- package/dist/cli/commands/interactive-commands/commands.d.ts +4 -4
- package/dist/cli/commands/interactive-commands/commands.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/commands.js +34 -42
- package/dist/cli/commands/interactive-commands/documentation-commands.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/documentation-commands.js +4 -7
- package/dist/cli/commands/interactive-commands/general-commands.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/general-commands.js +159 -117
- package/dist/cli/commands/interactive-commands/mcp/index.d.ts +9 -3
- package/dist/cli/commands/interactive-commands/mcp/index.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/mcp/index.js +18 -3
- package/dist/cli/commands/interactive-commands/model/index.d.ts +8 -6
- package/dist/cli/commands/interactive-commands/model/index.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/model/index.js +18 -6
- package/dist/cli/commands/interactive-commands/prompt-commands.d.ts +3 -2
- package/dist/cli/commands/interactive-commands/prompt-commands.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/prompt-commands.js +77 -60
- package/dist/cli/commands/interactive-commands/session/index.d.ts +7 -12
- package/dist/cli/commands/interactive-commands/session/index.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/session/index.js +7 -14
- package/dist/cli/commands/interactive-commands/session/session-commands.d.ts +10 -24
- package/dist/cli/commands/interactive-commands/session/session-commands.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/session/session-commands.js +16 -371
- package/dist/cli/commands/interactive-commands/system/system-commands.d.ts +1 -0
- package/dist/cli/commands/interactive-commands/system/system-commands.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/system/system-commands.js +106 -77
- package/dist/cli/commands/interactive-commands/tool-commands.d.ts +1 -1
- package/dist/cli/commands/interactive-commands/tool-commands.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/tool-commands.js +5 -62
- package/dist/cli/commands/interactive-commands/utils/command-output.d.ts +13 -17
- package/dist/cli/commands/interactive-commands/utils/command-output.d.ts.map +1 -1
- package/dist/cli/commands/interactive-commands/utils/command-output.js +18 -37
- package/dist/cli/commands/list-agents.d.ts +2 -2
- package/dist/cli/commands/list-agents.d.ts.map +1 -1
- package/dist/cli/commands/list-agents.js +38 -34
- package/dist/cli/commands/session-commands.js +16 -16
- package/dist/cli/commands/setup.d.ts +13 -5
- package/dist/cli/commands/setup.d.ts.map +1 -1
- package/dist/cli/commands/setup.js +860 -65
- package/dist/cli/commands/uninstall.d.ts.map +1 -1
- package/dist/cli/commands/uninstall.js +4 -6
- package/dist/cli/commands/which.d.ts.map +1 -1
- package/dist/cli/commands/which.js +18 -4
- package/dist/cli/ink-cli/InkCLIRefactored.d.ts +9 -22
- package/dist/cli/ink-cli/InkCLIRefactored.d.ts.map +1 -1
- package/dist/cli/ink-cli/InkCLIRefactored.js +50 -133
- package/dist/cli/ink-cli/components/ApprovalPrompt.d.ts +26 -3
- package/dist/cli/ink-cli/components/ApprovalPrompt.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/ApprovalPrompt.js +182 -45
- package/dist/cli/ink-cli/components/CustomInput.js +1 -1
- package/dist/cli/ink-cli/components/EditableMultiLineInput.js +4 -4
- package/dist/cli/ink-cli/components/ElicitationForm.d.ts +22 -0
- package/dist/cli/ink-cli/components/ElicitationForm.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/ElicitationForm.js +358 -0
- package/dist/cli/ink-cli/components/ErrorBoundary.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/ErrorBoundary.js +1 -1
- package/dist/cli/ink-cli/components/Footer.d.ts +16 -0
- package/dist/cli/ink-cli/components/Footer.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/Footer.js +27 -0
- package/dist/cli/ink-cli/components/HistorySearchBar.d.ts +17 -0
- package/dist/cli/ink-cli/components/HistorySearchBar.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/HistorySearchBar.js +8 -0
- package/dist/cli/ink-cli/components/MultiLineInput.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/MultiLineInput.js +3 -3
- package/dist/cli/ink-cli/components/ResourceAutocomplete.d.ts +15 -2
- package/dist/cli/ink-cli/components/ResourceAutocomplete.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/ResourceAutocomplete.js +126 -82
- package/dist/cli/ink-cli/components/SlashCommandAutocomplete.d.ts +15 -2
- package/dist/cli/ink-cli/components/SlashCommandAutocomplete.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/SlashCommandAutocomplete.js +228 -122
- package/dist/cli/ink-cli/components/StatusBar.d.ts +15 -2
- package/dist/cli/ink-cli/components/StatusBar.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/StatusBar.js +50 -10
- package/dist/cli/ink-cli/components/TextBufferInput.d.ts +52 -0
- package/dist/cli/ink-cli/components/TextBufferInput.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/TextBufferInput.js +471 -0
- package/dist/cli/ink-cli/components/base/BaseAutocomplete.js +4 -4
- package/dist/cli/ink-cli/components/base/BaseSelector.d.ts +11 -1
- package/dist/cli/ink-cli/components/base/BaseSelector.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/base/BaseSelector.js +90 -49
- package/dist/cli/ink-cli/components/chat/Footer.js +1 -1
- package/dist/cli/ink-cli/components/chat/Header.d.ts +1 -0
- package/dist/cli/ink-cli/components/chat/Header.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/chat/Header.js +6 -3
- package/dist/cli/ink-cli/components/chat/MessageItem.d.ts +3 -0
- package/dist/cli/ink-cli/components/chat/MessageItem.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/chat/MessageItem.js +95 -9
- package/dist/cli/ink-cli/components/chat/MessageList.js +1 -1
- package/dist/cli/ink-cli/components/chat/QueuedMessagesDisplay.d.ts +16 -0
- package/dist/cli/ink-cli/components/chat/QueuedMessagesDisplay.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/QueuedMessagesDisplay.js +27 -0
- package/dist/cli/ink-cli/components/chat/ToolIcon.d.ts +5 -3
- package/dist/cli/ink-cli/components/chat/ToolIcon.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/chat/ToolIcon.js +21 -7
- package/dist/cli/ink-cli/components/chat/styled-boxes/ConfigBox.d.ts +10 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/ConfigBox.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/ConfigBox.js +6 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/HelpBox.d.ts +10 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/HelpBox.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/HelpBox.js +15 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/LogConfigBox.d.ts +10 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/LogConfigBox.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/LogConfigBox.js +9 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/SessionHistoryBox.d.ts +10 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/SessionHistoryBox.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/SessionHistoryBox.js +37 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/SessionListBox.d.ts +10 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/SessionListBox.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/SessionListBox.js +9 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/ShortcutsBox.d.ts +10 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/ShortcutsBox.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/ShortcutsBox.js +6 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/StatsBox.d.ts +10 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/StatsBox.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/StatsBox.js +29 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/StyledBox.d.ts +45 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/StyledBox.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/StyledBox.js +38 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/SyspromptBox.d.ts +10 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/SyspromptBox.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/SyspromptBox.js +6 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/index.d.ts +13 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/index.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/chat/styled-boxes/index.js +12 -0
- package/dist/cli/ink-cli/components/input/InputArea.d.ts +36 -8
- package/dist/cli/ink-cli/components/input/InputArea.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/input/InputArea.js +3 -3
- package/dist/cli/ink-cli/components/modes/AlternateBufferCLI.d.ts +25 -0
- package/dist/cli/ink-cli/components/modes/AlternateBufferCLI.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/modes/AlternateBufferCLI.js +166 -0
- package/dist/cli/ink-cli/components/modes/StaticCLI.d.ts +27 -0
- package/dist/cli/ink-cli/components/modes/StaticCLI.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/modes/StaticCLI.js +95 -0
- package/dist/cli/ink-cli/components/modes/index.d.ts +10 -0
- package/dist/cli/ink-cli/components/modes/index.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/modes/index.js +9 -0
- package/dist/cli/ink-cli/components/overlays/ApiKeyInput.d.ts +26 -0
- package/dist/cli/ink-cli/components/overlays/ApiKeyInput.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/ApiKeyInput.js +92 -0
- package/dist/cli/ink-cli/components/overlays/CustomModelWizard.d.ts +29 -0
- package/dist/cli/ink-cli/components/overlays/CustomModelWizard.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/CustomModelWizard.js +286 -0
- package/dist/cli/ink-cli/components/overlays/LogLevelSelector.d.ts +22 -0
- package/dist/cli/ink-cli/components/overlays/LogLevelSelector.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/LogLevelSelector.js +59 -0
- package/dist/cli/ink-cli/components/overlays/McpAddChoice.d.ts +22 -0
- package/dist/cli/ink-cli/components/overlays/McpAddChoice.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/McpAddChoice.js +59 -0
- package/dist/cli/ink-cli/components/overlays/McpAddSelector.d.ts +26 -0
- package/dist/cli/ink-cli/components/overlays/McpAddSelector.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/McpAddSelector.js +73 -0
- package/dist/cli/ink-cli/components/overlays/McpCustomTypeSelector.d.ts +21 -0
- package/dist/cli/ink-cli/components/overlays/McpCustomTypeSelector.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/McpCustomTypeSelector.js +51 -0
- package/dist/cli/ink-cli/components/overlays/McpCustomWizard.d.ts +29 -0
- package/dist/cli/ink-cli/components/overlays/McpCustomWizard.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/McpCustomWizard.js +215 -0
- package/dist/cli/ink-cli/components/overlays/McpRemoveSelector.d.ts +22 -0
- package/dist/cli/ink-cli/components/overlays/McpRemoveSelector.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/McpRemoveSelector.js +74 -0
- package/dist/cli/ink-cli/components/overlays/McpSelector.d.ts +21 -0
- package/dist/cli/ink-cli/components/overlays/McpSelector.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/McpSelector.js +52 -0
- package/dist/cli/ink-cli/components/overlays/McpServerActions.d.ts +28 -0
- package/dist/cli/ink-cli/components/overlays/McpServerActions.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/McpServerActions.js +84 -0
- package/dist/cli/ink-cli/components/overlays/McpServerList.d.ts +29 -0
- package/dist/cli/ink-cli/components/overlays/McpServerList.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/McpServerList.js +109 -0
- package/dist/cli/ink-cli/components/overlays/ModelSelectorRefactored.d.ts +15 -8
- package/dist/cli/ink-cli/components/overlays/ModelSelectorRefactored.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/overlays/ModelSelectorRefactored.js +400 -23
- package/dist/cli/ink-cli/components/overlays/PromptAddChoice.d.ts +22 -0
- package/dist/cli/ink-cli/components/overlays/PromptAddChoice.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/PromptAddChoice.js +52 -0
- package/dist/cli/ink-cli/components/overlays/PromptAddWizard.d.ts +29 -0
- package/dist/cli/ink-cli/components/overlays/PromptAddWizard.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/PromptAddWizard.js +166 -0
- package/dist/cli/ink-cli/components/overlays/PromptDeleteSelector.d.ts +27 -0
- package/dist/cli/ink-cli/components/overlays/PromptDeleteSelector.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/PromptDeleteSelector.js +119 -0
- package/dist/cli/ink-cli/components/overlays/PromptList.d.ts +33 -0
- package/dist/cli/ink-cli/components/overlays/PromptList.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/PromptList.js +144 -0
- package/dist/cli/ink-cli/components/overlays/SearchOverlay.d.ts +23 -0
- package/dist/cli/ink-cli/components/overlays/SearchOverlay.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/SearchOverlay.js +189 -0
- package/dist/cli/ink-cli/components/overlays/SessionSelectorRefactored.d.ts +7 -2
- package/dist/cli/ink-cli/components/overlays/SessionSelectorRefactored.d.ts.map +1 -1
- package/dist/cli/ink-cli/components/overlays/SessionSelectorRefactored.js +19 -5
- package/dist/cli/ink-cli/components/overlays/SessionSubcommandSelector.d.ts +21 -0
- package/dist/cli/ink-cli/components/overlays/SessionSubcommandSelector.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/SessionSubcommandSelector.js +42 -0
- package/dist/cli/ink-cli/components/overlays/StreamSelector.d.ts +20 -0
- package/dist/cli/ink-cli/components/overlays/StreamSelector.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/StreamSelector.js +58 -0
- package/dist/cli/ink-cli/components/overlays/ToolBrowser.d.ts +25 -0
- package/dist/cli/ink-cli/components/overlays/ToolBrowser.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/ToolBrowser.js +400 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/LocalModelWizard.d.ts +25 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/LocalModelWizard.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/LocalModelWizard.js +609 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/index.d.ts +15 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/index.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/index.js +14 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/provider-config.d.ts +33 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/provider-config.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/provider-config.js +419 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/ApiKeyStep.d.ts +25 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/ApiKeyStep.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/ApiKeyStep.js +29 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/ProviderSelector.d.ts +17 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/ProviderSelector.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/ProviderSelector.js +11 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/SetupInfoBanner.d.ts +20 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/SetupInfoBanner.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/SetupInfoBanner.js +10 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/WizardStepInput.d.ts +30 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/WizardStepInput.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/WizardStepInput.js +13 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/index.d.ts +8 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/index.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/shared/index.js +7 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/types.d.ts +79 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/types.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/overlays/custom-model-wizard/types.js +38 -0
- package/dist/cli/ink-cli/components/renderers/DiffRenderer.d.ts +21 -0
- package/dist/cli/ink-cli/components/renderers/DiffRenderer.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/renderers/DiffRenderer.js +65 -0
- package/dist/cli/ink-cli/components/renderers/FilePreviewRenderer.d.ts +28 -0
- package/dist/cli/ink-cli/components/renderers/FilePreviewRenderer.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/renderers/FilePreviewRenderer.js +66 -0
- package/dist/cli/ink-cli/components/renderers/FileRenderer.d.ts +19 -0
- package/dist/cli/ink-cli/components/renderers/FileRenderer.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/renderers/FileRenderer.js +26 -0
- package/dist/cli/ink-cli/components/renderers/GenericRenderer.d.ts +21 -0
- package/dist/cli/ink-cli/components/renderers/GenericRenderer.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/renderers/GenericRenderer.js +26 -0
- package/dist/cli/ink-cli/components/renderers/SearchRenderer.d.ts +20 -0
- package/dist/cli/ink-cli/components/renderers/SearchRenderer.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/renderers/SearchRenderer.js +12 -0
- package/dist/cli/ink-cli/components/renderers/ShellRenderer.d.ts +21 -0
- package/dist/cli/ink-cli/components/renderers/ShellRenderer.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/renderers/ShellRenderer.js +25 -0
- package/dist/cli/ink-cli/components/renderers/diff-shared.d.ts +61 -0
- package/dist/cli/ink-cli/components/renderers/diff-shared.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/renderers/diff-shared.js +158 -0
- package/dist/cli/ink-cli/components/renderers/index.d.ts +28 -0
- package/dist/cli/ink-cli/components/renderers/index.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/renderers/index.js +36 -0
- package/dist/cli/ink-cli/components/shared/MarkdownText.d.ts +38 -0
- package/dist/cli/ink-cli/components/shared/MarkdownText.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/shared/MarkdownText.js +362 -0
- package/dist/cli/ink-cli/components/shared/VirtualizedList.d.ts +44 -0
- package/dist/cli/ink-cli/components/shared/VirtualizedList.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/shared/VirtualizedList.js +300 -0
- package/dist/cli/ink-cli/components/shared/text-buffer.d.ts +185 -0
- package/dist/cli/ink-cli/components/shared/text-buffer.d.ts.map +1 -0
- package/dist/cli/ink-cli/components/shared/text-buffer.js +1338 -0
- package/dist/cli/ink-cli/constants/processingPhrases.d.ts +10 -0
- package/dist/cli/ink-cli/constants/processingPhrases.d.ts.map +1 -0
- package/dist/cli/ink-cli/constants/processingPhrases.js +64 -0
- package/dist/cli/ink-cli/constants/tips.d.ts +15 -0
- package/dist/cli/ink-cli/constants/tips.d.ts.map +1 -0
- package/dist/cli/ink-cli/constants/tips.js +53 -0
- package/dist/cli/ink-cli/containers/InputContainer.d.ts +42 -8
- package/dist/cli/ink-cli/containers/InputContainer.d.ts.map +1 -1
- package/dist/cli/ink-cli/containers/InputContainer.js +513 -85
- package/dist/cli/ink-cli/containers/OverlayContainer.d.ts +23 -5
- package/dist/cli/ink-cli/containers/OverlayContainer.d.ts.map +1 -1
- package/dist/cli/ink-cli/containers/OverlayContainer.js +1214 -132
- package/dist/cli/ink-cli/containers/index.d.ts +1 -1
- package/dist/cli/ink-cli/containers/index.d.ts.map +1 -1
- package/dist/cli/ink-cli/contexts/KeypressContext.d.ts +36 -0
- package/dist/cli/ink-cli/contexts/KeypressContext.d.ts.map +1 -0
- package/dist/cli/ink-cli/contexts/KeypressContext.js +461 -0
- package/dist/cli/ink-cli/contexts/MouseContext.d.ts +27 -0
- package/dist/cli/ink-cli/contexts/MouseContext.d.ts.map +1 -0
- package/dist/cli/ink-cli/contexts/MouseContext.js +102 -0
- package/dist/cli/ink-cli/contexts/ScrollProvider.d.ts +33 -0
- package/dist/cli/ink-cli/contexts/ScrollProvider.d.ts.map +1 -0
- package/dist/cli/ink-cli/contexts/ScrollProvider.js +170 -0
- package/dist/cli/ink-cli/contexts/index.d.ts +7 -0
- package/dist/cli/ink-cli/contexts/index.d.ts.map +1 -0
- package/dist/cli/ink-cli/contexts/index.js +6 -0
- package/dist/cli/ink-cli/hooks/index.d.ts +5 -0
- package/dist/cli/ink-cli/hooks/index.d.ts.map +1 -1
- package/dist/cli/ink-cli/hooks/index.js +6 -1
- package/dist/cli/ink-cli/hooks/useAgentEvents.d.ts +26 -9
- package/dist/cli/ink-cli/hooks/useAgentEvents.d.ts.map +1 -1
- package/dist/cli/ink-cli/hooks/useAgentEvents.js +90 -198
- package/dist/cli/ink-cli/hooks/useBatchedScroll.d.ts +14 -0
- package/dist/cli/ink-cli/hooks/useBatchedScroll.d.ts.map +1 -0
- package/dist/cli/ink-cli/hooks/useBatchedScroll.js +25 -0
- package/dist/cli/ink-cli/hooks/useCLIState.d.ts +50 -0
- package/dist/cli/ink-cli/hooks/useCLIState.d.ts.map +1 -0
- package/dist/cli/ink-cli/hooks/useCLIState.js +190 -0
- package/dist/cli/ink-cli/hooks/useElapsedTime.d.ts +24 -0
- package/dist/cli/ink-cli/hooks/useElapsedTime.d.ts.map +1 -0
- package/dist/cli/ink-cli/hooks/useElapsedTime.js +69 -0
- package/dist/cli/ink-cli/hooks/useHistorySearch.d.ts +61 -0
- package/dist/cli/ink-cli/hooks/useHistorySearch.d.ts.map +1 -0
- package/dist/cli/ink-cli/hooks/useHistorySearch.js +210 -0
- package/dist/cli/ink-cli/hooks/useInputOrchestrator.d.ts +136 -0
- package/dist/cli/ink-cli/hooks/useInputOrchestrator.d.ts.map +1 -0
- package/dist/cli/ink-cli/hooks/useInputOrchestrator.js +663 -0
- package/dist/cli/ink-cli/hooks/useKeyboardShortcuts.d.ts.map +1 -1
- package/dist/cli/ink-cli/hooks/useKeyboardShortcuts.js +7 -26
- package/dist/cli/ink-cli/hooks/useKeypress.d.ts +18 -0
- package/dist/cli/ink-cli/hooks/useKeypress.d.ts.map +1 -0
- package/dist/cli/ink-cli/hooks/useKeypress.js +26 -0
- package/dist/cli/ink-cli/hooks/usePhraseCycler.d.ts +30 -0
- package/dist/cli/ink-cli/hooks/usePhraseCycler.d.ts.map +1 -0
- package/dist/cli/ink-cli/hooks/usePhraseCycler.js +68 -0
- package/dist/cli/ink-cli/hooks/useStreaming.d.ts +19 -0
- package/dist/cli/ink-cli/hooks/useStreaming.d.ts.map +1 -0
- package/dist/cli/ink-cli/hooks/useStreaming.js +26 -0
- package/dist/cli/ink-cli/hooks/useTerminalSize.d.ts +14 -0
- package/dist/cli/ink-cli/hooks/useTerminalSize.d.ts.map +1 -0
- package/dist/cli/ink-cli/hooks/useTerminalSize.js +31 -0
- package/dist/cli/ink-cli/hooks/useTokenCounter.d.ts +42 -0
- package/dist/cli/ink-cli/hooks/useTokenCounter.d.ts.map +1 -0
- package/dist/cli/ink-cli/hooks/useTokenCounter.js +96 -0
- package/dist/cli/ink-cli/services/CommandService.d.ts +32 -1
- package/dist/cli/ink-cli/services/CommandService.d.ts.map +1 -1
- package/dist/cli/ink-cli/services/CommandService.js +36 -5
- package/dist/cli/ink-cli/services/InputService.d.ts +1 -5
- package/dist/cli/ink-cli/services/InputService.d.ts.map +1 -1
- package/dist/cli/ink-cli/services/InputService.js +1 -8
- package/dist/cli/ink-cli/services/index.d.ts +2 -1
- package/dist/cli/ink-cli/services/index.d.ts.map +1 -1
- package/dist/cli/ink-cli/services/index.js +2 -1
- package/dist/cli/ink-cli/services/processStream.d.ts +69 -0
- package/dist/cli/ink-cli/services/processStream.d.ts.map +1 -0
- package/dist/cli/ink-cli/services/processStream.js +742 -0
- package/dist/cli/ink-cli/state/actions.d.ts +30 -60
- package/dist/cli/ink-cli/state/actions.d.ts.map +1 -1
- package/dist/cli/ink-cli/state/actions.js +3 -0
- package/dist/cli/ink-cli/state/index.d.ts +5 -3
- package/dist/cli/ink-cli/state/index.d.ts.map +1 -1
- package/dist/cli/ink-cli/state/index.js +4 -3
- package/dist/cli/ink-cli/state/initialState.d.ts +4 -3
- package/dist/cli/ink-cli/state/initialState.d.ts.map +1 -1
- package/dist/cli/ink-cli/state/initialState.js +20 -4
- package/dist/cli/ink-cli/state/reducer.d.ts +3 -0
- package/dist/cli/ink-cli/state/reducer.d.ts.map +1 -1
- package/dist/cli/ink-cli/state/reducer.js +62 -168
- package/dist/cli/ink-cli/state/streaming-state.d.ts +27 -0
- package/dist/cli/ink-cli/state/streaming-state.d.ts.map +1 -0
- package/dist/cli/ink-cli/state/streaming-state.js +39 -0
- package/dist/cli/ink-cli/state/types.d.ts +223 -6
- package/dist/cli/ink-cli/state/types.d.ts.map +1 -1
- package/dist/cli/ink-cli/utils/bracketedPaste.d.ts +22 -0
- package/dist/cli/ink-cli/utils/bracketedPaste.d.ts.map +1 -0
- package/dist/cli/ink-cli/utils/bracketedPaste.js +27 -0
- package/dist/cli/ink-cli/utils/clipboardUtils.d.ts +49 -0
- package/dist/cli/ink-cli/utils/clipboardUtils.d.ts.map +1 -0
- package/dist/cli/ink-cli/utils/clipboardUtils.js +356 -0
- package/dist/cli/ink-cli/utils/commandOverlays.d.ts +33 -0
- package/dist/cli/ink-cli/utils/commandOverlays.d.ts.map +1 -0
- package/dist/cli/ink-cli/utils/commandOverlays.js +78 -0
- package/dist/cli/ink-cli/utils/debugLog.d.ts +38 -0
- package/dist/cli/ink-cli/utils/debugLog.d.ts.map +1 -0
- package/dist/cli/ink-cli/utils/debugLog.js +66 -0
- package/dist/cli/ink-cli/utils/index.d.ts +2 -1
- package/dist/cli/ink-cli/utils/index.d.ts.map +1 -1
- package/dist/cli/ink-cli/utils/index.js +3 -1
- package/dist/cli/ink-cli/utils/input.d.ts +25 -0
- package/dist/cli/ink-cli/utils/input.d.ts.map +1 -0
- package/dist/cli/ink-cli/utils/input.js +56 -0
- package/dist/cli/ink-cli/utils/inputParsing.d.ts +0 -9
- package/dist/cli/ink-cli/utils/inputParsing.d.ts.map +1 -1
- package/dist/cli/ink-cli/utils/inputParsing.js +0 -27
- package/dist/cli/ink-cli/utils/messageFormatting.d.ts +59 -3
- package/dist/cli/ink-cli/utils/messageFormatting.d.ts.map +1 -1
- package/dist/cli/ink-cli/utils/messageFormatting.js +348 -20
- package/dist/cli/ink-cli/utils/mouse.d.ts +61 -0
- package/dist/cli/ink-cli/utils/mouse.d.ts.map +1 -0
- package/dist/cli/ink-cli/utils/mouse.js +209 -0
- package/dist/cli/ink-cli/utils/streamSplitter.d.ts +44 -0
- package/dist/cli/ink-cli/utils/streamSplitter.d.ts.map +1 -0
- package/dist/cli/ink-cli/utils/streamSplitter.js +154 -0
- package/dist/cli/ink-cli/utils/textUtils.d.ts +63 -0
- package/dist/cli/ink-cli/utils/textUtils.d.ts.map +1 -0
- package/dist/cli/ink-cli/utils/textUtils.js +248 -0
- package/dist/cli/ink-cli/utils/toolUtils.d.ts +9 -0
- package/dist/cli/ink-cli/utils/toolUtils.d.ts.map +1 -0
- package/dist/cli/ink-cli/utils/toolUtils.js +15 -0
- package/dist/cli/utils/api-key-setup.d.ts +54 -4
- package/dist/cli/utils/api-key-setup.d.ts.map +1 -1
- package/dist/cli/utils/api-key-setup.js +433 -107
- package/dist/cli/utils/api-key-verification.d.ts +17 -0
- package/dist/cli/utils/api-key-verification.d.ts.map +1 -0
- package/dist/cli/utils/api-key-verification.js +211 -0
- package/dist/cli/utils/config-validation.d.ts +22 -2
- package/dist/cli/utils/config-validation.d.ts.map +1 -1
- package/dist/cli/utils/config-validation.js +354 -25
- package/dist/cli/utils/local-model-setup.d.ts +46 -0
- package/dist/cli/utils/local-model-setup.d.ts.map +1 -0
- package/dist/cli/utils/local-model-setup.js +662 -0
- package/dist/cli/utils/options.d.ts.map +1 -1
- package/dist/cli/utils/options.js +1 -3
- package/dist/cli/utils/prompt-helpers.d.ts +47 -0
- package/dist/cli/utils/prompt-helpers.d.ts.map +1 -0
- package/dist/cli/utils/prompt-helpers.js +66 -0
- package/dist/cli/utils/provider-setup.d.ts +66 -8
- package/dist/cli/utils/provider-setup.d.ts.map +1 -1
- package/dist/cli/utils/provider-setup.js +324 -84
- package/dist/cli/utils/scaffolding-utils.d.ts +76 -0
- package/dist/cli/utils/scaffolding-utils.d.ts.map +1 -0
- package/dist/cli/utils/scaffolding-utils.js +246 -0
- package/dist/cli/utils/setup-utils.d.ts +16 -0
- package/dist/cli/utils/setup-utils.d.ts.map +1 -1
- package/dist/cli/utils/setup-utils.js +72 -21
- package/dist/cli/utils/template-engine.d.ts +65 -0
- package/dist/cli/utils/template-engine.d.ts.map +1 -0
- package/dist/cli/utils/template-engine.js +1089 -0
- package/dist/config/cli-overrides.d.ts +45 -2
- package/dist/config/cli-overrides.d.ts.map +1 -1
- package/dist/config/cli-overrides.js +107 -10
- package/dist/index.js +379 -99
- package/dist/utils/agent-helpers.d.ts +95 -0
- package/dist/utils/agent-helpers.d.ts.map +1 -0
- package/dist/utils/agent-helpers.js +117 -0
- package/dist/webui/assets/index-8j-KMkX1.js +2054 -0
- package/dist/webui/assets/index-c_AX24V4.css +1 -0
- package/dist/webui/assets/{tanstack-DgxBONJY.js → tanstack-Br79RQ-n.js} +1 -1
- package/dist/webui/index.html +4 -10
- package/dist/webui/logos/aws-color.svg +1 -0
- package/dist/webui/logos/dexto/dexto_logo.svg +1 -1
- package/dist/webui/logos/dexto/dexto_logo_light.svg +6 -6
- package/dist/webui/logos/glama.svg +7 -0
- package/dist/webui/logos/litellm.svg +7 -0
- package/dist/webui/logos/openrouter.svg +1 -0
- package/package.json +18 -15
- package/dist/cli/commands/interactive-commands/index.d.ts +0 -63
- package/dist/cli/commands/interactive-commands/index.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/index.js +0 -73
- package/dist/cli/commands/interactive-commands/mcp/mcp-add-utils.d.ts +0 -34
- package/dist/cli/commands/interactive-commands/mcp/mcp-add-utils.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/mcp/mcp-add-utils.js +0 -178
- package/dist/cli/commands/interactive-commands/mcp/mcp-commands.d.ts +0 -9
- package/dist/cli/commands/interactive-commands/mcp/mcp-commands.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/mcp/mcp-commands.js +0 -325
- package/dist/cli/commands/interactive-commands/model/model-commands.d.ts +0 -21
- package/dist/cli/commands/interactive-commands/model/model-commands.d.ts.map +0 -1
- package/dist/cli/commands/interactive-commands/model/model-commands.js +0 -190
- package/dist/cli/ink-cli/components/MultiLineTextInput.d.ts +0 -26
- package/dist/cli/ink-cli/components/MultiLineTextInput.d.ts.map +0 -1
- package/dist/cli/ink-cli/components/MultiLineTextInput.js +0 -220
- package/dist/discord/bot.d.ts +0 -4
- package/dist/discord/bot.d.ts.map +0 -1
- package/dist/discord/bot.js +0 -193
- package/dist/telegram/bot.d.ts +0 -5
- package/dist/telegram/bot.d.ts.map +0 -1
- package/dist/telegram/bot.js +0 -251
- package/dist/webui/assets/index-DKq5Xng1.js +0 -687
- package/dist/webui/assets/index-D_0_GBu5.css +0 -1
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Model Commands Module
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
4
|
+
* In interactive CLI, /model always shows the interactive model selector overlay.
|
|
5
|
+
* This command definition exists for autocomplete and help display.
|
|
6
|
+
*/
|
|
7
|
+
import type { CommandDefinition } from '../command-parser.js';
|
|
8
|
+
/**
|
|
9
|
+
* Model management command definition
|
|
10
|
+
* Always shows the interactive model selector overlay (handled by ALWAYS_OVERLAY)
|
|
9
11
|
*/
|
|
10
|
-
export
|
|
12
|
+
export declare const modelCommands: CommandDefinition;
|
|
11
13
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/cli/commands/interactive-commands/model/index.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/cli/commands/interactive-commands/model/index.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,EAAE,iBAAiB,EAAwB,MAAM,sBAAsB,CAAC;AAEpF;;;GAGG;AACH,eAAO,MAAM,aAAa,EAAE,iBAW3B,CAAC"}
|
|
@@ -1,10 +1,22 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Model Commands Module
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
*
|
|
4
|
+
* In interactive CLI, /model always shows the interactive model selector overlay.
|
|
5
|
+
* This command definition exists for autocomplete and help display.
|
|
6
|
+
*/
|
|
7
|
+
/**
|
|
8
|
+
* Model management command definition
|
|
9
|
+
* Always shows the interactive model selector overlay (handled by ALWAYS_OVERLAY)
|
|
9
10
|
*/
|
|
10
|
-
export
|
|
11
|
+
export const modelCommands = {
|
|
12
|
+
name: 'model',
|
|
13
|
+
description: 'Switch AI model (interactive selector)',
|
|
14
|
+
usage: '/model',
|
|
15
|
+
category: 'General',
|
|
16
|
+
aliases: ['m'],
|
|
17
|
+
handler: async () => {
|
|
18
|
+
// This handler is never called - model is in ALWAYS_OVERLAY
|
|
19
|
+
// which intercepts and shows the model selector overlay instead
|
|
20
|
+
return true;
|
|
21
|
+
},
|
|
22
|
+
};
|
|
@@ -9,14 +9,15 @@
|
|
|
9
9
|
* - /prompts - List all available prompts (MCP + internal)
|
|
10
10
|
* - /<prompt-name> [args] - Direct prompt execution (auto-generated for each prompt)
|
|
11
11
|
*/
|
|
12
|
-
import {
|
|
12
|
+
import type { DextoAgent } from '@dexto/core';
|
|
13
13
|
import type { CommandDefinition } from './command-parser.js';
|
|
14
14
|
/**
|
|
15
15
|
* Prompt management commands
|
|
16
16
|
*/
|
|
17
17
|
export declare const promptCommands: CommandDefinition[];
|
|
18
18
|
/**
|
|
19
|
-
* Get all dynamic prompt commands based on available prompts
|
|
19
|
+
* Get all dynamic prompt commands based on available prompts.
|
|
20
|
+
* Handles displayName collisions by prefixing with source (e.g., config:review).
|
|
20
21
|
*/
|
|
21
22
|
export declare function getDynamicPromptCommands(agent: DextoAgent): Promise<CommandDefinition[]>;
|
|
22
23
|
//# sourceMappingURL=prompt-commands.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"prompt-commands.d.ts","sourceRoot":"","sources":["../../../../src/cli/commands/interactive-commands/prompt-commands.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAGH,OAAO,
|
|
1
|
+
{"version":3,"file":"prompt-commands.d.ts","sourceRoot":"","sources":["../../../../src/cli/commands/interactive-commands/prompt-commands.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAGH,OAAO,KAAK,EAAE,UAAU,EAAc,MAAM,aAAa,CAAC;AAC1D,OAAO,KAAK,EAAE,iBAAiB,EAAwC,MAAM,qBAAqB,CAAC;AAKnG;;GAEG;AACH,eAAO,MAAM,cAAc,EAAE,iBAAiB,EA8L7C,CAAC;AAwFF;;;GAGG;AACH,wBAAsB,wBAAwB,CAAC,KAAK,EAAE,UAAU,GAAG,OAAO,CAAC,iBAAiB,EAAE,CAAC,CAwB9F"}
|
|
@@ -10,9 +10,8 @@
|
|
|
10
10
|
* - /<prompt-name> [args] - Direct prompt execution (auto-generated for each prompt)
|
|
11
11
|
*/
|
|
12
12
|
import chalk from 'chalk';
|
|
13
|
-
import { logger } from '@dexto/core';
|
|
14
|
-
import { getCLISessionId } from './command-parser.js';
|
|
15
13
|
import { formatForInkCli } from './utils/format-output.js';
|
|
14
|
+
import { createSendMessageMarker } from '../../ink-cli/services/index.js';
|
|
16
15
|
// Avoid depending on core types to keep CLI typecheck independent of build
|
|
17
16
|
/**
|
|
18
17
|
* Prompt management commands
|
|
@@ -23,36 +22,36 @@ export const promptCommands = [
|
|
|
23
22
|
description: 'Display the current system prompt',
|
|
24
23
|
usage: '/sysprompt',
|
|
25
24
|
category: 'Prompt Management',
|
|
26
|
-
handler: async (
|
|
25
|
+
handler: async (_args, agent, _ctx) => {
|
|
27
26
|
try {
|
|
28
27
|
const systemPrompt = await agent.getSystemPrompt();
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
return
|
|
28
|
+
// Return styled output for ink-cli
|
|
29
|
+
const styledOutput = {
|
|
30
|
+
styledType: 'sysprompt',
|
|
31
|
+
styledData: { content: systemPrompt },
|
|
32
|
+
fallbackText: `System Prompt:\n${systemPrompt}`,
|
|
33
|
+
};
|
|
34
|
+
return styledOutput;
|
|
36
35
|
}
|
|
37
36
|
catch (error) {
|
|
38
37
|
const errorMsg = `Failed to get system prompt: ${error instanceof Error ? error.message : String(error)}`;
|
|
39
|
-
logger.error(errorMsg);
|
|
38
|
+
agent.logger.error(errorMsg);
|
|
40
39
|
return formatForInkCli(`❌ ${errorMsg}`);
|
|
41
40
|
}
|
|
42
41
|
},
|
|
43
42
|
},
|
|
44
43
|
{
|
|
45
44
|
name: 'prompts',
|
|
46
|
-
description: '
|
|
45
|
+
description: 'Browse, add, and delete prompts',
|
|
47
46
|
usage: '/prompts',
|
|
48
47
|
category: 'Prompt Management',
|
|
49
|
-
handler: async (_args, agent) => {
|
|
48
|
+
handler: async (_args, agent, _ctx) => {
|
|
50
49
|
try {
|
|
51
50
|
const prompts = await agent.listPrompts();
|
|
52
51
|
const promptNames = Object.keys(prompts || {});
|
|
53
52
|
if (promptNames.length === 0) {
|
|
54
53
|
const output = '\n⚠️ No prompts available';
|
|
55
|
-
console.log(chalk.
|
|
54
|
+
console.log(chalk.rgb(255, 165, 0)(output));
|
|
56
55
|
return formatForInkCli(output);
|
|
57
56
|
}
|
|
58
57
|
// Build output string
|
|
@@ -77,14 +76,15 @@ export const promptCommands = [
|
|
|
77
76
|
mcpPrompts.forEach((name) => {
|
|
78
77
|
const info = prompts[name];
|
|
79
78
|
if (info) {
|
|
80
|
-
const
|
|
79
|
+
const displayName = info.displayName || name;
|
|
80
|
+
const title = info.title && info.title !== displayName ? ` (${info.title})` : '';
|
|
81
81
|
const desc = info.description ? ` - ${info.description}` : '';
|
|
82
82
|
const args = info.arguments && info.arguments.length > 0
|
|
83
83
|
? ` [args: ${info.arguments
|
|
84
84
|
.map((a) => `${a.name}${a.required ? '*' : ''}`)
|
|
85
85
|
.join(', ')}]`
|
|
86
86
|
: '';
|
|
87
|
-
outputLines.push(` ${
|
|
87
|
+
outputLines.push(` ${displayName}${title}${desc}${args}`);
|
|
88
88
|
}
|
|
89
89
|
});
|
|
90
90
|
outputLines.push('');
|
|
@@ -94,9 +94,10 @@ export const promptCommands = [
|
|
|
94
94
|
configPrompts.forEach((name) => {
|
|
95
95
|
const info = prompts[name];
|
|
96
96
|
if (info) {
|
|
97
|
-
const
|
|
97
|
+
const displayName = info.displayName || name;
|
|
98
|
+
const title = info.title && info.title !== displayName ? ` (${info.title})` : '';
|
|
98
99
|
const desc = info.description ? ` - ${info.description}` : '';
|
|
99
|
-
outputLines.push(` ${
|
|
100
|
+
outputLines.push(` ${displayName}${title}${desc}`);
|
|
100
101
|
}
|
|
101
102
|
});
|
|
102
103
|
outputLines.push('');
|
|
@@ -106,9 +107,10 @@ export const promptCommands = [
|
|
|
106
107
|
customPrompts.forEach((name) => {
|
|
107
108
|
const info = prompts[name];
|
|
108
109
|
if (info) {
|
|
109
|
-
const
|
|
110
|
+
const displayName = info.displayName || name;
|
|
111
|
+
const title = info.title && info.title !== displayName ? ` (${info.title})` : '';
|
|
110
112
|
const desc = info.description ? ` - ${info.description}` : '';
|
|
111
|
-
outputLines.push(` ${
|
|
113
|
+
outputLines.push(` ${displayName}${title}${desc}`);
|
|
112
114
|
}
|
|
113
115
|
});
|
|
114
116
|
outputLines.push('');
|
|
@@ -122,26 +124,28 @@ export const promptCommands = [
|
|
|
122
124
|
mcpPrompts.forEach((name) => {
|
|
123
125
|
const info = prompts[name];
|
|
124
126
|
if (info) {
|
|
125
|
-
const
|
|
127
|
+
const displayName = info.displayName || name;
|
|
128
|
+
const title = info.title && info.title !== displayName ? ` (${info.title})` : '';
|
|
126
129
|
const desc = info.description ? ` - ${info.description}` : '';
|
|
127
130
|
const args = info.arguments && info.arguments.length > 0
|
|
128
131
|
? ` [args: ${info.arguments
|
|
129
132
|
.map((a) => `${a.name}${a.required ? '*' : ''}`)
|
|
130
133
|
.join(', ')}]`
|
|
131
134
|
: '';
|
|
132
|
-
console.log(` ${chalk.blue(
|
|
135
|
+
console.log(` ${chalk.blue(displayName)}${chalk.rgb(255, 165, 0)(title)}${chalk.gray(desc)}${chalk.gray(args)}`);
|
|
133
136
|
}
|
|
134
137
|
});
|
|
135
138
|
console.log();
|
|
136
139
|
}
|
|
137
140
|
if (configPrompts.length > 0) {
|
|
138
|
-
console.log(chalk.
|
|
141
|
+
console.log(chalk.cyan('📋 Config Prompts:'));
|
|
139
142
|
configPrompts.forEach((name) => {
|
|
140
143
|
const info = prompts[name];
|
|
141
144
|
if (info) {
|
|
142
|
-
const
|
|
145
|
+
const displayName = info.displayName || name;
|
|
146
|
+
const title = info.title && info.title !== displayName ? ` (${info.title})` : '';
|
|
143
147
|
const desc = info.description ? ` - ${info.description}` : '';
|
|
144
|
-
console.log(` ${chalk.blue(
|
|
148
|
+
console.log(` ${chalk.blue(displayName)}${chalk.rgb(255, 165, 0)(title)}${chalk.gray(desc)}`);
|
|
145
149
|
}
|
|
146
150
|
});
|
|
147
151
|
console.log();
|
|
@@ -151,15 +155,16 @@ export const promptCommands = [
|
|
|
151
155
|
customPrompts.forEach((name) => {
|
|
152
156
|
const info = prompts[name];
|
|
153
157
|
if (info) {
|
|
154
|
-
const
|
|
158
|
+
const displayName = info.displayName || name;
|
|
159
|
+
const title = info.title && info.title !== displayName ? ` (${info.title})` : '';
|
|
155
160
|
const desc = info.description ? ` - ${info.description}` : '';
|
|
156
|
-
console.log(` ${chalk.blue(
|
|
161
|
+
console.log(` ${chalk.blue(displayName)}${chalk.rgb(255, 165, 0)(title)}${chalk.gray(desc)}`);
|
|
157
162
|
}
|
|
158
163
|
});
|
|
159
164
|
console.log();
|
|
160
165
|
}
|
|
161
|
-
console.log(chalk.
|
|
162
|
-
console.log(chalk.
|
|
166
|
+
console.log(chalk.gray(`Total: ${promptNames.length} prompts`));
|
|
167
|
+
console.log(chalk.gray('💡 Use /<prompt-name> to execute a prompt directly\n'));
|
|
163
168
|
return formatForInkCli(output);
|
|
164
169
|
}
|
|
165
170
|
catch (error) {
|
|
@@ -174,27 +179,34 @@ export const promptCommands = [
|
|
|
174
179
|
];
|
|
175
180
|
/**
|
|
176
181
|
* Create a dynamic command definition from a prompt
|
|
182
|
+
* @param promptInfo The prompt metadata
|
|
183
|
+
* @param hasCollision Whether this prompt's displayName collides with another
|
|
177
184
|
*/
|
|
178
|
-
function createPromptCommand(promptInfo) {
|
|
185
|
+
function createPromptCommand(promptInfo, hasCollision) {
|
|
186
|
+
const baseName = promptInfo.displayName || promptInfo.name;
|
|
187
|
+
// Add source prefix if collision (e.g., "config:review" or "mcp:review")
|
|
188
|
+
const commandName = hasCollision ? `${promptInfo.source}:${baseName}` : baseName;
|
|
189
|
+
// Keep internal name for prompt resolution (e.g., "config:review" or "mcp:server1:review")
|
|
190
|
+
const internalName = promptInfo.name;
|
|
179
191
|
return {
|
|
180
|
-
name:
|
|
181
|
-
description: promptInfo.description || `Execute ${
|
|
182
|
-
usage: `/${
|
|
192
|
+
name: commandName,
|
|
193
|
+
description: promptInfo.description || `Execute ${baseName} prompt`,
|
|
194
|
+
usage: `/${commandName} [context]`,
|
|
183
195
|
category: 'Dynamic Prompts',
|
|
184
|
-
handler: async (args, agent) => {
|
|
196
|
+
handler: async (args, agent, _ctx) => {
|
|
185
197
|
try {
|
|
186
198
|
const { argMap, context: contextString } = splitPromptArguments(args);
|
|
187
199
|
if (Object.keys(argMap).length > 0) {
|
|
188
|
-
console.log(chalk.cyan(`🤖 Executing prompt: ${
|
|
189
|
-
console.log(chalk.
|
|
200
|
+
console.log(chalk.cyan(`🤖 Executing prompt: ${commandName}`));
|
|
201
|
+
console.log(chalk.gray(`Explicit arguments: ${JSON.stringify(argMap)}`));
|
|
190
202
|
}
|
|
191
203
|
else if (contextString) {
|
|
192
|
-
console.log(chalk.cyan(`🤖 Executing prompt: ${
|
|
193
|
-
console.log(chalk.
|
|
204
|
+
console.log(chalk.cyan(`🤖 Executing prompt: ${commandName}`));
|
|
205
|
+
console.log(chalk.gray(`Context: ${contextString} (LLM will extrapolate template variables)`));
|
|
194
206
|
}
|
|
195
207
|
else {
|
|
196
|
-
console.log(chalk.cyan(`🤖 Executing prompt: ${
|
|
197
|
-
console.log(chalk.
|
|
208
|
+
console.log(chalk.cyan(`🤖 Executing prompt: ${commandName}`));
|
|
209
|
+
console.log(chalk.gray('No arguments provided - LLM will extrapolate from context'));
|
|
198
210
|
}
|
|
199
211
|
// Use resolvePrompt instead of getPrompt + flattenPromptResult (matches WebUI approach)
|
|
200
212
|
const resolveOptions = {};
|
|
@@ -204,7 +216,8 @@ function createPromptCommand(promptInfo) {
|
|
|
204
216
|
if (contextString) {
|
|
205
217
|
resolveOptions.context = contextString;
|
|
206
218
|
}
|
|
207
|
-
|
|
219
|
+
// Use internal name for resolution (includes prefix like "config:")
|
|
220
|
+
const result = await agent.resolvePrompt(internalName, resolveOptions);
|
|
208
221
|
// Convert resource URIs to @resource mentions so agent.run() can expand them
|
|
209
222
|
let finalText = result.text;
|
|
210
223
|
if (result.resources.length > 0) {
|
|
@@ -213,44 +226,48 @@ function createPromptCommand(promptInfo) {
|
|
|
213
226
|
finalText = finalText ? `${finalText}\n\n${resourceRefs}` : resourceRefs;
|
|
214
227
|
}
|
|
215
228
|
if (finalText.trim()) {
|
|
216
|
-
//
|
|
217
|
-
// This
|
|
218
|
-
|
|
219
|
-
if (!sessionId) {
|
|
220
|
-
const errorMsg = '❌ No active session. This should not happen in interactive mode.';
|
|
221
|
-
console.error(chalk.red(errorMsg));
|
|
222
|
-
return formatForInkCli(errorMsg);
|
|
223
|
-
}
|
|
224
|
-
await agent.run(finalText.trim(), undefined, undefined, sessionId);
|
|
225
|
-
// Return empty string to indicate command handled (ink-cli will show the message)
|
|
226
|
-
return '';
|
|
229
|
+
// Return the resolved text so CLI can send it through normal streaming flow
|
|
230
|
+
// This matches WebUI behavior: resolvePrompt() -> handleSend(text)
|
|
231
|
+
return createSendMessageMarker(finalText.trim());
|
|
227
232
|
}
|
|
228
233
|
else {
|
|
229
|
-
const warningMsg = `⚠️ Prompt '${
|
|
230
|
-
console.log(chalk.
|
|
234
|
+
const warningMsg = `⚠️ Prompt '${commandName}' returned no content`;
|
|
235
|
+
console.log(chalk.rgb(255, 165, 0)(warningMsg));
|
|
231
236
|
return formatForInkCli(warningMsg);
|
|
232
237
|
}
|
|
233
238
|
}
|
|
234
239
|
catch (error) {
|
|
235
240
|
const errorMessage = error instanceof Error ? error.message : String(error);
|
|
236
|
-
logger.error(`Failed to execute prompt command '${
|
|
237
|
-
const errorMsg = `❌ Error executing prompt '${
|
|
238
|
-
console.log(chalk.red(errorMsg));
|
|
241
|
+
agent.logger.error(`Failed to execute prompt command '${commandName}': ${errorMessage}`);
|
|
242
|
+
const errorMsg = `❌ Error executing prompt '${commandName}': ${errorMessage}`;
|
|
239
243
|
return formatForInkCli(errorMsg);
|
|
240
244
|
}
|
|
241
245
|
},
|
|
242
246
|
};
|
|
243
247
|
}
|
|
244
248
|
/**
|
|
245
|
-
* Get all dynamic prompt commands based on available prompts
|
|
249
|
+
* Get all dynamic prompt commands based on available prompts.
|
|
250
|
+
* Handles displayName collisions by prefixing with source (e.g., config:review).
|
|
246
251
|
*/
|
|
247
252
|
export async function getDynamicPromptCommands(agent) {
|
|
248
253
|
try {
|
|
249
254
|
const prompts = await agent.listPrompts();
|
|
250
|
-
|
|
255
|
+
const promptEntries = Object.entries(prompts);
|
|
256
|
+
// Build frequency map of displayNames to detect collisions
|
|
257
|
+
const displayNameCounts = new Map();
|
|
258
|
+
for (const [, info] of promptEntries) {
|
|
259
|
+
const displayName = info.displayName || info.name;
|
|
260
|
+
displayNameCounts.set(displayName, (displayNameCounts.get(displayName) || 0) + 1);
|
|
261
|
+
}
|
|
262
|
+
// Create commands with conditional prefixing
|
|
263
|
+
return promptEntries.map(([, info]) => {
|
|
264
|
+
const displayName = info.displayName || info.name;
|
|
265
|
+
const hasCollision = (displayNameCounts.get(displayName) || 0) > 1;
|
|
266
|
+
return createPromptCommand(info, hasCollision);
|
|
267
|
+
});
|
|
251
268
|
}
|
|
252
269
|
catch (error) {
|
|
253
|
-
logger.error(`Failed to get dynamic prompt commands: ${error instanceof Error ? error.message : String(error)}`);
|
|
270
|
+
agent.logger.error(`Failed to get dynamic prompt commands: ${error instanceof Error ? error.message : String(error)}`);
|
|
254
271
|
return [];
|
|
255
272
|
}
|
|
256
273
|
}
|
|
@@ -1,19 +1,14 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Session Commands Module
|
|
2
|
+
* Session Commands Module (Interactive CLI)
|
|
3
3
|
*
|
|
4
|
-
* This module provides
|
|
5
|
-
*
|
|
4
|
+
* This module provides session-related commands for the interactive CLI.
|
|
5
|
+
* These commands use interactive overlays/selectors rather than subcommands.
|
|
6
6
|
*
|
|
7
7
|
* Exports:
|
|
8
|
-
* -
|
|
9
|
-
* -
|
|
10
|
-
* - resumeCommand: Standalone resume command
|
|
11
|
-
* - sessionCommands: Array of all session-related commands
|
|
12
|
-
* - Formatter utilities from helpers (re-exported for convenience)
|
|
8
|
+
* - searchCommand: Opens interactive search overlay
|
|
9
|
+
* - resumeCommand: Shows interactive session selector
|
|
13
10
|
*
|
|
14
|
-
* Note:
|
|
11
|
+
* Note: For headless CLI session management, see src/cli/commands/session-commands.ts
|
|
15
12
|
*/
|
|
16
|
-
export {
|
|
17
|
-
export { formatSessionInfo, formatHistoryMessage } from '../../helpers/formatters.js';
|
|
18
|
-
export declare const sessionCommands: import("../command-parser.js").CommandDefinition[];
|
|
13
|
+
export { searchCommand, resumeCommand } from './session-commands.js';
|
|
19
14
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/cli/commands/interactive-commands/session/index.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/cli/commands/interactive-commands/session/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAE,aAAa,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC"}
|
|
@@ -1,20 +1,13 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Session Commands Module
|
|
2
|
+
* Session Commands Module (Interactive CLI)
|
|
3
3
|
*
|
|
4
|
-
* This module provides
|
|
5
|
-
*
|
|
4
|
+
* This module provides session-related commands for the interactive CLI.
|
|
5
|
+
* These commands use interactive overlays/selectors rather than subcommands.
|
|
6
6
|
*
|
|
7
7
|
* Exports:
|
|
8
|
-
* -
|
|
9
|
-
* -
|
|
10
|
-
* - resumeCommand: Standalone resume command
|
|
11
|
-
* - sessionCommands: Array of all session-related commands
|
|
12
|
-
* - Formatter utilities from helpers (re-exported for convenience)
|
|
8
|
+
* - searchCommand: Opens interactive search overlay
|
|
9
|
+
* - resumeCommand: Shows interactive session selector
|
|
13
10
|
*
|
|
14
|
-
* Note:
|
|
11
|
+
* Note: For headless CLI session management, see src/cli/commands/session-commands.ts
|
|
15
12
|
*/
|
|
16
|
-
export {
|
|
17
|
-
export { formatSessionInfo, formatHistoryMessage } from '../../helpers/formatters.js';
|
|
18
|
-
// Export all session commands as a convenient array
|
|
19
|
-
import { sessionCommand, searchCommand, resumeCommand } from './session-commands.js';
|
|
20
|
-
export const sessionCommands = [sessionCommand, searchCommand, resumeCommand];
|
|
13
|
+
export { searchCommand, resumeCommand } from './session-commands.js';
|
|
@@ -1,31 +1,17 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Session Management Commands
|
|
2
|
+
* Session Management Commands (Interactive CLI)
|
|
3
3
|
*
|
|
4
|
-
* This module contains
|
|
5
|
-
*
|
|
6
|
-
* and searching sessions.
|
|
4
|
+
* This module contains session-related commands for the interactive CLI.
|
|
5
|
+
* Session management in interactive mode uses overlays/selectors rather than subcommands.
|
|
7
6
|
*
|
|
8
|
-
*
|
|
9
|
-
* -
|
|
10
|
-
* -
|
|
11
|
-
* - switch: Switch to a different session
|
|
12
|
-
* - current: Show current active session info
|
|
13
|
-
* - delete: Delete a session (cannot delete active session)
|
|
14
|
-
* - help: Show detailed help for session commands
|
|
7
|
+
* Commands:
|
|
8
|
+
* - resume: Shows interactive session selector
|
|
9
|
+
* - search: Opens interactive search overlay
|
|
15
10
|
*
|
|
16
|
-
*
|
|
17
|
-
*
|
|
18
|
-
* - search: Search session history across sessions
|
|
11
|
+
* Note: For headless CLI session management (list, history, delete),
|
|
12
|
+
* see src/cli/commands/session-commands.ts
|
|
19
13
|
*/
|
|
20
|
-
import { CommandDefinition } from '../command-parser.js';
|
|
21
|
-
/**
|
|
22
|
-
* Session management commands
|
|
23
|
-
*/
|
|
24
|
-
export declare const sessionCommand: CommandDefinition;
|
|
25
|
-
/**
|
|
26
|
-
* Standalone history command for quick access
|
|
27
|
-
*/
|
|
28
|
-
export declare const historyCommand: CommandDefinition;
|
|
14
|
+
import type { CommandDefinition } from '../command-parser.js';
|
|
29
15
|
/**
|
|
30
16
|
* Resume command - shows interactive session selector
|
|
31
17
|
* Note: In interactive CLI, this always shows the selector (args ignored)
|
|
@@ -33,7 +19,7 @@ export declare const historyCommand: CommandDefinition;
|
|
|
33
19
|
*/
|
|
34
20
|
export declare const resumeCommand: CommandDefinition;
|
|
35
21
|
/**
|
|
36
|
-
* Standalone search command
|
|
22
|
+
* Standalone search command - opens interactive search overlay
|
|
37
23
|
*/
|
|
38
24
|
export declare const searchCommand: CommandDefinition;
|
|
39
25
|
//# sourceMappingURL=session-commands.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"session-commands.d.ts","sourceRoot":"","sources":["../../../../../src/cli/commands/interactive-commands/session/session-commands.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"session-commands.d.ts","sourceRoot":"","sources":["../../../../../src/cli/commands/interactive-commands/session/session-commands.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAIH,OAAO,KAAK,EAAE,iBAAiB,EAAkB,MAAM,sBAAsB,CAAC;AAE9E;;;;GAIG;AACH,eAAO,MAAM,aAAa,EAAE,iBAsB3B,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,aAAa,EAAE,iBAc3B,CAAC"}
|