@trenchwork/erosolar 1.1.16
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/LICENSE +21 -0
- package/README.md +232 -0
- package/agents/erosolar-code.rules.json +199 -0
- package/dist/bin/cliMode.d.ts +8 -0
- package/dist/bin/cliMode.d.ts.map +1 -0
- package/dist/bin/cliMode.js +20 -0
- package/dist/bin/cliMode.js.map +1 -0
- package/dist/bin/deepseek.d.ts +3 -0
- package/dist/bin/deepseek.d.ts.map +1 -0
- package/dist/bin/deepseek.js +232 -0
- package/dist/bin/deepseek.js.map +1 -0
- package/dist/bin/erosolar.d.ts +7 -0
- package/dist/bin/erosolar.d.ts.map +1 -0
- package/dist/bin/erosolar.js +7 -0
- package/dist/bin/erosolar.js.map +1 -0
- package/dist/bin/selfTest.d.ts +14 -0
- package/dist/bin/selfTest.d.ts.map +1 -0
- package/dist/bin/selfTest.js +298 -0
- package/dist/bin/selfTest.js.map +1 -0
- package/dist/capabilities/baseCapability.d.ts +72 -0
- package/dist/capabilities/baseCapability.d.ts.map +1 -0
- package/dist/capabilities/baseCapability.js +183 -0
- package/dist/capabilities/baseCapability.js.map +1 -0
- package/dist/capabilities/bashCapability.d.ts +13 -0
- package/dist/capabilities/bashCapability.d.ts.map +1 -0
- package/dist/capabilities/bashCapability.js +24 -0
- package/dist/capabilities/bashCapability.js.map +1 -0
- package/dist/capabilities/editCapability.d.ts +17 -0
- package/dist/capabilities/editCapability.d.ts.map +1 -0
- package/dist/capabilities/editCapability.js +27 -0
- package/dist/capabilities/editCapability.js.map +1 -0
- package/dist/capabilities/enhancedGitCapability.d.ts +7 -0
- package/dist/capabilities/enhancedGitCapability.d.ts.map +1 -0
- package/dist/capabilities/enhancedGitCapability.js +220 -0
- package/dist/capabilities/enhancedGitCapability.js.map +1 -0
- package/dist/capabilities/filesystemCapability.d.ts +13 -0
- package/dist/capabilities/filesystemCapability.d.ts.map +1 -0
- package/dist/capabilities/filesystemCapability.js +24 -0
- package/dist/capabilities/filesystemCapability.js.map +1 -0
- package/dist/capabilities/gitHistoryCapability.d.ts +6 -0
- package/dist/capabilities/gitHistoryCapability.d.ts.map +1 -0
- package/dist/capabilities/gitHistoryCapability.js +184 -0
- package/dist/capabilities/gitHistoryCapability.js.map +1 -0
- package/dist/capabilities/hitlCapability.d.ts +18 -0
- package/dist/capabilities/hitlCapability.d.ts.map +1 -0
- package/dist/capabilities/hitlCapability.js +29 -0
- package/dist/capabilities/hitlCapability.js.map +1 -0
- package/dist/capabilities/index.d.ts +13 -0
- package/dist/capabilities/index.d.ts.map +1 -0
- package/dist/capabilities/index.js +18 -0
- package/dist/capabilities/index.js.map +1 -0
- package/dist/capabilities/kaliCapability.d.ts +14 -0
- package/dist/capabilities/kaliCapability.d.ts.map +1 -0
- package/dist/capabilities/kaliCapability.js +478 -0
- package/dist/capabilities/kaliCapability.js.map +1 -0
- package/dist/capabilities/mcpCapability.d.ts +7 -0
- package/dist/capabilities/mcpCapability.d.ts.map +1 -0
- package/dist/capabilities/mcpCapability.js +80 -0
- package/dist/capabilities/mcpCapability.js.map +1 -0
- package/dist/capabilities/memoryCapability.d.ts +10 -0
- package/dist/capabilities/memoryCapability.d.ts.map +1 -0
- package/dist/capabilities/memoryCapability.js +22 -0
- package/dist/capabilities/memoryCapability.js.map +1 -0
- package/dist/capabilities/notebookCapability.d.ts +6 -0
- package/dist/capabilities/notebookCapability.d.ts.map +1 -0
- package/dist/capabilities/notebookCapability.js +17 -0
- package/dist/capabilities/notebookCapability.js.map +1 -0
- package/dist/capabilities/searchCapability.d.ts +19 -0
- package/dist/capabilities/searchCapability.d.ts.map +1 -0
- package/dist/capabilities/searchCapability.js +29 -0
- package/dist/capabilities/searchCapability.js.map +1 -0
- package/dist/capabilities/skillCapability.d.ts +6 -0
- package/dist/capabilities/skillCapability.d.ts.map +1 -0
- package/dist/capabilities/skillCapability.js +17 -0
- package/dist/capabilities/skillCapability.js.map +1 -0
- package/dist/capabilities/todoCapability.d.ts +11 -0
- package/dist/capabilities/todoCapability.d.ts.map +1 -0
- package/dist/capabilities/todoCapability.js +22 -0
- package/dist/capabilities/todoCapability.js.map +1 -0
- package/dist/capabilities/toolManifest.d.ts +3 -0
- package/dist/capabilities/toolManifest.d.ts.map +1 -0
- package/dist/capabilities/toolManifest.js +163 -0
- package/dist/capabilities/toolManifest.js.map +1 -0
- package/dist/capabilities/toolRegistry.d.ts +25 -0
- package/dist/capabilities/toolRegistry.d.ts.map +1 -0
- package/dist/capabilities/toolRegistry.js +150 -0
- package/dist/capabilities/toolRegistry.js.map +1 -0
- package/dist/capabilities/unifiedCodingCapability.d.ts +62 -0
- package/dist/capabilities/unifiedCodingCapability.d.ts.map +1 -0
- package/dist/capabilities/unifiedCodingCapability.js +788 -0
- package/dist/capabilities/unifiedCodingCapability.js.map +1 -0
- package/dist/capabilities/webCapability.d.ts +23 -0
- package/dist/capabilities/webCapability.d.ts.map +1 -0
- package/dist/capabilities/webCapability.js +33 -0
- package/dist/capabilities/webCapability.js.map +1 -0
- package/dist/config.d.ts +25 -0
- package/dist/config.d.ts.map +1 -0
- package/dist/config.js +155 -0
- package/dist/config.js.map +1 -0
- package/dist/contracts/agent-profiles.schema.json +43 -0
- package/dist/contracts/agent-schemas.json +470 -0
- package/dist/contracts/models.schema.json +9 -0
- package/dist/contracts/module-schema.json +367 -0
- package/dist/contracts/schemas/agent-profile.schema.json +157 -0
- package/dist/contracts/schemas/agent-rules.schema.json +238 -0
- package/dist/contracts/schemas/agent-schemas.schema.json +528 -0
- package/dist/contracts/schemas/agent.schema.json +90 -0
- package/dist/contracts/schemas/tool-selection.schema.json +174 -0
- package/dist/contracts/tools.schema.json +42 -0
- package/dist/contracts/unified-schema.json +660 -0
- package/dist/contracts/v1/agent.d.ts +179 -0
- package/dist/contracts/v1/agent.d.ts.map +1 -0
- package/dist/contracts/v1/agent.js +8 -0
- package/dist/contracts/v1/agent.js.map +1 -0
- package/dist/contracts/v1/agentProfileManifest.d.ts +60 -0
- package/dist/contracts/v1/agentProfileManifest.d.ts.map +1 -0
- package/dist/contracts/v1/agentProfileManifest.js +9 -0
- package/dist/contracts/v1/agentProfileManifest.js.map +1 -0
- package/dist/contracts/v1/agentRules.d.ts +60 -0
- package/dist/contracts/v1/agentRules.d.ts.map +1 -0
- package/dist/contracts/v1/agentRules.js +10 -0
- package/dist/contracts/v1/agentRules.js.map +1 -0
- package/dist/contracts/v1/provider.d.ts +149 -0
- package/dist/contracts/v1/provider.d.ts.map +1 -0
- package/dist/contracts/v1/provider.js +7 -0
- package/dist/contracts/v1/provider.js.map +1 -0
- package/dist/contracts/v1/tool.d.ts +136 -0
- package/dist/contracts/v1/tool.d.ts.map +1 -0
- package/dist/contracts/v1/tool.js +7 -0
- package/dist/contracts/v1/tool.js.map +1 -0
- package/dist/contracts/v1/toolAccess.d.ts +43 -0
- package/dist/contracts/v1/toolAccess.d.ts.map +1 -0
- package/dist/contracts/v1/toolAccess.js +9 -0
- package/dist/contracts/v1/toolAccess.js.map +1 -0
- package/dist/core/agent.d.ts +320 -0
- package/dist/core/agent.d.ts.map +1 -0
- package/dist/core/agent.js +1627 -0
- package/dist/core/agent.js.map +1 -0
- package/dist/core/agentProfileManifest.d.ts +3 -0
- package/dist/core/agentProfileManifest.d.ts.map +1 -0
- package/dist/core/agentProfileManifest.js +188 -0
- package/dist/core/agentProfileManifest.js.map +1 -0
- package/dist/core/agentProfiles.d.ts +22 -0
- package/dist/core/agentProfiles.d.ts.map +1 -0
- package/dist/core/agentProfiles.js +35 -0
- package/dist/core/agentProfiles.js.map +1 -0
- package/dist/core/agentRegistry.d.ts +111 -0
- package/dist/core/agentRegistry.d.ts.map +1 -0
- package/dist/core/agentRegistry.js +229 -0
- package/dist/core/agentRegistry.js.map +1 -0
- package/dist/core/agentRulebook.d.ts +11 -0
- package/dist/core/agentRulebook.d.ts.map +1 -0
- package/dist/core/agentRulebook.js +136 -0
- package/dist/core/agentRulebook.js.map +1 -0
- package/dist/core/agentSchemaLoader.d.ts +131 -0
- package/dist/core/agentSchemaLoader.d.ts.map +1 -0
- package/dist/core/agentSchemaLoader.js +235 -0
- package/dist/core/agentSchemaLoader.js.map +1 -0
- package/dist/core/aiErrorFixer.d.ts +57 -0
- package/dist/core/aiErrorFixer.d.ts.map +1 -0
- package/dist/core/aiErrorFixer.js +214 -0
- package/dist/core/aiErrorFixer.js.map +1 -0
- package/dist/core/auth.d.ts +15 -0
- package/dist/core/auth.d.ts.map +1 -0
- package/dist/core/auth.js +291 -0
- package/dist/core/auth.js.map +1 -0
- package/dist/core/bashCommandGuidance.d.ts +16 -0
- package/dist/core/bashCommandGuidance.d.ts.map +1 -0
- package/dist/core/bashCommandGuidance.js +40 -0
- package/dist/core/bashCommandGuidance.js.map +1 -0
- package/dist/core/constants.d.ts +31 -0
- package/dist/core/constants.d.ts.map +1 -0
- package/dist/core/constants.js +62 -0
- package/dist/core/constants.js.map +1 -0
- package/dist/core/contextManager.d.ts +271 -0
- package/dist/core/contextManager.d.ts.map +1 -0
- package/dist/core/contextManager.js +1073 -0
- package/dist/core/contextManager.js.map +1 -0
- package/dist/core/contextWindow.d.ts +42 -0
- package/dist/core/contextWindow.d.ts.map +1 -0
- package/dist/core/contextWindow.js +123 -0
- package/dist/core/contextWindow.js.map +1 -0
- package/dist/core/customCommands.d.ts +19 -0
- package/dist/core/customCommands.d.ts.map +1 -0
- package/dist/core/customCommands.js +85 -0
- package/dist/core/customCommands.js.map +1 -0
- package/dist/core/errors/apiKeyErrors.d.ts +11 -0
- package/dist/core/errors/apiKeyErrors.d.ts.map +1 -0
- package/dist/core/errors/apiKeyErrors.js +159 -0
- package/dist/core/errors/apiKeyErrors.js.map +1 -0
- package/dist/core/errors/errorTypes.d.ts +111 -0
- package/dist/core/errors/errorTypes.d.ts.map +1 -0
- package/dist/core/errors/errorTypes.js +345 -0
- package/dist/core/errors/errorTypes.js.map +1 -0
- package/dist/core/errors/index.d.ts +50 -0
- package/dist/core/errors/index.d.ts.map +1 -0
- package/dist/core/errors/index.js +156 -0
- package/dist/core/errors/index.js.map +1 -0
- package/dist/core/errors/networkErrors.d.ts +14 -0
- package/dist/core/errors/networkErrors.d.ts.map +1 -0
- package/dist/core/errors/networkErrors.js +53 -0
- package/dist/core/errors/networkErrors.js.map +1 -0
- package/dist/core/errors/safetyValidator.d.ts +109 -0
- package/dist/core/errors/safetyValidator.d.ts.map +1 -0
- package/dist/core/errors/safetyValidator.js +271 -0
- package/dist/core/errors/safetyValidator.js.map +1 -0
- package/dist/core/errors.d.ts +4 -0
- package/dist/core/errors.d.ts.map +1 -0
- package/dist/core/errors.js +33 -0
- package/dist/core/errors.js.map +1 -0
- package/dist/core/finalResponseFormatter.d.ts +10 -0
- package/dist/core/finalResponseFormatter.d.ts.map +1 -0
- package/dist/core/finalResponseFormatter.js +14 -0
- package/dist/core/finalResponseFormatter.js.map +1 -0
- package/dist/core/guardrails.d.ts +146 -0
- package/dist/core/guardrails.d.ts.map +1 -0
- package/dist/core/guardrails.js +361 -0
- package/dist/core/guardrails.js.map +1 -0
- package/dist/core/hitl.d.ts +119 -0
- package/dist/core/hitl.d.ts.map +1 -0
- package/dist/core/hitl.js +387 -0
- package/dist/core/hitl.js.map +1 -0
- package/dist/core/hooks.d.ts +95 -0
- package/dist/core/hooks.d.ts.map +1 -0
- package/dist/core/hooks.js +239 -0
- package/dist/core/hooks.js.map +1 -0
- package/dist/core/index.d.ts +7 -0
- package/dist/core/index.d.ts.map +1 -0
- package/dist/core/index.js +7 -0
- package/dist/core/index.js.map +1 -0
- package/dist/core/inputProtection.d.ts +122 -0
- package/dist/core/inputProtection.d.ts.map +1 -0
- package/dist/core/inputProtection.js +422 -0
- package/dist/core/inputProtection.js.map +1 -0
- package/dist/core/modelDiscovery.d.ts +105 -0
- package/dist/core/modelDiscovery.d.ts.map +1 -0
- package/dist/core/modelDiscovery.js +768 -0
- package/dist/core/modelDiscovery.js.map +1 -0
- package/dist/core/multilinePasteHandler.d.ts +35 -0
- package/dist/core/multilinePasteHandler.d.ts.map +1 -0
- package/dist/core/multilinePasteHandler.js +81 -0
- package/dist/core/multilinePasteHandler.js.map +1 -0
- package/dist/core/preferences.d.ts +65 -0
- package/dist/core/preferences.d.ts.map +1 -0
- package/dist/core/preferences.js +305 -0
- package/dist/core/preferences.js.map +1 -0
- package/dist/core/providerKeys.d.ts +20 -0
- package/dist/core/providerKeys.d.ts.map +1 -0
- package/dist/core/providerKeys.js +40 -0
- package/dist/core/providerKeys.js.map +1 -0
- package/dist/core/refusalDetection.d.ts +2 -0
- package/dist/core/refusalDetection.d.ts.map +1 -0
- package/dist/core/refusalDetection.js +51 -0
- package/dist/core/refusalDetection.js.map +1 -0
- package/dist/core/resultVerification.d.ts +47 -0
- package/dist/core/resultVerification.d.ts.map +1 -0
- package/dist/core/resultVerification.js +126 -0
- package/dist/core/resultVerification.js.map +1 -0
- package/dist/core/schemaValidator.d.ts +49 -0
- package/dist/core/schemaValidator.d.ts.map +1 -0
- package/dist/core/schemaValidator.js +234 -0
- package/dist/core/schemaValidator.js.map +1 -0
- package/dist/core/secretStore.d.ts +48 -0
- package/dist/core/secretStore.d.ts.map +1 -0
- package/dist/core/secretStore.js +268 -0
- package/dist/core/secretStore.js.map +1 -0
- package/dist/core/sessionStorage.d.ts +10 -0
- package/dist/core/sessionStorage.d.ts.map +1 -0
- package/dist/core/sessionStorage.js +46 -0
- package/dist/core/sessionStorage.js.map +1 -0
- package/dist/core/sessionStore.d.ts +35 -0
- package/dist/core/sessionStore.d.ts.map +1 -0
- package/dist/core/sessionStore.js +191 -0
- package/dist/core/sessionStore.js.map +1 -0
- package/dist/core/shutdown.d.ts +34 -0
- package/dist/core/shutdown.d.ts.map +1 -0
- package/dist/core/shutdown.js +186 -0
- package/dist/core/shutdown.js.map +1 -0
- package/dist/core/sudoPasswordManager.d.ts +52 -0
- package/dist/core/sudoPasswordManager.d.ts.map +1 -0
- package/dist/core/sudoPasswordManager.js +115 -0
- package/dist/core/sudoPasswordManager.js.map +1 -0
- package/dist/core/taskCompletionDetector.d.ts +117 -0
- package/dist/core/taskCompletionDetector.d.ts.map +1 -0
- package/dist/core/taskCompletionDetector.js +532 -0
- package/dist/core/taskCompletionDetector.js.map +1 -0
- package/dist/core/testFailureMonitor.d.ts +67 -0
- package/dist/core/testFailureMonitor.d.ts.map +1 -0
- package/dist/core/testFailureMonitor.js +262 -0
- package/dist/core/testFailureMonitor.js.map +1 -0
- package/dist/core/toolPreconditions.d.ts +34 -0
- package/dist/core/toolPreconditions.d.ts.map +1 -0
- package/dist/core/toolPreconditions.js +242 -0
- package/dist/core/toolPreconditions.js.map +1 -0
- package/dist/core/toolRuntime.d.ts +192 -0
- package/dist/core/toolRuntime.d.ts.map +1 -0
- package/dist/core/toolRuntime.js +460 -0
- package/dist/core/toolRuntime.js.map +1 -0
- package/dist/core/types/utilityTypes.d.ts +183 -0
- package/dist/core/types/utilityTypes.d.ts.map +1 -0
- package/dist/core/types/utilityTypes.js +273 -0
- package/dist/core/types/utilityTypes.js.map +1 -0
- package/dist/core/types.d.ts +334 -0
- package/dist/core/types.d.ts.map +1 -0
- package/dist/core/types.js +76 -0
- package/dist/core/types.js.map +1 -0
- package/dist/core/updateChecker.d.ts +148 -0
- package/dist/core/updateChecker.d.ts.map +1 -0
- package/dist/core/updateChecker.js +599 -0
- package/dist/core/updateChecker.js.map +1 -0
- package/dist/core/usageTracker.d.ts +11 -0
- package/dist/core/usageTracker.d.ts.map +1 -0
- package/dist/core/usageTracker.js +128 -0
- package/dist/core/usageTracker.js.map +1 -0
- package/dist/headless/interactiveShell.d.ts +22 -0
- package/dist/headless/interactiveShell.d.ts.map +1 -0
- package/dist/headless/interactiveShell.js +2100 -0
- package/dist/headless/interactiveShell.js.map +1 -0
- package/dist/leanAgent.d.ts +73 -0
- package/dist/leanAgent.d.ts.map +1 -0
- package/dist/leanAgent.js +177 -0
- package/dist/leanAgent.js.map +1 -0
- package/dist/plugins/index.d.ts +49 -0
- package/dist/plugins/index.d.ts.map +1 -0
- package/dist/plugins/index.js +104 -0
- package/dist/plugins/index.js.map +1 -0
- package/dist/plugins/providers/anthropic/index.d.ts +9 -0
- package/dist/plugins/providers/anthropic/index.d.ts.map +1 -0
- package/dist/plugins/providers/anthropic/index.js +48 -0
- package/dist/plugins/providers/anthropic/index.js.map +1 -0
- package/dist/plugins/providers/deepseek/index.d.ts +11 -0
- package/dist/plugins/providers/deepseek/index.d.ts.map +1 -0
- package/dist/plugins/providers/deepseek/index.js +54 -0
- package/dist/plugins/providers/deepseek/index.js.map +1 -0
- package/dist/plugins/providers/index.d.ts +2 -0
- package/dist/plugins/providers/index.d.ts.map +1 -0
- package/dist/plugins/providers/index.js +17 -0
- package/dist/plugins/providers/index.js.map +1 -0
- package/dist/plugins/providers/openai/index.d.ts +10 -0
- package/dist/plugins/providers/openai/index.d.ts.map +1 -0
- package/dist/plugins/providers/openai/index.js +47 -0
- package/dist/plugins/providers/openai/index.js.map +1 -0
- package/dist/plugins/providers/xai/index.d.ts +10 -0
- package/dist/plugins/providers/xai/index.d.ts.map +1 -0
- package/dist/plugins/providers/xai/index.js +47 -0
- package/dist/plugins/providers/xai/index.js.map +1 -0
- package/dist/plugins/tools/agentSpawning/agentSpawningPlugin.d.ts +10 -0
- package/dist/plugins/tools/agentSpawning/agentSpawningPlugin.d.ts.map +1 -0
- package/dist/plugins/tools/agentSpawning/agentSpawningPlugin.js +110 -0
- package/dist/plugins/tools/agentSpawning/agentSpawningPlugin.js.map +1 -0
- package/dist/plugins/tools/bash/localBashPlugin.d.ts +3 -0
- package/dist/plugins/tools/bash/localBashPlugin.d.ts.map +1 -0
- package/dist/plugins/tools/bash/localBashPlugin.js +14 -0
- package/dist/plugins/tools/bash/localBashPlugin.js.map +1 -0
- package/dist/plugins/tools/edit/editPlugin.d.ts +9 -0
- package/dist/plugins/tools/edit/editPlugin.d.ts.map +1 -0
- package/dist/plugins/tools/edit/editPlugin.js +15 -0
- package/dist/plugins/tools/edit/editPlugin.js.map +1 -0
- package/dist/plugins/tools/enhancedGit/enhancedGitPlugin.d.ts +3 -0
- package/dist/plugins/tools/enhancedGit/enhancedGitPlugin.d.ts.map +1 -0
- package/dist/plugins/tools/enhancedGit/enhancedGitPlugin.js +9 -0
- package/dist/plugins/tools/enhancedGit/enhancedGitPlugin.js.map +1 -0
- package/dist/plugins/tools/filesystem/localFilesystemPlugin.d.ts +3 -0
- package/dist/plugins/tools/filesystem/localFilesystemPlugin.d.ts.map +1 -0
- package/dist/plugins/tools/filesystem/localFilesystemPlugin.js +14 -0
- package/dist/plugins/tools/filesystem/localFilesystemPlugin.js.map +1 -0
- package/dist/plugins/tools/gitHistory/gitHistoryPlugin.d.ts +3 -0
- package/dist/plugins/tools/gitHistory/gitHistoryPlugin.d.ts.map +1 -0
- package/dist/plugins/tools/gitHistory/gitHistoryPlugin.js +9 -0
- package/dist/plugins/tools/gitHistory/gitHistoryPlugin.js.map +1 -0
- package/dist/plugins/tools/index.d.ts +3 -0
- package/dist/plugins/tools/index.d.ts.map +1 -0
- package/dist/plugins/tools/index.js +3 -0
- package/dist/plugins/tools/index.js.map +1 -0
- package/dist/plugins/tools/integrity/integrityPlugin.d.ts +3 -0
- package/dist/plugins/tools/integrity/integrityPlugin.d.ts.map +1 -0
- package/dist/plugins/tools/integrity/integrityPlugin.js +31 -0
- package/dist/plugins/tools/integrity/integrityPlugin.js.map +1 -0
- package/dist/plugins/tools/kali/kaliPlugin.d.ts +3 -0
- package/dist/plugins/tools/kali/kaliPlugin.d.ts.map +1 -0
- package/dist/plugins/tools/kali/kaliPlugin.js +10 -0
- package/dist/plugins/tools/kali/kaliPlugin.js.map +1 -0
- package/dist/plugins/tools/mcp/mcpClient.d.ts +49 -0
- package/dist/plugins/tools/mcp/mcpClient.d.ts.map +1 -0
- package/dist/plugins/tools/mcp/mcpClient.js +112 -0
- package/dist/plugins/tools/mcp/mcpClient.js.map +1 -0
- package/dist/plugins/tools/mcp/mcpPlugin.d.ts +3 -0
- package/dist/plugins/tools/mcp/mcpPlugin.d.ts.map +1 -0
- package/dist/plugins/tools/mcp/mcpPlugin.js +10 -0
- package/dist/plugins/tools/mcp/mcpPlugin.js.map +1 -0
- package/dist/plugins/tools/nodeDefaults.d.ts +13 -0
- package/dist/plugins/tools/nodeDefaults.d.ts.map +1 -0
- package/dist/plugins/tools/nodeDefaults.js +37 -0
- package/dist/plugins/tools/nodeDefaults.js.map +1 -0
- package/dist/plugins/tools/orchestration/orchestrationPlugin.d.ts +3 -0
- package/dist/plugins/tools/orchestration/orchestrationPlugin.d.ts.map +1 -0
- package/dist/plugins/tools/orchestration/orchestrationPlugin.js +340 -0
- package/dist/plugins/tools/orchestration/orchestrationPlugin.js.map +1 -0
- package/dist/plugins/tools/registry.d.ts +22 -0
- package/dist/plugins/tools/registry.d.ts.map +1 -0
- package/dist/plugins/tools/registry.js +58 -0
- package/dist/plugins/tools/registry.js.map +1 -0
- package/dist/plugins/tools/search/localSearchPlugin.d.ts +3 -0
- package/dist/plugins/tools/search/localSearchPlugin.d.ts.map +1 -0
- package/dist/plugins/tools/search/localSearchPlugin.js +14 -0
- package/dist/plugins/tools/search/localSearchPlugin.js.map +1 -0
- package/dist/plugins/tools/skills/skillPlugin.d.ts +3 -0
- package/dist/plugins/tools/skills/skillPlugin.d.ts.map +1 -0
- package/dist/plugins/tools/skills/skillPlugin.js +27 -0
- package/dist/plugins/tools/skills/skillPlugin.js.map +1 -0
- package/dist/plugins/tools/todo/todoPlugin.d.ts +3 -0
- package/dist/plugins/tools/todo/todoPlugin.d.ts.map +1 -0
- package/dist/plugins/tools/todo/todoPlugin.js +10 -0
- package/dist/plugins/tools/todo/todoPlugin.js.map +1 -0
- package/dist/providers/baseProvider.d.ts +148 -0
- package/dist/providers/baseProvider.d.ts.map +1 -0
- package/dist/providers/baseProvider.js +284 -0
- package/dist/providers/baseProvider.js.map +1 -0
- package/dist/providers/openaiChatCompletionsProvider.d.ts +64 -0
- package/dist/providers/openaiChatCompletionsProvider.d.ts.map +1 -0
- package/dist/providers/openaiChatCompletionsProvider.js +1018 -0
- package/dist/providers/openaiChatCompletionsProvider.js.map +1 -0
- package/dist/providers/providerFactory.d.ts +22 -0
- package/dist/providers/providerFactory.d.ts.map +1 -0
- package/dist/providers/providerFactory.js +25 -0
- package/dist/providers/providerFactory.js.map +1 -0
- package/dist/providers/resilientProvider.d.ts +103 -0
- package/dist/providers/resilientProvider.d.ts.map +1 -0
- package/dist/providers/resilientProvider.js +468 -0
- package/dist/providers/resilientProvider.js.map +1 -0
- package/dist/runtime/agentController.d.ts +121 -0
- package/dist/runtime/agentController.d.ts.map +1 -0
- package/dist/runtime/agentController.js +739 -0
- package/dist/runtime/agentController.js.map +1 -0
- package/dist/runtime/agentHost.d.ts +61 -0
- package/dist/runtime/agentHost.d.ts.map +1 -0
- package/dist/runtime/agentHost.js +158 -0
- package/dist/runtime/agentHost.js.map +1 -0
- package/dist/runtime/agentSession.d.ts +49 -0
- package/dist/runtime/agentSession.d.ts.map +1 -0
- package/dist/runtime/agentSession.js +218 -0
- package/dist/runtime/agentSession.js.map +1 -0
- package/dist/runtime/agentSpawningWiring.d.ts +23 -0
- package/dist/runtime/agentSpawningWiring.d.ts.map +1 -0
- package/dist/runtime/agentSpawningWiring.js +119 -0
- package/dist/runtime/agentSpawningWiring.js.map +1 -0
- package/dist/runtime/agentWorkerPool.d.ts +167 -0
- package/dist/runtime/agentWorkerPool.d.ts.map +1 -0
- package/dist/runtime/agentWorkerPool.js +435 -0
- package/dist/runtime/agentWorkerPool.js.map +1 -0
- package/dist/runtime/node.d.ts +7 -0
- package/dist/runtime/node.d.ts.map +1 -0
- package/dist/runtime/node.js +56 -0
- package/dist/runtime/node.js.map +1 -0
- package/dist/runtime/universal.d.ts +18 -0
- package/dist/runtime/universal.d.ts.map +1 -0
- package/dist/runtime/universal.js +21 -0
- package/dist/runtime/universal.js.map +1 -0
- package/dist/shell/autoExecutor.d.ts +70 -0
- package/dist/shell/autoExecutor.d.ts.map +1 -0
- package/dist/shell/autoExecutor.js +320 -0
- package/dist/shell/autoExecutor.js.map +1 -0
- package/dist/shell/commandRegistry.d.ts +122 -0
- package/dist/shell/commandRegistry.d.ts.map +1 -0
- package/dist/shell/commandRegistry.js +355 -0
- package/dist/shell/commandRegistry.js.map +1 -0
- package/dist/shell/composableMessage.d.ts +178 -0
- package/dist/shell/composableMessage.d.ts.map +1 -0
- package/dist/shell/composableMessage.js +384 -0
- package/dist/shell/composableMessage.js.map +1 -0
- package/dist/shell/liveStatus.d.ts +27 -0
- package/dist/shell/liveStatus.d.ts.map +1 -0
- package/dist/shell/liveStatus.js +53 -0
- package/dist/shell/liveStatus.js.map +1 -0
- package/dist/shell/systemPrompt.d.ts +12 -0
- package/dist/shell/systemPrompt.d.ts.map +1 -0
- package/dist/shell/systemPrompt.js +16 -0
- package/dist/shell/systemPrompt.js.map +1 -0
- package/dist/shell/vimMode.d.ts +66 -0
- package/dist/shell/vimMode.d.ts.map +1 -0
- package/dist/shell/vimMode.js +435 -0
- package/dist/shell/vimMode.js.map +1 -0
- package/dist/tools/bashTools.d.ts +11 -0
- package/dist/tools/bashTools.d.ts.map +1 -0
- package/dist/tools/bashTools.js +779 -0
- package/dist/tools/bashTools.js.map +1 -0
- package/dist/tools/diffUtils.d.ts +43 -0
- package/dist/tools/diffUtils.d.ts.map +1 -0
- package/dist/tools/diffUtils.js +607 -0
- package/dist/tools/diffUtils.js.map +1 -0
- package/dist/tools/editTools.d.ts +29 -0
- package/dist/tools/editTools.d.ts.map +1 -0
- package/dist/tools/editTools.js +792 -0
- package/dist/tools/editTools.js.map +1 -0
- package/dist/tools/fileChangeTracker.d.ts +47 -0
- package/dist/tools/fileChangeTracker.d.ts.map +1 -0
- package/dist/tools/fileChangeTracker.js +154 -0
- package/dist/tools/fileChangeTracker.js.map +1 -0
- package/dist/tools/fileReadTracker.d.ts +69 -0
- package/dist/tools/fileReadTracker.d.ts.map +1 -0
- package/dist/tools/fileReadTracker.js +213 -0
- package/dist/tools/fileReadTracker.js.map +1 -0
- package/dist/tools/fileTools.d.ts +3 -0
- package/dist/tools/fileTools.d.ts.map +1 -0
- package/dist/tools/fileTools.js +389 -0
- package/dist/tools/fileTools.js.map +1 -0
- package/dist/tools/grepTools.d.ts +3 -0
- package/dist/tools/grepTools.d.ts.map +1 -0
- package/dist/tools/grepTools.js +128 -0
- package/dist/tools/grepTools.js.map +1 -0
- package/dist/tools/heliaControl.d.ts +51 -0
- package/dist/tools/heliaControl.d.ts.map +1 -0
- package/dist/tools/heliaControl.js +93 -0
- package/dist/tools/heliaControl.js.map +1 -0
- package/dist/tools/hitlTools.d.ts +7 -0
- package/dist/tools/hitlTools.d.ts.map +1 -0
- package/dist/tools/hitlTools.js +185 -0
- package/dist/tools/hitlTools.js.map +1 -0
- package/dist/tools/localExplore.d.ts +38 -0
- package/dist/tools/localExplore.d.ts.map +1 -0
- package/dist/tools/localExplore.js +30 -0
- package/dist/tools/localExplore.js.map +1 -0
- package/dist/tools/memoryTools.d.ts +20 -0
- package/dist/tools/memoryTools.d.ts.map +1 -0
- package/dist/tools/memoryTools.js +180 -0
- package/dist/tools/memoryTools.js.map +1 -0
- package/dist/tools/notebookTools.d.ts +20 -0
- package/dist/tools/notebookTools.d.ts.map +1 -0
- package/dist/tools/notebookTools.js +140 -0
- package/dist/tools/notebookTools.js.map +1 -0
- package/dist/tools/searchTools.d.ts +12 -0
- package/dist/tools/searchTools.d.ts.map +1 -0
- package/dist/tools/searchTools.js +413 -0
- package/dist/tools/searchTools.js.map +1 -0
- package/dist/tools/skillTools.d.ts +24 -0
- package/dist/tools/skillTools.d.ts.map +1 -0
- package/dist/tools/skillTools.js +140 -0
- package/dist/tools/skillTools.js.map +1 -0
- package/dist/tools/todoTools.d.ts +24 -0
- package/dist/tools/todoTools.d.ts.map +1 -0
- package/dist/tools/todoTools.js +101 -0
- package/dist/tools/todoTools.js.map +1 -0
- package/dist/tools/webTools.d.ts +26 -0
- package/dist/tools/webTools.d.ts.map +1 -0
- package/dist/tools/webTools.js +332 -0
- package/dist/tools/webTools.js.map +1 -0
- package/dist/ui/RenderGate.d.ts +83 -0
- package/dist/ui/RenderGate.d.ts.map +1 -0
- package/dist/ui/RenderGate.js +138 -0
- package/dist/ui/RenderGate.js.map +1 -0
- package/dist/ui/animatedStatus.d.ts +140 -0
- package/dist/ui/animatedStatus.d.ts.map +1 -0
- package/dist/ui/animatedStatus.js +480 -0
- package/dist/ui/animatedStatus.js.map +1 -0
- package/dist/ui/animation/AnimationScheduler.d.ts +197 -0
- package/dist/ui/animation/AnimationScheduler.d.ts.map +1 -0
- package/dist/ui/animation/AnimationScheduler.js +440 -0
- package/dist/ui/animation/AnimationScheduler.js.map +1 -0
- package/dist/ui/codeHighlighter.d.ts +6 -0
- package/dist/ui/codeHighlighter.d.ts.map +1 -0
- package/dist/ui/codeHighlighter.js +855 -0
- package/dist/ui/codeHighlighter.js.map +1 -0
- package/dist/ui/designSystem.d.ts +26 -0
- package/dist/ui/designSystem.d.ts.map +1 -0
- package/dist/ui/designSystem.js +114 -0
- package/dist/ui/designSystem.js.map +1 -0
- package/dist/ui/errorFormatter.d.ts +64 -0
- package/dist/ui/errorFormatter.d.ts.map +1 -0
- package/dist/ui/errorFormatter.js +316 -0
- package/dist/ui/errorFormatter.js.map +1 -0
- package/dist/ui/globalWriteLock.d.ts +63 -0
- package/dist/ui/globalWriteLock.d.ts.map +1 -0
- package/dist/ui/globalWriteLock.js +173 -0
- package/dist/ui/globalWriteLock.js.map +1 -0
- package/dist/ui/index.d.ts +31 -0
- package/dist/ui/index.d.ts.map +1 -0
- package/dist/ui/index.js +49 -0
- package/dist/ui/index.js.map +1 -0
- package/dist/ui/ink/App.d.ts +39 -0
- package/dist/ui/ink/App.d.ts.map +1 -0
- package/dist/ui/ink/App.js +9 -0
- package/dist/ui/ink/App.js.map +1 -0
- package/dist/ui/ink/ChatStatic.d.ts +29 -0
- package/dist/ui/ink/ChatStatic.d.ts.map +1 -0
- package/dist/ui/ink/ChatStatic.js +14 -0
- package/dist/ui/ink/ChatStatic.js.map +1 -0
- package/dist/ui/ink/InkPromptController.d.ts +282 -0
- package/dist/ui/ink/InkPromptController.d.ts.map +1 -0
- package/dist/ui/ink/InkPromptController.js +508 -0
- package/dist/ui/ink/InkPromptController.js.map +1 -0
- package/dist/ui/ink/Prompt.d.ts +31 -0
- package/dist/ui/ink/Prompt.d.ts.map +1 -0
- package/dist/ui/ink/Prompt.js +197 -0
- package/dist/ui/ink/Prompt.js.map +1 -0
- package/dist/ui/ink/StatusLine.d.ts +25 -0
- package/dist/ui/ink/StatusLine.d.ts.map +1 -0
- package/dist/ui/ink/StatusLine.js +11 -0
- package/dist/ui/ink/StatusLine.js.map +1 -0
- package/dist/ui/ink/adapter.d.ts +58 -0
- package/dist/ui/ink/adapter.d.ts.map +1 -0
- package/dist/ui/ink/adapter.js +113 -0
- package/dist/ui/ink/adapter.js.map +1 -0
- package/dist/ui/interrupts/InterruptManager.d.ts +157 -0
- package/dist/ui/interrupts/InterruptManager.d.ts.map +1 -0
- package/dist/ui/interrupts/InterruptManager.js +501 -0
- package/dist/ui/interrupts/InterruptManager.js.map +1 -0
- package/dist/ui/layout.d.ts +27 -0
- package/dist/ui/layout.d.ts.map +1 -0
- package/dist/ui/layout.js +184 -0
- package/dist/ui/layout.js.map +1 -0
- package/dist/ui/outputMode.d.ts +58 -0
- package/dist/ui/outputMode.d.ts.map +1 -0
- package/dist/ui/outputMode.js +179 -0
- package/dist/ui/outputMode.js.map +1 -0
- package/dist/ui/overlay/OverlayManager.d.ts +105 -0
- package/dist/ui/overlay/OverlayManager.d.ts.map +1 -0
- package/dist/ui/overlay/OverlayManager.js +304 -0
- package/dist/ui/overlay/OverlayManager.js.map +1 -0
- package/dist/ui/premiumComponents.d.ts +54 -0
- package/dist/ui/premiumComponents.d.ts.map +1 -0
- package/dist/ui/premiumComponents.js +241 -0
- package/dist/ui/premiumComponents.js.map +1 -0
- package/dist/ui/richText.d.ts +13 -0
- package/dist/ui/richText.d.ts.map +1 -0
- package/dist/ui/richText.js +444 -0
- package/dist/ui/richText.js.map +1 -0
- package/dist/ui/telemetry/ResponseTracker.d.ts +22 -0
- package/dist/ui/telemetry/ResponseTracker.d.ts.map +1 -0
- package/dist/ui/telemetry/ResponseTracker.js +60 -0
- package/dist/ui/telemetry/ResponseTracker.js.map +1 -0
- package/dist/ui/telemetry/UITelemetry.d.ts +181 -0
- package/dist/ui/telemetry/UITelemetry.d.ts.map +1 -0
- package/dist/ui/telemetry/UITelemetry.js +446 -0
- package/dist/ui/telemetry/UITelemetry.js.map +1 -0
- package/dist/ui/textHighlighter.d.ts +83 -0
- package/dist/ui/textHighlighter.d.ts.map +1 -0
- package/dist/ui/textHighlighter.js +267 -0
- package/dist/ui/textHighlighter.js.map +1 -0
- package/dist/ui/theme.d.ts +351 -0
- package/dist/ui/theme.d.ts.map +1 -0
- package/dist/ui/theme.js +434 -0
- package/dist/ui/theme.js.map +1 -0
- package/dist/ui/toolDisplay.d.ts +221 -0
- package/dist/ui/toolDisplay.d.ts.map +1 -0
- package/dist/ui/toolDisplay.js +1654 -0
- package/dist/ui/toolDisplay.js.map +1 -0
- package/dist/ui/uiConstants.d.ts +253 -0
- package/dist/ui/uiConstants.d.ts.map +1 -0
- package/dist/ui/uiConstants.js +437 -0
- package/dist/ui/uiConstants.js.map +1 -0
- package/dist/utils/analytics.d.ts +2 -0
- package/dist/utils/analytics.d.ts.map +1 -0
- package/dist/utils/analytics.js +51 -0
- package/dist/utils/analytics.js.map +1 -0
- package/dist/utils/askUserPrompt.d.ts +21 -0
- package/dist/utils/askUserPrompt.d.ts.map +1 -0
- package/dist/utils/askUserPrompt.js +87 -0
- package/dist/utils/askUserPrompt.js.map +1 -0
- package/dist/utils/asyncUtils.d.ts +95 -0
- package/dist/utils/asyncUtils.d.ts.map +1 -0
- package/dist/utils/asyncUtils.js +286 -0
- package/dist/utils/asyncUtils.js.map +1 -0
- package/dist/utils/debugLogger.d.ts +6 -0
- package/dist/utils/debugLogger.d.ts.map +1 -0
- package/dist/utils/debugLogger.js +39 -0
- package/dist/utils/debugLogger.js.map +1 -0
- package/dist/utils/errorUtils.d.ts +12 -0
- package/dist/utils/errorUtils.d.ts.map +1 -0
- package/dist/utils/errorUtils.js +83 -0
- package/dist/utils/errorUtils.js.map +1 -0
- package/dist/utils/frontmatter.d.ts +10 -0
- package/dist/utils/frontmatter.d.ts.map +1 -0
- package/dist/utils/frontmatter.js +78 -0
- package/dist/utils/frontmatter.js.map +1 -0
- package/dist/utils/packageInfo.d.ts +14 -0
- package/dist/utils/packageInfo.d.ts.map +1 -0
- package/dist/utils/packageInfo.js +45 -0
- package/dist/utils/packageInfo.js.map +1 -0
- package/dist/utils/planFormatter.d.ts +34 -0
- package/dist/utils/planFormatter.d.ts.map +1 -0
- package/dist/utils/planFormatter.js +141 -0
- package/dist/utils/planFormatter.js.map +1 -0
- package/dist/utils/securityUtils.d.ts +145 -0
- package/dist/utils/securityUtils.d.ts.map +1 -0
- package/dist/utils/securityUtils.js +507 -0
- package/dist/utils/securityUtils.js.map +1 -0
- package/dist/utils/statusReporter.d.ts +6 -0
- package/dist/utils/statusReporter.d.ts.map +1 -0
- package/dist/utils/statusReporter.js +26 -0
- package/dist/utils/statusReporter.js.map +1 -0
- package/dist/workspace.d.ts +8 -0
- package/dist/workspace.d.ts.map +1 -0
- package/dist/workspace.js +135 -0
- package/dist/workspace.js.map +1 -0
- package/dist/workspace.validator.d.ts +49 -0
- package/dist/workspace.validator.d.ts.map +1 -0
- package/dist/workspace.validator.js +215 -0
- package/dist/workspace.validator.js.map +1 -0
- package/package.json +135 -0
- package/scripts/postinstall.cjs +58 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"memoryCapability.js","sourceRoot":"","sources":["../../src/capabilities/memoryCapability.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAE5D,MAAM,OAAO,sBAAsB;IACxB,EAAE,GAAG,mBAAmB,CAAC;IACjB,OAAO,CAA0B;IAElD,YAAY,UAAmC,EAAE;QAC/C,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IACzB,CAAC;IAED,KAAK,CAAC,MAAM,CAAC,OAA0B;QACrC,MAAM,UAAU,GAAG,IAAI,CAAC,OAAO,CAAC,UAAU,IAAI,OAAO,CAAC,UAAU,CAAC;QACjE,OAAO;YACL,EAAE,EAAE,cAAc;YAClB,WAAW,EAAE,0DAA0D;YACvE,SAAS,EAAE;gBACT,EAAE,EAAE,QAAQ;gBACZ,WAAW,EAAE,8BAA8B;gBAC3C,KAAK,EAAE,iBAAiB,CAAC,UAAU,CAAC;aACrC;YACD,QAAQ,EAAE,EAAE,UAAU,EAAE;SACzB,CAAC;IACJ,CAAC;CACF"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { CapabilityContribution, CapabilityContext, CapabilityModule } from '../runtime/agentHost.js';
|
|
2
|
+
export declare class NotebookCapabilityModule implements CapabilityModule {
|
|
3
|
+
readonly id = "capability.notebook";
|
|
4
|
+
create(context: CapabilityContext): Promise<CapabilityContribution>;
|
|
5
|
+
}
|
|
6
|
+
//# sourceMappingURL=notebookCapability.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"notebookCapability.d.ts","sourceRoot":"","sources":["../../src/capabilities/notebookCapability.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,sBAAsB,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAG3G,qBAAa,wBAAyB,YAAW,gBAAgB;IAC/D,QAAQ,CAAC,EAAE,yBAAyB;IAE9B,MAAM,CAAC,OAAO,EAAE,iBAAiB,GAAG,OAAO,CAAC,sBAAsB,CAAC;CAY1E"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { createNotebookTools } from '../tools/notebookTools.js';
|
|
2
|
+
export class NotebookCapabilityModule {
|
|
3
|
+
id = 'capability.notebook';
|
|
4
|
+
async create(context) {
|
|
5
|
+
return {
|
|
6
|
+
id: 'notebook.tools',
|
|
7
|
+
description: 'Jupyter notebook (.ipynb) cell-level editing.',
|
|
8
|
+
toolSuite: {
|
|
9
|
+
id: 'notebook',
|
|
10
|
+
description: 'NotebookEdit',
|
|
11
|
+
tools: createNotebookTools(context.workingDir),
|
|
12
|
+
},
|
|
13
|
+
metadata: {},
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
//# sourceMappingURL=notebookCapability.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"notebookCapability.js","sourceRoot":"","sources":["../../src/capabilities/notebookCapability.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,mBAAmB,EAAE,MAAM,2BAA2B,CAAC;AAEhE,MAAM,OAAO,wBAAwB;IAC1B,EAAE,GAAG,qBAAqB,CAAC;IAEpC,KAAK,CAAC,MAAM,CAAC,OAA0B;QACrC,OAAO;YACL,EAAE,EAAE,gBAAgB;YACpB,WAAW,EAAE,+CAA+C;YAC5D,SAAS,EAAE;gBACT,EAAE,EAAE,UAAU;gBACd,WAAW,EAAE,cAAc;gBAC3B,KAAK,EAAE,mBAAmB,CAAC,OAAO,CAAC,UAAU,CAAC;aAC/C;YACD,QAAQ,EAAE,EAAE;SACb,CAAC;IACJ,CAAC;CACF"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { CapabilityContribution, CapabilityContext, CapabilityModule } from '../runtime/agentHost.js';
|
|
2
|
+
export interface SearchCapabilityOptions {
|
|
3
|
+
workingDir?: string;
|
|
4
|
+
}
|
|
5
|
+
/**
|
|
6
|
+
* Unified Search Capability Module
|
|
7
|
+
*
|
|
8
|
+
* Provides the Search tool which combines:
|
|
9
|
+
* - File pattern matching (glob)
|
|
10
|
+
* - Content search (regex/grep)
|
|
11
|
+
* - Definition finding (functions, classes, interfaces)
|
|
12
|
+
*/
|
|
13
|
+
export declare class SearchCapabilityModule implements CapabilityModule {
|
|
14
|
+
readonly id = "capability.search";
|
|
15
|
+
private readonly options;
|
|
16
|
+
constructor(options?: SearchCapabilityOptions);
|
|
17
|
+
create(context: CapabilityContext): Promise<CapabilityContribution>;
|
|
18
|
+
}
|
|
19
|
+
//# sourceMappingURL=searchCapability.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"searchCapability.d.ts","sourceRoot":"","sources":["../../src/capabilities/searchCapability.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,sBAAsB,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAG3G,MAAM,WAAW,uBAAuB;IACtC,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED;;;;;;;GAOG;AACH,qBAAa,sBAAuB,YAAW,gBAAgB;IAC7D,QAAQ,CAAC,EAAE,uBAAuB;IAClC,OAAO,CAAC,QAAQ,CAAC,OAAO,CAA0B;gBAEtC,OAAO,GAAE,uBAA4B;IAI3C,MAAM,CAAC,OAAO,EAAE,iBAAiB,GAAG,OAAO,CAAC,sBAAsB,CAAC;CAY1E"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { createSearchTools } from '../tools/searchTools.js';
|
|
2
|
+
/**
|
|
3
|
+
* Unified Search Capability Module
|
|
4
|
+
*
|
|
5
|
+
* Provides the Search tool which combines:
|
|
6
|
+
* - File pattern matching (glob)
|
|
7
|
+
* - Content search (regex/grep)
|
|
8
|
+
* - Definition finding (functions, classes, interfaces)
|
|
9
|
+
*/
|
|
10
|
+
export class SearchCapabilityModule {
|
|
11
|
+
id = 'capability.search';
|
|
12
|
+
options;
|
|
13
|
+
constructor(options = {}) {
|
|
14
|
+
this.options = options;
|
|
15
|
+
}
|
|
16
|
+
async create(context) {
|
|
17
|
+
const workingDir = this.options.workingDir ?? context.workingDir;
|
|
18
|
+
return {
|
|
19
|
+
id: 'search.unified',
|
|
20
|
+
description: 'Unified search for files and content',
|
|
21
|
+
toolSuite: {
|
|
22
|
+
id: 'search',
|
|
23
|
+
tools: createSearchTools(workingDir),
|
|
24
|
+
},
|
|
25
|
+
metadata: { workingDir },
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
//# sourceMappingURL=searchCapability.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"searchCapability.js","sourceRoot":"","sources":["../../src/capabilities/searchCapability.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAM5D;;;;;;;GAOG;AACH,MAAM,OAAO,sBAAsB;IACxB,EAAE,GAAG,mBAAmB,CAAC;IACjB,OAAO,CAA0B;IAElD,YAAY,UAAmC,EAAE;QAC/C,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IACzB,CAAC;IAED,KAAK,CAAC,MAAM,CAAC,OAA0B;QACrC,MAAM,UAAU,GAAG,IAAI,CAAC,OAAO,CAAC,UAAU,IAAI,OAAO,CAAC,UAAU,CAAC;QACjE,OAAO;YACL,EAAE,EAAE,gBAAgB;YACpB,WAAW,EAAE,sCAAsC;YACnD,SAAS,EAAE;gBACT,EAAE,EAAE,QAAQ;gBACZ,KAAK,EAAE,iBAAiB,CAAC,UAAU,CAAC;aACrC;YACD,QAAQ,EAAE,EAAE,UAAU,EAAE;SACzB,CAAC;IACJ,CAAC;CACF"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { CapabilityContribution, CapabilityContext, CapabilityModule } from '../runtime/agentHost.js';
|
|
2
|
+
export declare class SkillCapabilityModule implements CapabilityModule {
|
|
3
|
+
readonly id = "capability.skills";
|
|
4
|
+
create(context: CapabilityContext): Promise<CapabilityContribution>;
|
|
5
|
+
}
|
|
6
|
+
//# sourceMappingURL=skillCapability.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"skillCapability.d.ts","sourceRoot":"","sources":["../../src/capabilities/skillCapability.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,sBAAsB,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAG3G,qBAAa,qBAAsB,YAAW,gBAAgB;IAC5D,QAAQ,CAAC,EAAE,uBAAuB;IAE5B,MAAM,CAAC,OAAO,EAAE,iBAAiB,GAAG,OAAO,CAAC,sBAAsB,CAAC;CAY1E"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { createSkillTools } from '../tools/skillTools.js';
|
|
2
|
+
export class SkillCapabilityModule {
|
|
3
|
+
id = 'capability.skills';
|
|
4
|
+
async create(context) {
|
|
5
|
+
return {
|
|
6
|
+
id: 'skills.tools',
|
|
7
|
+
description: 'Skill registry — Claude-Code-style reusable playbooks loaded from .erosolar/skills/.',
|
|
8
|
+
toolSuite: {
|
|
9
|
+
id: 'skills',
|
|
10
|
+
description: 'Skill discovery + loading',
|
|
11
|
+
tools: createSkillTools(context.workingDir),
|
|
12
|
+
},
|
|
13
|
+
metadata: {},
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
//# sourceMappingURL=skillCapability.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"skillCapability.js","sourceRoot":"","sources":["../../src/capabilities/skillCapability.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAE1D,MAAM,OAAO,qBAAqB;IACvB,EAAE,GAAG,mBAAmB,CAAC;IAElC,KAAK,CAAC,MAAM,CAAC,OAA0B;QACrC,OAAO;YACL,EAAE,EAAE,cAAc;YAClB,WAAW,EAAE,sFAAsF;YACnG,SAAS,EAAE;gBACT,EAAE,EAAE,QAAQ;gBACZ,WAAW,EAAE,2BAA2B;gBACxC,KAAK,EAAE,gBAAgB,CAAC,OAAO,CAAC,UAAU,CAAC;aAC5C;YACD,QAAQ,EAAE,EAAE;SACb,CAAC;IACJ,CAAC;CACF"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { CapabilityContribution, CapabilityContext, CapabilityModule } from '../runtime/agentHost.js';
|
|
2
|
+
/**
|
|
3
|
+
* Exposes the TodoWrite tool for agent task-list management.
|
|
4
|
+
* Stateless module; the underlying tool keeps its list in module
|
|
5
|
+
* scope so it persists across turns within a single process.
|
|
6
|
+
*/
|
|
7
|
+
export declare class TodoCapabilityModule implements CapabilityModule {
|
|
8
|
+
readonly id = "capability.todo";
|
|
9
|
+
create(_context: CapabilityContext): Promise<CapabilityContribution>;
|
|
10
|
+
}
|
|
11
|
+
//# sourceMappingURL=todoCapability.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"todoCapability.d.ts","sourceRoot":"","sources":["../../src/capabilities/todoCapability.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,sBAAsB,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAG3G;;;;GAIG;AACH,qBAAa,oBAAqB,YAAW,gBAAgB;IAC3D,QAAQ,CAAC,EAAE,qBAAqB;IAE1B,MAAM,CAAC,QAAQ,EAAE,iBAAiB,GAAG,OAAO,CAAC,sBAAsB,CAAC;CAY3E"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { createTodoTools } from '../tools/todoTools.js';
|
|
2
|
+
/**
|
|
3
|
+
* Exposes the TodoWrite tool for agent task-list management.
|
|
4
|
+
* Stateless module; the underlying tool keeps its list in module
|
|
5
|
+
* scope so it persists across turns within a single process.
|
|
6
|
+
*/
|
|
7
|
+
export class TodoCapabilityModule {
|
|
8
|
+
id = 'capability.todo';
|
|
9
|
+
async create(_context) {
|
|
10
|
+
return {
|
|
11
|
+
id: 'todo.tools',
|
|
12
|
+
description: 'TodoWrite — agent task list (Claude-Code-style).',
|
|
13
|
+
toolSuite: {
|
|
14
|
+
id: 'todo',
|
|
15
|
+
description: 'Task list management',
|
|
16
|
+
tools: createTodoTools(),
|
|
17
|
+
},
|
|
18
|
+
metadata: {},
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
//# sourceMappingURL=todoCapability.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"todoCapability.js","sourceRoot":"","sources":["../../src/capabilities/todoCapability.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAExD;;;;GAIG;AACH,MAAM,OAAO,oBAAoB;IACtB,EAAE,GAAG,iBAAiB,CAAC;IAEhC,KAAK,CAAC,MAAM,CAAC,QAA2B;QACtC,OAAO;YACL,EAAE,EAAE,YAAY;YAChB,WAAW,EAAE,kDAAkD;YAC/D,SAAS,EAAE;gBACT,EAAE,EAAE,MAAM;gBACV,WAAW,EAAE,sBAAsB;gBACnC,KAAK,EAAE,eAAe,EAAE;aACzB;YACD,QAAQ,EAAE,EAAE;SACb,CAAC;IACJ,CAAC;CACF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toolManifest.d.ts","sourceRoot":"","sources":["../../src/capabilities/toolManifest.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAEV,qBAAqB,EAGtB,MAAM,+BAA+B,CAAC;AAUvC,wBAAgB,eAAe,IAAI,qBAAqB,CAEvD"}
|
|
@@ -0,0 +1,163 @@
|
|
|
1
|
+
import { readFileSync } from 'node:fs';
|
|
2
|
+
import { dirname, join } from 'node:path';
|
|
3
|
+
import { fileURLToPath } from 'node:url';
|
|
4
|
+
const __filename = fileURLToPath(import.meta.url);
|
|
5
|
+
const __dirname = dirname(__filename);
|
|
6
|
+
const manifest = normalizeManifest(JSON.parse(readFileSync(join(__dirname, '../contracts/tools.schema.json'), 'utf-8')));
|
|
7
|
+
export function getToolManifest() {
|
|
8
|
+
return manifest;
|
|
9
|
+
}
|
|
10
|
+
function normalizeManifest(raw) {
|
|
11
|
+
if (!raw || typeof raw !== 'object') {
|
|
12
|
+
throw new Error('Tool manifest is malformed: expected an object.');
|
|
13
|
+
}
|
|
14
|
+
const options = Array.isArray(raw.options) ? raw.options.map(normalizeOption) : null;
|
|
15
|
+
if (!options?.length) {
|
|
16
|
+
throw new Error('Tool manifest must include at least one tool option.');
|
|
17
|
+
}
|
|
18
|
+
const manifest = {
|
|
19
|
+
contractVersion: requireString(raw.contractVersion, 'contractVersion'),
|
|
20
|
+
profile: requireString(raw.profile, 'profile'),
|
|
21
|
+
version: requireString(raw.version, 'version'),
|
|
22
|
+
options,
|
|
23
|
+
};
|
|
24
|
+
const label = optionalString(raw.label);
|
|
25
|
+
if (label) {
|
|
26
|
+
manifest.label = label;
|
|
27
|
+
}
|
|
28
|
+
const description = optionalString(raw.description);
|
|
29
|
+
if (description) {
|
|
30
|
+
manifest.description = description;
|
|
31
|
+
}
|
|
32
|
+
const metadata = normalizeRecord(raw.metadata);
|
|
33
|
+
if (metadata) {
|
|
34
|
+
manifest.metadata = metadata;
|
|
35
|
+
}
|
|
36
|
+
const presets = normalizePresets(raw.presets);
|
|
37
|
+
if (presets) {
|
|
38
|
+
manifest.presets = presets;
|
|
39
|
+
}
|
|
40
|
+
return manifest;
|
|
41
|
+
}
|
|
42
|
+
function normalizeOption(raw) {
|
|
43
|
+
const id = requireString(raw.id, 'option.id');
|
|
44
|
+
const label = requireString(raw.label, `option("${id}").label`);
|
|
45
|
+
const description = requireString(raw.description, `option("${id}").description`);
|
|
46
|
+
const pluginIds = dedupeStrings(raw.pluginIds);
|
|
47
|
+
if (!pluginIds.length) {
|
|
48
|
+
throw new Error(`Tool option "${id}" must declare at least one plugin id.`);
|
|
49
|
+
}
|
|
50
|
+
const option = {
|
|
51
|
+
id,
|
|
52
|
+
label,
|
|
53
|
+
description,
|
|
54
|
+
defaultEnabled: Boolean(raw.defaultEnabled),
|
|
55
|
+
pluginIds,
|
|
56
|
+
};
|
|
57
|
+
const category = optionalString(raw.category);
|
|
58
|
+
if (category) {
|
|
59
|
+
option.category = category;
|
|
60
|
+
}
|
|
61
|
+
const requiresSecret = optionalString(raw.requiresSecret);
|
|
62
|
+
if (requiresSecret) {
|
|
63
|
+
option.requiresSecret = requiresSecret;
|
|
64
|
+
}
|
|
65
|
+
const scopes = raw.scopes?.length ? dedupeStrings(raw.scopes) : undefined;
|
|
66
|
+
if (scopes?.length) {
|
|
67
|
+
option.scopes = scopes;
|
|
68
|
+
}
|
|
69
|
+
const metadata = normalizeRecord(raw.metadata);
|
|
70
|
+
if (metadata) {
|
|
71
|
+
option.metadata = metadata;
|
|
72
|
+
}
|
|
73
|
+
return option;
|
|
74
|
+
}
|
|
75
|
+
function normalizePresets(entries) {
|
|
76
|
+
if (!entries?.length) {
|
|
77
|
+
return undefined;
|
|
78
|
+
}
|
|
79
|
+
return entries.map((preset) => {
|
|
80
|
+
const id = requireString(preset.id, 'preset.id');
|
|
81
|
+
const normalized = {
|
|
82
|
+
id,
|
|
83
|
+
label: requireString(preset.label, `preset("${id}").label`),
|
|
84
|
+
enabled: dedupeStrings(preset.enabled),
|
|
85
|
+
disabled: dedupeStrings(preset.disabled),
|
|
86
|
+
locked: dedupeStrings(preset.locked),
|
|
87
|
+
};
|
|
88
|
+
const description = optionalString(preset.description);
|
|
89
|
+
if (description) {
|
|
90
|
+
normalized.description = description;
|
|
91
|
+
}
|
|
92
|
+
const appliesTo = normalizeTargets(preset.appliesTo);
|
|
93
|
+
if (appliesTo) {
|
|
94
|
+
normalized.appliesTo = appliesTo;
|
|
95
|
+
}
|
|
96
|
+
const metadata = normalizeRecord(preset.metadata);
|
|
97
|
+
if (metadata) {
|
|
98
|
+
normalized.metadata = metadata;
|
|
99
|
+
}
|
|
100
|
+
const notes = optionalString(preset.notes);
|
|
101
|
+
if (notes) {
|
|
102
|
+
normalized.notes = notes;
|
|
103
|
+
}
|
|
104
|
+
return normalized;
|
|
105
|
+
});
|
|
106
|
+
}
|
|
107
|
+
function normalizeTargets(targets) {
|
|
108
|
+
if (!targets?.length) {
|
|
109
|
+
return undefined;
|
|
110
|
+
}
|
|
111
|
+
const seen = new Set();
|
|
112
|
+
const result = [];
|
|
113
|
+
for (const target of targets) {
|
|
114
|
+
if (target && !seen.has(target)) {
|
|
115
|
+
seen.add(target);
|
|
116
|
+
result.push(target);
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
return result.length ? result : undefined;
|
|
120
|
+
}
|
|
121
|
+
function dedupeStrings(values) {
|
|
122
|
+
if (!values?.length) {
|
|
123
|
+
return [];
|
|
124
|
+
}
|
|
125
|
+
const seen = new Set();
|
|
126
|
+
const result = [];
|
|
127
|
+
for (const entry of values) {
|
|
128
|
+
if (typeof entry !== 'string') {
|
|
129
|
+
continue;
|
|
130
|
+
}
|
|
131
|
+
const trimmed = entry.trim();
|
|
132
|
+
if (!trimmed || seen.has(trimmed)) {
|
|
133
|
+
continue;
|
|
134
|
+
}
|
|
135
|
+
seen.add(trimmed);
|
|
136
|
+
result.push(trimmed);
|
|
137
|
+
}
|
|
138
|
+
return result;
|
|
139
|
+
}
|
|
140
|
+
function normalizeRecord(value) {
|
|
141
|
+
if (!value || typeof value !== 'object' || Array.isArray(value)) {
|
|
142
|
+
return undefined;
|
|
143
|
+
}
|
|
144
|
+
return { ...value };
|
|
145
|
+
}
|
|
146
|
+
function requireString(value, field) {
|
|
147
|
+
if (typeof value !== 'string') {
|
|
148
|
+
throw new Error(`Tool manifest is missing required field "${field}".`);
|
|
149
|
+
}
|
|
150
|
+
const trimmed = value.trim();
|
|
151
|
+
if (!trimmed) {
|
|
152
|
+
throw new Error(`Tool manifest field "${field}" cannot be blank.`);
|
|
153
|
+
}
|
|
154
|
+
return trimmed;
|
|
155
|
+
}
|
|
156
|
+
function optionalString(value) {
|
|
157
|
+
if (typeof value !== 'string') {
|
|
158
|
+
return undefined;
|
|
159
|
+
}
|
|
160
|
+
const trimmed = value.trim();
|
|
161
|
+
return trimmed.length ? trimmed : undefined;
|
|
162
|
+
}
|
|
163
|
+
//# sourceMappingURL=toolManifest.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
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KAAK,CAAC,wBAAwB,KAAK,oBAAoB,CAAC,CAAC;IACrE,CAAC;IACD,OAAO,OAAO,CAAC;AACjB,CAAC;AAED,SAAS,cAAc,CAAC,KAAc;IACpC,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE,CAAC;QAC9B,OAAO,SAAS,CAAC;IACnB,CAAC;IACD,MAAM,OAAO,GAAG,KAAK,CAAC,IAAI,EAAE,CAAC;IAC7B,OAAO,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,SAAS,CAAC;AAC9C,CAAC"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import type { ToolAvailabilityOption } from '../contracts/v1/toolAccess.js';
|
|
2
|
+
import type { ProfileName } from '../config.js';
|
|
3
|
+
import type { ToolSettings } from '../core/preferences.js';
|
|
4
|
+
import { type SecretName } from '../core/secretStore.js';
|
|
5
|
+
export type ToolToggleId = string;
|
|
6
|
+
export type ToolToggleOption = ToolAvailabilityOption & {
|
|
7
|
+
requiresSecret?: SecretName;
|
|
8
|
+
locked?: boolean;
|
|
9
|
+
restartRequired?: boolean;
|
|
10
|
+
};
|
|
11
|
+
export interface ToolPermissionSummary {
|
|
12
|
+
allowedPluginIds: Set<string>;
|
|
13
|
+
warnings: ToolLoadWarning[];
|
|
14
|
+
}
|
|
15
|
+
export interface ToolLoadWarning {
|
|
16
|
+
id: ToolToggleId;
|
|
17
|
+
label: string;
|
|
18
|
+
reason: 'missing-secret';
|
|
19
|
+
secretId?: SecretName;
|
|
20
|
+
}
|
|
21
|
+
export declare function getToolToggleOptions(): ToolToggleOption[];
|
|
22
|
+
export declare function buildEnabledToolSet(saved: ToolSettings | null, _profile?: ProfileName): Set<ToolToggleId>;
|
|
23
|
+
export declare function evaluateToolPermissions(selection: Set<ToolToggleId>): ToolPermissionSummary;
|
|
24
|
+
export declare function isPluginEnabled(pluginId: string, allowedPluginIds: Set<string>): boolean;
|
|
25
|
+
//# sourceMappingURL=toolRegistry.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-0,0 +1,150 @@
|
|
|
1
|
+
import { getSecretValue, listSecretDefinitions } from '../core/secretStore.js';
|
|
2
|
+
import { getToolManifest } from './toolManifest.js';
|
|
3
|
+
const SECRET_LOOKUP = buildSecretLookup();
|
|
4
|
+
const TOOL_OPTIONS = buildToolToggleOptions();
|
|
5
|
+
const PLUGIN_TO_OPTION = buildPluginLookup();
|
|
6
|
+
const LOCKED_OPTION_IDS = buildLockedOptionIds();
|
|
7
|
+
const DEFAULT_OPTION_IDS = buildDefaultOptionIds();
|
|
8
|
+
export function getToolToggleOptions() {
|
|
9
|
+
return [...TOOL_OPTIONS];
|
|
10
|
+
}
|
|
11
|
+
export function buildEnabledToolSet(saved, _profile) {
|
|
12
|
+
const enabled = new Set();
|
|
13
|
+
// Always include locked/default core packages to keep the AI flow intact
|
|
14
|
+
for (const id of LOCKED_OPTION_IDS) {
|
|
15
|
+
enabled.add(id);
|
|
16
|
+
}
|
|
17
|
+
if (!saved) {
|
|
18
|
+
for (const id of DEFAULT_OPTION_IDS) {
|
|
19
|
+
enabled.add(id);
|
|
20
|
+
}
|
|
21
|
+
return enabled;
|
|
22
|
+
}
|
|
23
|
+
const knownIds = new Set(TOOL_OPTIONS.map((option) => option.id));
|
|
24
|
+
for (const id of saved.enabledTools ?? []) {
|
|
25
|
+
if (knownIds.has(id)) {
|
|
26
|
+
enabled.add(id);
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
// Enforce locked/default packages even if missing from saved settings
|
|
30
|
+
for (const id of LOCKED_OPTION_IDS) {
|
|
31
|
+
enabled.add(id);
|
|
32
|
+
}
|
|
33
|
+
for (const id of DEFAULT_OPTION_IDS) {
|
|
34
|
+
enabled.add(id);
|
|
35
|
+
}
|
|
36
|
+
return enabled;
|
|
37
|
+
}
|
|
38
|
+
export function evaluateToolPermissions(selection) {
|
|
39
|
+
const allowedPluginIds = new Set();
|
|
40
|
+
const warnings = [];
|
|
41
|
+
for (const option of TOOL_OPTIONS) {
|
|
42
|
+
if (!selection.has(option.id)) {
|
|
43
|
+
continue;
|
|
44
|
+
}
|
|
45
|
+
if (option.requiresSecret) {
|
|
46
|
+
const secret = getSecretValue(option.requiresSecret);
|
|
47
|
+
if (!secret) {
|
|
48
|
+
warnings.push({
|
|
49
|
+
id: option.id,
|
|
50
|
+
label: option.label,
|
|
51
|
+
reason: 'missing-secret',
|
|
52
|
+
secretId: option.requiresSecret,
|
|
53
|
+
});
|
|
54
|
+
continue;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
for (const pluginId of option.pluginIds) {
|
|
58
|
+
allowedPluginIds.add(pluginId);
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
return {
|
|
62
|
+
allowedPluginIds,
|
|
63
|
+
warnings,
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
export function isPluginEnabled(pluginId, allowedPluginIds) {
|
|
67
|
+
const associated = PLUGIN_TO_OPTION.get(pluginId);
|
|
68
|
+
if (!associated) {
|
|
69
|
+
return true;
|
|
70
|
+
}
|
|
71
|
+
return allowedPluginIds.has(pluginId);
|
|
72
|
+
}
|
|
73
|
+
function buildPluginLookup() {
|
|
74
|
+
const map = new Map();
|
|
75
|
+
for (const option of TOOL_OPTIONS) {
|
|
76
|
+
for (const pluginId of option.pluginIds) {
|
|
77
|
+
map.set(pluginId, option);
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
return map;
|
|
81
|
+
}
|
|
82
|
+
function buildToolToggleOptions() {
|
|
83
|
+
const manifest = getToolManifest();
|
|
84
|
+
return manifest.options.map((option) => normalizeToggleOption(option));
|
|
85
|
+
}
|
|
86
|
+
function buildLockedOptionIds() {
|
|
87
|
+
const ids = new Set();
|
|
88
|
+
for (const option of TOOL_OPTIONS) {
|
|
89
|
+
if (option.locked) {
|
|
90
|
+
ids.add(option.id);
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
return ids;
|
|
94
|
+
}
|
|
95
|
+
function buildDefaultOptionIds() {
|
|
96
|
+
const ids = new Set();
|
|
97
|
+
for (const option of TOOL_OPTIONS) {
|
|
98
|
+
if (option.defaultEnabled) {
|
|
99
|
+
ids.add(option.id);
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
return ids;
|
|
103
|
+
}
|
|
104
|
+
function normalizeToggleOption(option) {
|
|
105
|
+
const pluginIds = option.pluginIds ?? [];
|
|
106
|
+
if (!pluginIds.length) {
|
|
107
|
+
throw new Error(`Tool option "${option.id}" is missing plugin bindings.`);
|
|
108
|
+
}
|
|
109
|
+
const normalized = {
|
|
110
|
+
id: option.id,
|
|
111
|
+
label: option.label,
|
|
112
|
+
description: option.description,
|
|
113
|
+
defaultEnabled: option.defaultEnabled,
|
|
114
|
+
pluginIds: [...pluginIds],
|
|
115
|
+
};
|
|
116
|
+
if (option.category) {
|
|
117
|
+
normalized.category = option.category;
|
|
118
|
+
}
|
|
119
|
+
if (option.scopes?.length) {
|
|
120
|
+
normalized.scopes = [...option.scopes];
|
|
121
|
+
}
|
|
122
|
+
const secret = normalizeSecret(option.requiresSecret);
|
|
123
|
+
if (secret) {
|
|
124
|
+
normalized.requiresSecret = secret;
|
|
125
|
+
}
|
|
126
|
+
if (option.metadata) {
|
|
127
|
+
normalized.metadata = { ...option.metadata };
|
|
128
|
+
}
|
|
129
|
+
if (option.metadata && option.metadata['locked'] === true) {
|
|
130
|
+
normalized.locked = true;
|
|
131
|
+
}
|
|
132
|
+
if (option.metadata && option.metadata['restartRequired'] === true) {
|
|
133
|
+
normalized.restartRequired = true;
|
|
134
|
+
}
|
|
135
|
+
return normalized;
|
|
136
|
+
}
|
|
137
|
+
function buildSecretLookup() {
|
|
138
|
+
const ids = listSecretDefinitions().map((secret) => secret.id);
|
|
139
|
+
return new Set(ids);
|
|
140
|
+
}
|
|
141
|
+
function normalizeSecret(value) {
|
|
142
|
+
if (!value) {
|
|
143
|
+
return undefined;
|
|
144
|
+
}
|
|
145
|
+
if (!SECRET_LOOKUP.has(value)) {
|
|
146
|
+
throw new Error(`Tool manifest references unknown secret "${value}".`);
|
|
147
|
+
}
|
|
148
|
+
return value;
|
|
149
|
+
}
|
|
150
|
+
//# sourceMappingURL=toolRegistry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toolRegistry.js","sourceRoot":"","sources":["../../src/capabilities/toolRegistry.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,cAAc,EAAE,qBAAqB,EAAmB,MAAM,wBAAwB,CAAC;AAChG,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAsBpD,MAAM,aAAa,GAAG,iBAAiB,EAAE,CAAC;AAE1C,MAAM,YAAY,GAAuB,sBAAsB,EAAE,CAAC;AAElE,MAAM,gBAAgB,GAAG,iBAAiB,EAAE,CAAC;AAC7C,MAAM,iBAAiB,GAAG,oBAAoB,EAAE,CAAC;AACjD,MAAM,kBAAkB,GAAG,qBAAqB,EAAE,CAAC;AAEnD,MAAM,UAAU,oBAAoB;IAClC,OAAO,CAAC,GAAG,YAAY,CAAC,CAAC;AAC3B,CAAC;AAED,MAAM,UAAU,mBAAmB,CAAC,KAA0B,EAAE,QAAsB;IACpF,MAAM,OAAO,GAAG,IAAI,GAAG,EAAgB,CAAC;IACxC,yEAAyE;IACzE,KAAK,MAAM,EAAE,IAAI,iBAAiB,EAAE,CAAC;QACnC,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;IAClB,CAAC;IAED,IAAI,CAAC,KAAK,EAAE,CAAC;QACX,KAAK,MAAM,EAAE,IAAI,kBAAkB,EAAE,CAAC;YACpC,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;QAClB,CAAC;QACD,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,MAAM,QAAQ,GAAG,IAAI,GAAG,CAAC,YAAY,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,CAAC;IAClE,KAAK,MAAM,EAAE,IAAI,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,MAAM,GAAG,IAAI,CAAC;IAC3B,CAAC;IACD,IAAI,MAAM,CAAC,QAAQ,IAAI,MAAM,CAAC,QAAQ,CAAC,iBAAiB,CAAC,KAAK,IAAI,EAAE,CAAC;QACnE,UAAU,CAAC,eAAe,GAAG,IAAI,CAAC;IACpC,CAAC;IAED,OAAO,UAAU,CAAC;AACpB,CAAC;AAED,SAAS,iBAAiB;IACxB,MAAM,GAAG,GAAG,qBAAqB,EAAE,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC;IAC/D,OAAO,IAAI,GAAG,CAAC,GAAG,CAAC,CAAC;AACtB,CAAC;AAED,SAAS,eAAe,CAAC,KAAyB;IAChD,IAAI,CAAC,KAAK,EAAE,CAAC;QACX,OAAO,SAAS,CAAC;IACnB,CAAC;IACD,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,KAAmB,CAAC,EAAE,CAAC;QAC5C,MAAM,IAAI,KAAK,CAAC,4CAA4C,KAAK,IAAI,CAAC,CAAC;IACzE,CAAC;IACD,OAAO,KAAmB,CAAC;AAC7B,CAAC"}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* UNIFIED CODING CAPABILITY
|
|
3
|
+
*
|
|
4
|
+
* A lean, consolidated capability module that provides all essential
|
|
5
|
+
* tools for an AI coding assistant in a single, coherent interface.
|
|
6
|
+
*
|
|
7
|
+
* Consolidates: Filesystem, Edit, Bash, Search, Git, Web
|
|
8
|
+
*/
|
|
9
|
+
import type { CapabilityContribution, CapabilityContext, CapabilityModule } from '../runtime/agentHost.js';
|
|
10
|
+
import type { LLMProvider } from '../core/types.js';
|
|
11
|
+
export interface UnifiedCodingOptions {
|
|
12
|
+
workingDir?: string;
|
|
13
|
+
enableGit?: boolean;
|
|
14
|
+
enableWeb?: boolean;
|
|
15
|
+
enableBash?: boolean;
|
|
16
|
+
maxFileSize?: number;
|
|
17
|
+
timeout?: number;
|
|
18
|
+
/** LLM provider for parallel agent spawning */
|
|
19
|
+
provider?: LLMProvider;
|
|
20
|
+
providerId?: string;
|
|
21
|
+
modelId?: string;
|
|
22
|
+
/** When set, this capability is being built FOR a sub-agent: the
|
|
23
|
+
* unified suite is filtered down to the tools that subagent_type is
|
|
24
|
+
* allowed to use. The parent's capability is built with this unset
|
|
25
|
+
* (or 'general'). */
|
|
26
|
+
subagentType?: import('../core/agentRegistry.js').AgentType;
|
|
27
|
+
/** Optional explicit allow-list. Overrides `subagentType` filtering
|
|
28
|
+
* if both are set. Used internally when callers want a custom
|
|
29
|
+
* toolset for a one-off sub-agent. */
|
|
30
|
+
allowedToolNames?: ReadonlySet<string>;
|
|
31
|
+
/** Shared registry for the parent agent — child agents access this
|
|
32
|
+
* via the `Agent` and lifecycle tools. Created lazily on first use
|
|
33
|
+
* if not passed in. */
|
|
34
|
+
agentRegistry?: import('../core/agentRegistry.js').AgentRegistry;
|
|
35
|
+
}
|
|
36
|
+
export declare class UnifiedCodingCapabilityModule implements CapabilityModule {
|
|
37
|
+
readonly id = "unified-coding";
|
|
38
|
+
private readonly options;
|
|
39
|
+
constructor(options?: UnifiedCodingOptions);
|
|
40
|
+
create(_context: CapabilityContext): Promise<CapabilityContribution>;
|
|
41
|
+
private buildToolSuite;
|
|
42
|
+
private createReadFileTool;
|
|
43
|
+
private createWriteFileTool;
|
|
44
|
+
private createListFilesTool;
|
|
45
|
+
private createFileExistsTool;
|
|
46
|
+
private createEditFileTool;
|
|
47
|
+
private createSearchReplaceTool;
|
|
48
|
+
private createGrepTool;
|
|
49
|
+
private createGlobTool;
|
|
50
|
+
private createBashTool;
|
|
51
|
+
private createGitTool;
|
|
52
|
+
private createWebFetchTool;
|
|
53
|
+
private createAgentSpawnTools;
|
|
54
|
+
private subagentSystemPrompt;
|
|
55
|
+
private resolvePath;
|
|
56
|
+
private listDirectory;
|
|
57
|
+
private globToRegex;
|
|
58
|
+
private escapeRegex;
|
|
59
|
+
}
|
|
60
|
+
export declare function createUnifiedCodingCapability(options?: UnifiedCodingOptions): UnifiedCodingCapabilityModule;
|
|
61
|
+
export default UnifiedCodingCapabilityModule;
|
|
62
|
+
//# sourceMappingURL=unifiedCodingCapability.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"unifiedCodingCapability.d.ts","sourceRoot":"","sources":["../../src/capabilities/unifiedCodingCapability.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,KAAK,EAAE,sBAAsB,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAQ3G,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAMpD,MAAM,WAAW,oBAAoB;IACnC,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,+CAA+C;IAC/C,QAAQ,CAAC,EAAE,WAAW,CAAC;IACvB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB;;;0BAGsB;IACtB,YAAY,CAAC,EAAE,OAAO,0BAA0B,EAAE,SAAS,CAAC;IAC5D;;2CAEuC;IACvC,gBAAgB,CAAC,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC;IACvC;;4BAEwB;IACxB,aAAa,CAAC,EAAE,OAAO,0BAA0B,EAAE,aAAa,CAAC;CAClE;AAgDD,qBAAa,6BAA8B,YAAW,gBAAgB;IACpE,QAAQ,CAAC,EAAE,oBAAoB;IAC/B,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAwB;gBAEpC,OAAO,GAAE,oBAAyB;IAiBxC,MAAM,CAAC,QAAQ,EAAE,iBAAiB,GAAG,OAAO,CAAC,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