@intrect/openswarm 0.2.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/LICENSE +21 -0
- package/README.md +544 -0
- package/config.example.yaml +107 -0
- package/dist/adapters/base.d.ts +8 -0
- package/dist/adapters/base.d.ts.map +1 -0
- package/dist/adapters/base.js +104 -0
- package/dist/adapters/base.js.map +1 -0
- package/dist/adapters/claude.d.ts +13 -0
- package/dist/adapters/claude.d.ts.map +1 -0
- package/dist/adapters/claude.js +318 -0
- package/dist/adapters/claude.js.map +1 -0
- package/dist/adapters/codex.d.ts +14 -0
- package/dist/adapters/codex.d.ts.map +1 -0
- package/dist/adapters/codex.js +366 -0
- package/dist/adapters/codex.js.map +1 -0
- package/dist/adapters/cryptoQuantAdapter.d.ts +85 -0
- package/dist/adapters/cryptoQuantAdapter.d.ts.map +1 -0
- package/dist/adapters/cryptoQuantAdapter.js +238 -0
- package/dist/adapters/cryptoQuantAdapter.js.map +1 -0
- package/dist/adapters/index.d.ts +17 -0
- package/dist/adapters/index.d.ts.map +1 -0
- package/dist/adapters/index.js +47 -0
- package/dist/adapters/index.js.map +1 -0
- package/dist/adapters/processRegistry.d.ts +38 -0
- package/dist/adapters/processRegistry.d.ts.map +1 -0
- package/dist/adapters/processRegistry.js +147 -0
- package/dist/adapters/processRegistry.js.map +1 -0
- package/dist/adapters/streamBuffer.d.ts +59 -0
- package/dist/adapters/streamBuffer.d.ts.map +1 -0
- package/dist/adapters/streamBuffer.js +123 -0
- package/dist/adapters/streamBuffer.js.map +1 -0
- package/dist/adapters/types.d.ts +65 -0
- package/dist/adapters/types.d.ts.map +1 -0
- package/dist/adapters/types.js +6 -0
- package/dist/adapters/types.js.map +1 -0
- package/dist/agents/agentBus.d.ts +160 -0
- package/dist/agents/agentBus.d.ts.map +1 -0
- package/dist/agents/agentBus.js +350 -0
- package/dist/agents/agentBus.js.map +1 -0
- package/dist/agents/agentPair.d.ts +210 -0
- package/dist/agents/agentPair.d.ts.map +1 -0
- package/dist/agents/agentPair.js +420 -0
- package/dist/agents/agentPair.js.map +1 -0
- package/dist/agents/auditor.d.ts +27 -0
- package/dist/agents/auditor.d.ts.map +1 -0
- package/dist/agents/auditor.js +237 -0
- package/dist/agents/auditor.js.map +1 -0
- package/dist/agents/cliStreamParser.d.ts +18 -0
- package/dist/agents/cliStreamParser.d.ts.map +1 -0
- package/dist/agents/cliStreamParser.js +156 -0
- package/dist/agents/cliStreamParser.js.map +1 -0
- package/dist/agents/documenter.d.ts +31 -0
- package/dist/agents/documenter.d.ts.map +1 -0
- package/dist/agents/documenter.js +285 -0
- package/dist/agents/documenter.js.map +1 -0
- package/dist/agents/index.d.ts +10 -0
- package/dist/agents/index.d.ts.map +1 -0
- package/dist/agents/index.js +10 -0
- package/dist/agents/index.js.map +1 -0
- package/dist/agents/pairMetrics.d.ts +63 -0
- package/dist/agents/pairMetrics.d.ts.map +1 -0
- package/dist/agents/pairMetrics.js +231 -0
- package/dist/agents/pairMetrics.js.map +1 -0
- package/dist/agents/pairPipeline.d.ts +155 -0
- package/dist/agents/pairPipeline.d.ts.map +1 -0
- package/dist/agents/pairPipeline.js +793 -0
- package/dist/agents/pairPipeline.js.map +1 -0
- package/dist/agents/pairWebhook.d.ts +59 -0
- package/dist/agents/pairWebhook.d.ts.map +1 -0
- package/dist/agents/pairWebhook.js +242 -0
- package/dist/agents/pairWebhook.js.map +1 -0
- package/dist/agents/pipelineFormat.d.ts +11 -0
- package/dist/agents/pipelineFormat.d.ts.map +1 -0
- package/dist/agents/pipelineFormat.js +164 -0
- package/dist/agents/pipelineFormat.js.map +1 -0
- package/dist/agents/pipelineGuards.d.ts +23 -0
- package/dist/agents/pipelineGuards.d.ts.map +1 -0
- package/dist/agents/pipelineGuards.js +175 -0
- package/dist/agents/pipelineGuards.js.map +1 -0
- package/dist/agents/reviewer.d.ts +37 -0
- package/dist/agents/reviewer.d.ts.map +1 -0
- package/dist/agents/reviewer.js +213 -0
- package/dist/agents/reviewer.js.map +1 -0
- package/dist/agents/skillDocumenter.d.ts +23 -0
- package/dist/agents/skillDocumenter.d.ts.map +1 -0
- package/dist/agents/skillDocumenter.js +218 -0
- package/dist/agents/skillDocumenter.js.map +1 -0
- package/dist/agents/tester.d.ts +37 -0
- package/dist/agents/tester.d.ts.map +1 -0
- package/dist/agents/tester.js +308 -0
- package/dist/agents/tester.js.map +1 -0
- package/dist/agents/worker.d.ts +30 -0
- package/dist/agents/worker.d.ts.map +1 -0
- package/dist/agents/worker.js +128 -0
- package/dist/agents/worker.js.map +1 -0
- package/dist/automation/autonomousRunner.d.ts +123 -0
- package/dist/automation/autonomousRunner.d.ts.map +1 -0
- package/dist/automation/autonomousRunner.js +1082 -0
- package/dist/automation/autonomousRunner.js.map +1 -0
- package/dist/automation/ciWorker.d.ts +51 -0
- package/dist/automation/ciWorker.d.ts.map +1 -0
- package/dist/automation/ciWorker.js +282 -0
- package/dist/automation/ciWorker.js.map +1 -0
- package/dist/automation/conflictResolver.d.ts +29 -0
- package/dist/automation/conflictResolver.d.ts.map +1 -0
- package/dist/automation/conflictResolver.js +261 -0
- package/dist/automation/conflictResolver.js.map +1 -0
- package/dist/automation/dailyReporter.d.ts +26 -0
- package/dist/automation/dailyReporter.d.ts.map +1 -0
- package/dist/automation/dailyReporter.js +132 -0
- package/dist/automation/dailyReporter.js.map +1 -0
- package/dist/automation/index.d.ts +7 -0
- package/dist/automation/index.d.ts.map +1 -0
- package/dist/automation/index.js +7 -0
- package/dist/automation/index.js.map +1 -0
- package/dist/automation/longRunningMonitor.d.ts +26 -0
- package/dist/automation/longRunningMonitor.d.ts.map +1 -0
- package/dist/automation/longRunningMonitor.js +231 -0
- package/dist/automation/longRunningMonitor.js.map +1 -0
- package/dist/automation/prOwnership.d.ts +18 -0
- package/dist/automation/prOwnership.d.ts.map +1 -0
- package/dist/automation/prOwnership.js +61 -0
- package/dist/automation/prOwnership.js.map +1 -0
- package/dist/automation/prProcessor.d.ts +62 -0
- package/dist/automation/prProcessor.d.ts.map +1 -0
- package/dist/automation/prProcessor.js +700 -0
- package/dist/automation/prProcessor.js.map +1 -0
- package/dist/automation/runnerExecution.d.ts +49 -0
- package/dist/automation/runnerExecution.d.ts.map +1 -0
- package/dist/automation/runnerExecution.js +663 -0
- package/dist/automation/runnerExecution.js.map +1 -0
- package/dist/automation/runnerState.d.ts +170 -0
- package/dist/automation/runnerState.d.ts.map +1 -0
- package/dist/automation/runnerState.js +495 -0
- package/dist/automation/runnerState.js.map +1 -0
- package/dist/automation/runnerTypes.d.ts +46 -0
- package/dist/automation/runnerTypes.d.ts.map +1 -0
- package/dist/automation/runnerTypes.js +5 -0
- package/dist/automation/runnerTypes.js.map +1 -0
- package/dist/automation/scheduler.d.ts +75 -0
- package/dist/automation/scheduler.d.ts.map +1 -0
- package/dist/automation/scheduler.js +394 -0
- package/dist/automation/scheduler.js.map +1 -0
- package/dist/cli/promptHandler.d.ts +13 -0
- package/dist/cli/promptHandler.d.ts.map +1 -0
- package/dist/cli/promptHandler.js +189 -0
- package/dist/cli/promptHandler.js.map +1 -0
- package/dist/cli.d.ts +3 -0
- package/dist/cli.d.ts.map +1 -0
- package/dist/cli.js +138 -0
- package/dist/cli.js.map +1 -0
- package/dist/core/config.d.ts +308 -0
- package/dist/core/config.d.ts.map +1 -0
- package/dist/core/config.js +529 -0
- package/dist/core/config.js.map +1 -0
- package/dist/core/eventHub.d.ts +194 -0
- package/dist/core/eventHub.d.ts.map +1 -0
- package/dist/core/eventHub.js +136 -0
- package/dist/core/eventHub.js.map +1 -0
- package/dist/core/index.d.ts +6 -0
- package/dist/core/index.d.ts.map +1 -0
- package/dist/core/index.js +6 -0
- package/dist/core/index.js.map +1 -0
- package/dist/core/service.d.ts +27 -0
- package/dist/core/service.d.ts.map +1 -0
- package/dist/core/service.js +438 -0
- package/dist/core/service.js.map +1 -0
- package/dist/core/traceCollector.d.ts +105 -0
- package/dist/core/traceCollector.d.ts.map +1 -0
- package/dist/core/traceCollector.js +141 -0
- package/dist/core/traceCollector.js.map +1 -0
- package/dist/core/types.d.ts +413 -0
- package/dist/core/types.d.ts.map +1 -0
- package/dist/core/types.js +5 -0
- package/dist/core/types.js.map +1 -0
- package/dist/discord/discordCore.d.ts +104 -0
- package/dist/discord/discordCore.d.ts.map +1 -0
- package/dist/discord/discordCore.js +698 -0
- package/dist/discord/discordCore.js.map +1 -0
- package/dist/discord/discordHandlers.d.ts +86 -0
- package/dist/discord/discordHandlers.d.ts.map +1 -0
- package/dist/discord/discordHandlers.js +849 -0
- package/dist/discord/discordHandlers.js.map +1 -0
- package/dist/discord/discordPair.d.ts +6 -0
- package/dist/discord/discordPair.d.ts.map +1 -0
- package/dist/discord/discordPair.js +567 -0
- package/dist/discord/discordPair.js.map +1 -0
- package/dist/discord/index.d.ts +4 -0
- package/dist/discord/index.d.ts.map +1 -0
- package/dist/discord/index.js +11 -0
- package/dist/discord/index.js.map +1 -0
- package/dist/github/github.d.ts +236 -0
- package/dist/github/github.d.ts.map +1 -0
- package/dist/github/github.js +535 -0
- package/dist/github/github.js.map +1 -0
- package/dist/github/index.d.ts +2 -0
- package/dist/github/index.d.ts.map +1 -0
- package/dist/github/index.js +2 -0
- package/dist/github/index.js.map +1 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +60 -0
- package/dist/index.js.map +1 -0
- package/dist/knowledge/analyzer.d.ts +36 -0
- package/dist/knowledge/analyzer.d.ts.map +1 -0
- package/dist/knowledge/analyzer.js +170 -0
- package/dist/knowledge/analyzer.js.map +1 -0
- package/dist/knowledge/gitInfo.d.ts +10 -0
- package/dist/knowledge/gitInfo.d.ts.map +1 -0
- package/dist/knowledge/gitInfo.js +134 -0
- package/dist/knowledge/gitInfo.js.map +1 -0
- package/dist/knowledge/graph.d.ts +45 -0
- package/dist/knowledge/graph.d.ts.map +1 -0
- package/dist/knowledge/graph.js +262 -0
- package/dist/knowledge/graph.js.map +1 -0
- package/dist/knowledge/graphqlExporter.d.ts +64 -0
- package/dist/knowledge/graphqlExporter.d.ts.map +1 -0
- package/dist/knowledge/graphqlExporter.js +333 -0
- package/dist/knowledge/graphqlExporter.js.map +1 -0
- package/dist/knowledge/index.d.ts +58 -0
- package/dist/knowledge/index.d.ts.map +1 -0
- package/dist/knowledge/index.js +212 -0
- package/dist/knowledge/index.js.map +1 -0
- package/dist/knowledge/repository.d.ts +64 -0
- package/dist/knowledge/repository.d.ts.map +1 -0
- package/dist/knowledge/repository.js +250 -0
- package/dist/knowledge/repository.js.map +1 -0
- package/dist/knowledge/riskOnAnalyzer.d.ts +79 -0
- package/dist/knowledge/riskOnAnalyzer.d.ts.map +1 -0
- package/dist/knowledge/riskOnAnalyzer.js +243 -0
- package/dist/knowledge/riskOnAnalyzer.js.map +1 -0
- package/dist/knowledge/scanner.d.ts +14 -0
- package/dist/knowledge/scanner.d.ts.map +1 -0
- package/dist/knowledge/scanner.js +350 -0
- package/dist/knowledge/scanner.js.map +1 -0
- package/dist/knowledge/store.d.ts +23 -0
- package/dist/knowledge/store.d.ts.map +1 -0
- package/dist/knowledge/store.js +86 -0
- package/dist/knowledge/store.js.map +1 -0
- package/dist/knowledge/types.d.ts +288 -0
- package/dist/knowledge/types.d.ts.map +1 -0
- package/dist/knowledge/types.js +111 -0
- package/dist/knowledge/types.js.map +1 -0
- package/dist/linear/index.d.ts +3 -0
- package/dist/linear/index.d.ts.map +1 -0
- package/dist/linear/index.js +3 -0
- package/dist/linear/index.js.map +1 -0
- package/dist/linear/linear.d.ts +160 -0
- package/dist/linear/linear.d.ts.map +1 -0
- package/dist/linear/linear.js +983 -0
- package/dist/linear/linear.js.map +1 -0
- package/dist/linear/projectUpdater.d.ts +23 -0
- package/dist/linear/projectUpdater.d.ts.map +1 -0
- package/dist/linear/projectUpdater.js +347 -0
- package/dist/linear/projectUpdater.js.map +1 -0
- package/dist/locale/en.d.ts +3 -0
- package/dist/locale/en.d.ts.map +1 -0
- package/dist/locale/en.js +436 -0
- package/dist/locale/en.js.map +1 -0
- package/dist/locale/index.d.ts +28 -0
- package/dist/locale/index.d.ts.map +1 -0
- package/dist/locale/index.js +89 -0
- package/dist/locale/index.js.map +1 -0
- package/dist/locale/ko.d.ts +3 -0
- package/dist/locale/ko.d.ts.map +1 -0
- package/dist/locale/ko.js +436 -0
- package/dist/locale/ko.js.map +1 -0
- package/dist/locale/prompts/en.d.ts +3 -0
- package/dist/locale/prompts/en.d.ts.map +1 -0
- package/dist/locale/prompts/en.js +278 -0
- package/dist/locale/prompts/en.js.map +1 -0
- package/dist/locale/prompts/ko.d.ts +3 -0
- package/dist/locale/prompts/ko.d.ts.map +1 -0
- package/dist/locale/prompts/ko.js +279 -0
- package/dist/locale/prompts/ko.js.map +1 -0
- package/dist/locale/types.d.ts +407 -0
- package/dist/locale/types.d.ts.map +1 -0
- package/dist/locale/types.js +5 -0
- package/dist/locale/types.js.map +1 -0
- package/dist/memory/codex.d.ts +93 -0
- package/dist/memory/codex.d.ts.map +1 -0
- package/dist/memory/codex.js +366 -0
- package/dist/memory/codex.js.map +1 -0
- package/dist/memory/compaction.d.ts +21 -0
- package/dist/memory/compaction.d.ts.map +1 -0
- package/dist/memory/compaction.js +205 -0
- package/dist/memory/compaction.js.map +1 -0
- package/dist/memory/index.d.ts +13 -0
- package/dist/memory/index.d.ts.map +1 -0
- package/dist/memory/index.js +13 -0
- package/dist/memory/index.js.map +1 -0
- package/dist/memory/memoryCore.d.ts +178 -0
- package/dist/memory/memoryCore.d.ts.map +1 -0
- package/dist/memory/memoryCore.js +623 -0
- package/dist/memory/memoryCore.js.map +1 -0
- package/dist/memory/memoryOps.d.ts +90 -0
- package/dist/memory/memoryOps.d.ts.map +1 -0
- package/dist/memory/memoryOps.js +606 -0
- package/dist/memory/memoryOps.js.map +1 -0
- package/dist/orchestration/conflictDetector.d.ts +15 -0
- package/dist/orchestration/conflictDetector.d.ts.map +1 -0
- package/dist/orchestration/conflictDetector.js +130 -0
- package/dist/orchestration/conflictDetector.js.map +1 -0
- package/dist/orchestration/decisionEngine.d.ts +177 -0
- package/dist/orchestration/decisionEngine.d.ts.map +1 -0
- package/dist/orchestration/decisionEngine.js +496 -0
- package/dist/orchestration/decisionEngine.js.map +1 -0
- package/dist/orchestration/index.d.ts +5 -0
- package/dist/orchestration/index.d.ts.map +1 -0
- package/dist/orchestration/index.js +5 -0
- package/dist/orchestration/index.js.map +1 -0
- package/dist/orchestration/taskParser.d.ts +67 -0
- package/dist/orchestration/taskParser.d.ts.map +1 -0
- package/dist/orchestration/taskParser.js +542 -0
- package/dist/orchestration/taskParser.js.map +1 -0
- package/dist/orchestration/taskScheduler.d.ts +141 -0
- package/dist/orchestration/taskScheduler.d.ts.map +1 -0
- package/dist/orchestration/taskScheduler.js +317 -0
- package/dist/orchestration/taskScheduler.js.map +1 -0
- package/dist/orchestration/workflow.d.ts +145 -0
- package/dist/orchestration/workflow.d.ts.map +1 -0
- package/dist/orchestration/workflow.js +301 -0
- package/dist/orchestration/workflow.js.map +1 -0
- package/dist/runners/cliRunner.d.ts +11 -0
- package/dist/runners/cliRunner.d.ts.map +1 -0
- package/dist/runners/cliRunner.js +194 -0
- package/dist/runners/cliRunner.js.map +1 -0
- package/dist/support/apiCache.d.ts +85 -0
- package/dist/support/apiCache.d.ts.map +1 -0
- package/dist/support/apiCache.js +163 -0
- package/dist/support/apiCache.js.map +1 -0
- package/dist/support/chat.d.ts +3 -0
- package/dist/support/chat.d.ts.map +1 -0
- package/dist/support/chat.js +304 -0
- package/dist/support/chat.js.map +1 -0
- package/dist/support/chatBackend.d.ts +25 -0
- package/dist/support/chatBackend.d.ts.map +1 -0
- package/dist/support/chatBackend.js +235 -0
- package/dist/support/chatBackend.js.map +1 -0
- package/dist/support/chatMemory.d.ts +71 -0
- package/dist/support/chatMemory.d.ts.map +1 -0
- package/dist/support/chatMemory.js +119 -0
- package/dist/support/chatMemory.js.map +1 -0
- package/dist/support/chatTui.d.ts +3 -0
- package/dist/support/chatTui.d.ts.map +1 -0
- package/dist/support/chatTui.js +998 -0
- package/dist/support/chatTui.js.map +1 -0
- package/dist/support/costTracker.d.ts +29 -0
- package/dist/support/costTracker.d.ts.map +1 -0
- package/dist/support/costTracker.js +113 -0
- package/dist/support/costTracker.js.map +1 -0
- package/dist/support/dashboardHtml.d.ts +3 -0
- package/dist/support/dashboardHtml.d.ts.map +1 -0
- package/dist/support/dashboardHtml.js +2070 -0
- package/dist/support/dashboardHtml.js.map +1 -0
- package/dist/support/delete-beliefs.d.ts +2 -0
- package/dist/support/delete-beliefs.d.ts.map +1 -0
- package/dist/support/delete-beliefs.js +34 -0
- package/dist/support/delete-beliefs.js.map +1 -0
- package/dist/support/dev.d.ts +55 -0
- package/dist/support/dev.d.ts.map +1 -0
- package/dist/support/dev.js +298 -0
- package/dist/support/dev.js.map +1 -0
- package/dist/support/editParser.d.ts +37 -0
- package/dist/support/editParser.d.ts.map +1 -0
- package/dist/support/editParser.js +365 -0
- package/dist/support/editParser.js.map +1 -0
- package/dist/support/gitStatus.d.ts +21 -0
- package/dist/support/gitStatus.d.ts.map +1 -0
- package/dist/support/gitStatus.js +108 -0
- package/dist/support/gitStatus.js.map +1 -0
- package/dist/support/gitTracker.d.ts +30 -0
- package/dist/support/gitTracker.d.ts.map +1 -0
- package/dist/support/gitTracker.js +143 -0
- package/dist/support/gitTracker.js.map +1 -0
- package/dist/support/index.d.ts +13 -0
- package/dist/support/index.d.ts.map +1 -0
- package/dist/support/index.js +13 -0
- package/dist/support/index.js.map +1 -0
- package/dist/support/planner.d.ts +58 -0
- package/dist/support/planner.d.ts.map +1 -0
- package/dist/support/planner.js +395 -0
- package/dist/support/planner.js.map +1 -0
- package/dist/support/projectMapper.d.ts +46 -0
- package/dist/support/projectMapper.d.ts.map +1 -0
- package/dist/support/projectMapper.js +259 -0
- package/dist/support/projectMapper.js.map +1 -0
- package/dist/support/quotaTracker.d.ts +29 -0
- package/dist/support/quotaTracker.d.ts.map +1 -0
- package/dist/support/quotaTracker.js +89 -0
- package/dist/support/quotaTracker.js.map +1 -0
- package/dist/support/rateLimiter.d.ts +101 -0
- package/dist/support/rateLimiter.d.ts.map +1 -0
- package/dist/support/rateLimiter.js +219 -0
- package/dist/support/rateLimiter.js.map +1 -0
- package/dist/support/rollback.d.ts +61 -0
- package/dist/support/rollback.d.ts.map +1 -0
- package/dist/support/rollback.js +328 -0
- package/dist/support/rollback.js.map +1 -0
- package/dist/support/stuckDetector.d.ts +68 -0
- package/dist/support/stuckDetector.d.ts.map +1 -0
- package/dist/support/stuckDetector.js +174 -0
- package/dist/support/stuckDetector.js.map +1 -0
- package/dist/support/timeWindow.d.ts +60 -0
- package/dist/support/timeWindow.d.ts.map +1 -0
- package/dist/support/timeWindow.js +236 -0
- package/dist/support/timeWindow.js.map +1 -0
- package/dist/support/web.d.ts +11 -0
- package/dist/support/web.d.ts.map +1 -0
- package/dist/support/web.js +938 -0
- package/dist/support/web.js.map +1 -0
- package/dist/support/workflowLinear.d.ts +99 -0
- package/dist/support/workflowLinear.d.ts.map +1 -0
- package/dist/support/workflowLinear.js +257 -0
- package/dist/support/workflowLinear.js.map +1 -0
- package/dist/support/worktreeManager.d.ts +20 -0
- package/dist/support/worktreeManager.d.ts.map +1 -0
- package/dist/support/worktreeManager.js +144 -0
- package/dist/support/worktreeManager.js.map +1 -0
- package/dist/taskState/store.d.ts +101 -0
- package/dist/taskState/store.d.ts.map +1 -0
- package/dist/taskState/store.js +346 -0
- package/dist/taskState/store.js.map +1 -0
- package/package.json +70 -0
- package/templates/AGENTS.md +432 -0
- package/templates/BOOT.md +25 -0
- package/templates/BOOTSTRAP.md +50 -0
- package/templates/CHANGELOG_AUDIT.md +74 -0
- package/templates/HEARTBEAT.md +86 -0
- package/templates/IDENTITY.md +27 -0
- package/templates/ISSUE_ANALYSIS.md +31 -0
- package/templates/PR_LAND.md +75 -0
- package/templates/PR_REVIEW.md +97 -0
- package/templates/SOUL.dev.md +52 -0
- package/templates/SOUL.md +81 -0
- package/templates/TOOLS.md +52 -0
- package/templates/USER.md +22 -0
|
@@ -0,0 +1,350 @@
|
|
|
1
|
+
// ============================================
|
|
2
|
+
// OpenSwarm - Agent Message Bus
|
|
3
|
+
// Inter-agent context sharing system
|
|
4
|
+
// ============================================
|
|
5
|
+
import { resolve } from 'path';
|
|
6
|
+
import { homedir } from 'os';
|
|
7
|
+
import * as fs from 'fs/promises';
|
|
8
|
+
import { existsSync } from 'fs';
|
|
9
|
+
// Bus Implementation (File-based)
|
|
10
|
+
const BUS_DIR = resolve(homedir(), '.openswarm/bus');
|
|
11
|
+
/**
|
|
12
|
+
* Message bus class
|
|
13
|
+
*/
|
|
14
|
+
export class AgentBus {
|
|
15
|
+
executionId;
|
|
16
|
+
contextPath;
|
|
17
|
+
messagesPath;
|
|
18
|
+
listeners = new Map();
|
|
19
|
+
pollInterval = null;
|
|
20
|
+
lastMessageId = '';
|
|
21
|
+
constructor(executionId) {
|
|
22
|
+
this.executionId = executionId;
|
|
23
|
+
this.contextPath = resolve(BUS_DIR, executionId, 'context.json');
|
|
24
|
+
this.messagesPath = resolve(BUS_DIR, executionId, 'messages');
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* Initialize bus
|
|
28
|
+
*/
|
|
29
|
+
async init(workflowId) {
|
|
30
|
+
await fs.mkdir(resolve(BUS_DIR, this.executionId, 'messages'), { recursive: true });
|
|
31
|
+
// Create initial context
|
|
32
|
+
const context = {
|
|
33
|
+
executionId: this.executionId,
|
|
34
|
+
workflowId,
|
|
35
|
+
startedAt: Date.now(),
|
|
36
|
+
stepOutputs: {},
|
|
37
|
+
changedFiles: [],
|
|
38
|
+
errors: [],
|
|
39
|
+
data: {},
|
|
40
|
+
};
|
|
41
|
+
await this.saveContext(context);
|
|
42
|
+
console.log(`[AgentBus] Initialized for execution: ${this.executionId}`);
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* Publish message
|
|
46
|
+
*/
|
|
47
|
+
async publish(type, sender, payload, recipient) {
|
|
48
|
+
const message = {
|
|
49
|
+
id: `${Date.now()}-${Math.random().toString(36).slice(2, 8)}`,
|
|
50
|
+
timestamp: Date.now(),
|
|
51
|
+
type,
|
|
52
|
+
sender,
|
|
53
|
+
recipient,
|
|
54
|
+
executionId: this.executionId,
|
|
55
|
+
payload,
|
|
56
|
+
};
|
|
57
|
+
// Save message
|
|
58
|
+
const messagePath = resolve(this.messagesPath, `${message.id}.json`);
|
|
59
|
+
await fs.writeFile(messagePath, JSON.stringify(message, null, 2));
|
|
60
|
+
// Handle special message types
|
|
61
|
+
if (type === 'step_completed') {
|
|
62
|
+
await this.handleStepCompleted(payload);
|
|
63
|
+
}
|
|
64
|
+
else if (type === 'context_update') {
|
|
65
|
+
await this.handleContextUpdate(payload);
|
|
66
|
+
}
|
|
67
|
+
else if (type === 'file_changed') {
|
|
68
|
+
await this.handleFileChanged(payload);
|
|
69
|
+
}
|
|
70
|
+
else if (type === 'error') {
|
|
71
|
+
await this.handleError(sender, payload);
|
|
72
|
+
}
|
|
73
|
+
console.log(`[AgentBus] Published ${type} from ${sender}`);
|
|
74
|
+
return message.id;
|
|
75
|
+
}
|
|
76
|
+
/**
|
|
77
|
+
* Handle step completion
|
|
78
|
+
*/
|
|
79
|
+
async handleStepCompleted(payload) {
|
|
80
|
+
const context = await this.getContext();
|
|
81
|
+
if (!context)
|
|
82
|
+
return;
|
|
83
|
+
context.stepOutputs[payload.stepId] = payload.output;
|
|
84
|
+
if (payload.changedFiles) {
|
|
85
|
+
for (const file of payload.changedFiles) {
|
|
86
|
+
if (!context.changedFiles.includes(file)) {
|
|
87
|
+
context.changedFiles.push(file);
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
await this.saveContext(context);
|
|
92
|
+
}
|
|
93
|
+
/**
|
|
94
|
+
* Handle context update
|
|
95
|
+
*/
|
|
96
|
+
async handleContextUpdate(payload) {
|
|
97
|
+
const context = await this.getContext();
|
|
98
|
+
if (!context)
|
|
99
|
+
return;
|
|
100
|
+
switch (payload.operation) {
|
|
101
|
+
case 'set':
|
|
102
|
+
context.data[payload.key] = payload.value;
|
|
103
|
+
break;
|
|
104
|
+
case 'append':
|
|
105
|
+
if (!Array.isArray(context.data[payload.key])) {
|
|
106
|
+
context.data[payload.key] = [];
|
|
107
|
+
}
|
|
108
|
+
context.data[payload.key].push(payload.value);
|
|
109
|
+
break;
|
|
110
|
+
case 'delete':
|
|
111
|
+
delete context.data[payload.key];
|
|
112
|
+
break;
|
|
113
|
+
}
|
|
114
|
+
await this.saveContext(context);
|
|
115
|
+
}
|
|
116
|
+
/**
|
|
117
|
+
* Handle file change
|
|
118
|
+
*/
|
|
119
|
+
async handleFileChanged(payload) {
|
|
120
|
+
const context = await this.getContext();
|
|
121
|
+
if (!context)
|
|
122
|
+
return;
|
|
123
|
+
if (!context.changedFiles.includes(payload.path)) {
|
|
124
|
+
context.changedFiles.push(payload.path);
|
|
125
|
+
}
|
|
126
|
+
await this.saveContext(context);
|
|
127
|
+
}
|
|
128
|
+
/**
|
|
129
|
+
* Handle error
|
|
130
|
+
*/
|
|
131
|
+
async handleError(stepId, message) {
|
|
132
|
+
const context = await this.getContext();
|
|
133
|
+
if (!context)
|
|
134
|
+
return;
|
|
135
|
+
context.errors.push({
|
|
136
|
+
stepId,
|
|
137
|
+
message,
|
|
138
|
+
timestamp: Date.now(),
|
|
139
|
+
});
|
|
140
|
+
await this.saveContext(context);
|
|
141
|
+
}
|
|
142
|
+
/**
|
|
143
|
+
* Get context
|
|
144
|
+
*/
|
|
145
|
+
async getContext() {
|
|
146
|
+
try {
|
|
147
|
+
const content = await fs.readFile(this.contextPath, 'utf-8');
|
|
148
|
+
return JSON.parse(content);
|
|
149
|
+
}
|
|
150
|
+
catch {
|
|
151
|
+
return null;
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
/**
|
|
155
|
+
* Save context
|
|
156
|
+
*/
|
|
157
|
+
async saveContext(context) {
|
|
158
|
+
await fs.writeFile(this.contextPath, JSON.stringify(context, null, 2));
|
|
159
|
+
}
|
|
160
|
+
/**
|
|
161
|
+
* Get output from specific step
|
|
162
|
+
*/
|
|
163
|
+
async getStepOutput(stepId) {
|
|
164
|
+
const context = await this.getContext();
|
|
165
|
+
return context?.stepOutputs[stepId] ?? null;
|
|
166
|
+
}
|
|
167
|
+
/**
|
|
168
|
+
* Get all changed files
|
|
169
|
+
*/
|
|
170
|
+
async getChangedFiles() {
|
|
171
|
+
const context = await this.getContext();
|
|
172
|
+
return context?.changedFiles ?? [];
|
|
173
|
+
}
|
|
174
|
+
/**
|
|
175
|
+
* Get custom data
|
|
176
|
+
*/
|
|
177
|
+
async getData(key) {
|
|
178
|
+
const context = await this.getContext();
|
|
179
|
+
return context?.data[key] ?? null;
|
|
180
|
+
}
|
|
181
|
+
/**
|
|
182
|
+
* Set custom data
|
|
183
|
+
*/
|
|
184
|
+
async setData(key, value) {
|
|
185
|
+
await this.publish('context_update', 'system', {
|
|
186
|
+
key,
|
|
187
|
+
value,
|
|
188
|
+
operation: 'set',
|
|
189
|
+
});
|
|
190
|
+
}
|
|
191
|
+
/**
|
|
192
|
+
* Register message listener
|
|
193
|
+
*/
|
|
194
|
+
on(type, callback) {
|
|
195
|
+
if (!this.listeners.has(type)) {
|
|
196
|
+
this.listeners.set(type, []);
|
|
197
|
+
}
|
|
198
|
+
this.listeners.get(type).push(callback);
|
|
199
|
+
}
|
|
200
|
+
/**
|
|
201
|
+
* Start polling (detect new messages)
|
|
202
|
+
*/
|
|
203
|
+
startPolling(intervalMs = 1000) {
|
|
204
|
+
if (this.pollInterval)
|
|
205
|
+
return;
|
|
206
|
+
this.pollInterval = setInterval(async () => {
|
|
207
|
+
await this.checkNewMessages();
|
|
208
|
+
}, intervalMs);
|
|
209
|
+
}
|
|
210
|
+
/**
|
|
211
|
+
* Stop polling
|
|
212
|
+
*/
|
|
213
|
+
stopPolling() {
|
|
214
|
+
if (this.pollInterval) {
|
|
215
|
+
clearInterval(this.pollInterval);
|
|
216
|
+
this.pollInterval = null;
|
|
217
|
+
}
|
|
218
|
+
}
|
|
219
|
+
/**
|
|
220
|
+
* Check for new messages
|
|
221
|
+
*/
|
|
222
|
+
async checkNewMessages() {
|
|
223
|
+
try {
|
|
224
|
+
const files = await fs.readdir(this.messagesPath);
|
|
225
|
+
const newFiles = files
|
|
226
|
+
.filter(f => f.endsWith('.json') && f > this.lastMessageId)
|
|
227
|
+
.sort();
|
|
228
|
+
for (const file of newFiles) {
|
|
229
|
+
const content = await fs.readFile(resolve(this.messagesPath, file), 'utf-8');
|
|
230
|
+
const message = JSON.parse(content);
|
|
231
|
+
// Invoke listeners
|
|
232
|
+
const callbacks = this.listeners.get(message.type);
|
|
233
|
+
if (callbacks) {
|
|
234
|
+
for (const cb of callbacks) {
|
|
235
|
+
cb(message);
|
|
236
|
+
}
|
|
237
|
+
}
|
|
238
|
+
this.lastMessageId = file;
|
|
239
|
+
}
|
|
240
|
+
}
|
|
241
|
+
catch {
|
|
242
|
+
// Ignore
|
|
243
|
+
}
|
|
244
|
+
}
|
|
245
|
+
/**
|
|
246
|
+
* Get all messages
|
|
247
|
+
*/
|
|
248
|
+
async getAllMessages() {
|
|
249
|
+
try {
|
|
250
|
+
const files = await fs.readdir(this.messagesPath);
|
|
251
|
+
const messages = [];
|
|
252
|
+
for (const file of files.filter(f => f.endsWith('.json')).sort()) {
|
|
253
|
+
const content = await fs.readFile(resolve(this.messagesPath, file), 'utf-8');
|
|
254
|
+
messages.push(JSON.parse(content));
|
|
255
|
+
}
|
|
256
|
+
return messages;
|
|
257
|
+
}
|
|
258
|
+
catch {
|
|
259
|
+
return [];
|
|
260
|
+
}
|
|
261
|
+
}
|
|
262
|
+
/**
|
|
263
|
+
* Create step context (including previous step results)
|
|
264
|
+
*/
|
|
265
|
+
async createStepContext(stepId, dependsOn) {
|
|
266
|
+
const context = await this.getContext();
|
|
267
|
+
if (!context)
|
|
268
|
+
return '';
|
|
269
|
+
const parts = [
|
|
270
|
+
'## Workflow Context',
|
|
271
|
+
'',
|
|
272
|
+
`Execution ID: ${context.executionId}`,
|
|
273
|
+
`Started: ${new Date(context.startedAt).toISOString()}`,
|
|
274
|
+
'',
|
|
275
|
+
];
|
|
276
|
+
// Previous step results
|
|
277
|
+
if (dependsOn && dependsOn.length > 0) {
|
|
278
|
+
parts.push('### Previous Step Results');
|
|
279
|
+
for (const depId of dependsOn) {
|
|
280
|
+
const output = context.stepOutputs[depId];
|
|
281
|
+
if (output) {
|
|
282
|
+
parts.push(`\n#### ${depId}:`);
|
|
283
|
+
parts.push(output.slice(0, 2000)); // Truncate if too long
|
|
284
|
+
}
|
|
285
|
+
}
|
|
286
|
+
parts.push('');
|
|
287
|
+
}
|
|
288
|
+
// Changed files
|
|
289
|
+
if (context.changedFiles.length > 0) {
|
|
290
|
+
parts.push('### Changed Files So Far');
|
|
291
|
+
parts.push(context.changedFiles.map(f => `- ${f}`).join('\n'));
|
|
292
|
+
parts.push('');
|
|
293
|
+
}
|
|
294
|
+
// Error log
|
|
295
|
+
if (context.errors.length > 0) {
|
|
296
|
+
parts.push('### Previous Errors');
|
|
297
|
+
for (const err of context.errors) {
|
|
298
|
+
parts.push(`- [${err.stepId}] ${err.message}`);
|
|
299
|
+
}
|
|
300
|
+
parts.push('');
|
|
301
|
+
}
|
|
302
|
+
return parts.join('\n');
|
|
303
|
+
}
|
|
304
|
+
/**
|
|
305
|
+
* Clean up bus
|
|
306
|
+
*/
|
|
307
|
+
async cleanup() {
|
|
308
|
+
this.stopPolling();
|
|
309
|
+
// Clean up files if needed
|
|
310
|
+
}
|
|
311
|
+
}
|
|
312
|
+
// Helper Functions
|
|
313
|
+
/**
|
|
314
|
+
* Create new bus instance
|
|
315
|
+
*/
|
|
316
|
+
export function createBus(executionId) {
|
|
317
|
+
const id = executionId || `exec-${Date.now()}-${Math.random().toString(36).slice(2, 8)}`;
|
|
318
|
+
return new AgentBus(id);
|
|
319
|
+
}
|
|
320
|
+
/**
|
|
321
|
+
* Connect to existing bus
|
|
322
|
+
*/
|
|
323
|
+
export async function connectToBus(executionId) {
|
|
324
|
+
const contextPath = resolve(BUS_DIR, executionId, 'context.json');
|
|
325
|
+
if (!existsSync(contextPath)) {
|
|
326
|
+
return null;
|
|
327
|
+
}
|
|
328
|
+
return new AgentBus(executionId);
|
|
329
|
+
}
|
|
330
|
+
/**
|
|
331
|
+
* List active buses
|
|
332
|
+
*/
|
|
333
|
+
export async function listActiveBuses() {
|
|
334
|
+
try {
|
|
335
|
+
await fs.mkdir(BUS_DIR, { recursive: true });
|
|
336
|
+
const dirs = await fs.readdir(BUS_DIR);
|
|
337
|
+
const active = [];
|
|
338
|
+
for (const dir of dirs) {
|
|
339
|
+
const contextPath = resolve(BUS_DIR, dir, 'context.json');
|
|
340
|
+
if (existsSync(contextPath)) {
|
|
341
|
+
active.push(dir);
|
|
342
|
+
}
|
|
343
|
+
}
|
|
344
|
+
return active;
|
|
345
|
+
}
|
|
346
|
+
catch {
|
|
347
|
+
return [];
|
|
348
|
+
}
|
|
349
|
+
}
|
|
350
|
+
//# sourceMappingURL=agentBus.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agentBus.js","sourceRoot":"","sources":["../../src/agents/agentBus.ts"],"names":[],"mappings":"AAAA,+CAA+C;AAC/C,gCAAgC;AAChC,qCAAqC;AACrC,+CAA+C;AAE/C,OAAO,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AAC/B,OAAO,EAAE,OAAO,EAAE,MAAM,IAAI,CAAC;AAC7B,OAAO,KAAK,EAAE,MAAM,aAAa,CAAC;AAClC,OAAO,EAAE,UAAU,EAAE,MAAM,IAAI,CAAC;AAkFhC,kCAAkC;AAElC,MAAM,OAAO,GAAG,OAAO,CAAC,OAAO,EAAE,EAAE,gBAAgB,CAAC,CAAC;AAErD;;GAEG;AACH,MAAM,OAAO,QAAQ;IACX,WAAW,CAAS;IACpB,WAAW,CAAS;IACpB,YAAY,CAAS;IACrB,SAAS,GAAyD,IAAI,GAAG,EAAE,CAAC;IAC5E,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MAAM,CAAC,KAAK,UAAU,YAAY,CAAC,WAAmB;IACpD,MAAM,WAAW,GAAG,OAAO,CAAC,OAAO,EAAE,WAAW,EAAE,cAAc,CAAC,CAAC;IAClE,IAAI,CAAC,UAAU,CAAC,WAAW,CAAC,EAAE,CAAC;QAC7B,OAAO,IAAI,CAAC;IACd,CAAC;IACD,OAAO,IAAI,QAAQ,CAAC,WAAW,CAAC,CAAC;AACnC,CAAC;AAED;;GAEG;AACH,MAAM,CAAC,KAAK,UAAU,eAAe;IACnC,IAAI,CAAC;QACH,MAAM,EAAE,CAAC,KAAK,CAAC,OAAO,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC;QAC7C,MAAM,IAAI,GAAG,MAAM,EAAE,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;QACvC,MAAM,MAAM,GAAa,EAAE,CAAC;QAE5B,KAAK,MAAM,GAAG,IAAI,IAAI,EAAE,CAAC;YACvB,MAAM,WAAW,GAAG,OAAO,CAAC,OAAO,EAAE,GAAG,EAAE,cAAc,CAAC,CAAC;YAC1D,IAAI,UAAU,CAAC,WAAW,CAAC,EAAE,CAAC;gBAC5B,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;YACnB,CAAC;QACH,CAAC;QAED,OAAO,MAAM,CAAC;IAChB,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,EAAE,CAAC;IACZ,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,210 @@
|
|
|
1
|
+
import type { CostInfo } from '../support/costTracker.js';
|
|
2
|
+
/**
|
|
3
|
+
* Confidence level for execution results (legacy)
|
|
4
|
+
* 0 = failed, 1 = low, 2 = medium, 3 = high
|
|
5
|
+
*/
|
|
6
|
+
export type ConfidenceLevel = 0 | 1 | 2 | 3;
|
|
7
|
+
/**
|
|
8
|
+
* Confidence as a 0-100 percentage
|
|
9
|
+
*/
|
|
10
|
+
export type ConfidencePercent = number;
|
|
11
|
+
export declare const CONFIDENCE_THRESHOLDS: {
|
|
12
|
+
readonly PROCEED: 80;
|
|
13
|
+
readonly CAUTIOUS: 60;
|
|
14
|
+
readonly HALT: 60;
|
|
15
|
+
};
|
|
16
|
+
/**
|
|
17
|
+
* Worker execution result
|
|
18
|
+
*/
|
|
19
|
+
export interface WorkerResult {
|
|
20
|
+
success: boolean;
|
|
21
|
+
summary: string;
|
|
22
|
+
filesChanged: string[];
|
|
23
|
+
commands: string[];
|
|
24
|
+
output: string;
|
|
25
|
+
error?: string;
|
|
26
|
+
confidence?: ConfidenceLevel;
|
|
27
|
+
confidencePercent?: number;
|
|
28
|
+
haltReason?: string;
|
|
29
|
+
uncertaintySignals?: string[];
|
|
30
|
+
costInfo?: CostInfo;
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Confidence tracking for detecting degradation
|
|
34
|
+
*/
|
|
35
|
+
export interface ConfidenceTracker {
|
|
36
|
+
history: Array<{
|
|
37
|
+
attempt: number;
|
|
38
|
+
confidence: ConfidencePercent;
|
|
39
|
+
timestamp: number;
|
|
40
|
+
action: string;
|
|
41
|
+
haltTriggered?: boolean;
|
|
42
|
+
}>;
|
|
43
|
+
streakCount: number;
|
|
44
|
+
lastConfidence: ConfidencePercent;
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
* Reviewer decision
|
|
48
|
+
*/
|
|
49
|
+
export type ReviewDecision = 'approve' | 'revise' | 'reject';
|
|
50
|
+
/**
|
|
51
|
+
* Reviewer result
|
|
52
|
+
*/
|
|
53
|
+
export interface ReviewResult {
|
|
54
|
+
decision: ReviewDecision;
|
|
55
|
+
feedback: string;
|
|
56
|
+
issues?: string[];
|
|
57
|
+
suggestions?: string[];
|
|
58
|
+
costInfo?: CostInfo;
|
|
59
|
+
}
|
|
60
|
+
/**
|
|
61
|
+
* Pair message
|
|
62
|
+
*/
|
|
63
|
+
export interface PairMessage {
|
|
64
|
+
role: 'worker' | 'reviewer' | 'system';
|
|
65
|
+
content: string;
|
|
66
|
+
timestamp: number;
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* Pair session status
|
|
70
|
+
*/
|
|
71
|
+
export type PairSessionStatus = 'pending' | 'working' | 'reviewing' | 'revising' | 'approved' | 'rejected' | 'failed' | 'cancelled';
|
|
72
|
+
/**
|
|
73
|
+
* Pair session
|
|
74
|
+
*/
|
|
75
|
+
export interface PairSession {
|
|
76
|
+
id: string;
|
|
77
|
+
taskId: string;
|
|
78
|
+
taskTitle: string;
|
|
79
|
+
taskDescription: string;
|
|
80
|
+
projectPath: string;
|
|
81
|
+
threadId?: string;
|
|
82
|
+
webhookUrl?: string;
|
|
83
|
+
models?: PairModelConfig;
|
|
84
|
+
status: PairSessionStatus;
|
|
85
|
+
worker: {
|
|
86
|
+
result?: WorkerResult;
|
|
87
|
+
attempts: number;
|
|
88
|
+
maxAttempts: number;
|
|
89
|
+
freshContextAfter?: number;
|
|
90
|
+
failureStreak: number;
|
|
91
|
+
useFreshContext?: boolean;
|
|
92
|
+
};
|
|
93
|
+
reviewer: {
|
|
94
|
+
feedback?: ReviewResult;
|
|
95
|
+
};
|
|
96
|
+
messages: PairMessage[];
|
|
97
|
+
confidenceTracker?: ConfidenceTracker;
|
|
98
|
+
startedAt: number;
|
|
99
|
+
finishedAt?: number;
|
|
100
|
+
}
|
|
101
|
+
/**
|
|
102
|
+
* Model configuration
|
|
103
|
+
*/
|
|
104
|
+
export interface PairModelConfig {
|
|
105
|
+
worker?: string;
|
|
106
|
+
reviewer?: string;
|
|
107
|
+
}
|
|
108
|
+
/**
|
|
109
|
+
* Pair session creation options
|
|
110
|
+
*/
|
|
111
|
+
export interface CreatePairSessionOptions {
|
|
112
|
+
taskId: string;
|
|
113
|
+
taskTitle: string;
|
|
114
|
+
taskDescription: string;
|
|
115
|
+
projectPath: string;
|
|
116
|
+
maxAttempts?: number;
|
|
117
|
+
webhookUrl?: string;
|
|
118
|
+
models?: PairModelConfig;
|
|
119
|
+
}
|
|
120
|
+
/**
|
|
121
|
+
* Create a new pair session
|
|
122
|
+
*/
|
|
123
|
+
export declare function createPairSession(options: CreatePairSessionOptions): PairSession;
|
|
124
|
+
/**
|
|
125
|
+
* Get session by ID
|
|
126
|
+
*/
|
|
127
|
+
export declare function getPairSession(sessionId: string): PairSession | undefined;
|
|
128
|
+
/**
|
|
129
|
+
* List active sessions
|
|
130
|
+
*/
|
|
131
|
+
export declare function getActiveSessions(): PairSession[];
|
|
132
|
+
/**
|
|
133
|
+
* Update session status
|
|
134
|
+
*/
|
|
135
|
+
export declare function updateSessionStatus(sessionId: string, status: PairSessionStatus): PairSession | undefined;
|
|
136
|
+
/**
|
|
137
|
+
* Set Discord thread ID
|
|
138
|
+
*/
|
|
139
|
+
export declare function setSessionThreadId(sessionId: string, threadId: string): PairSession | undefined;
|
|
140
|
+
/**
|
|
141
|
+
* Save Worker result
|
|
142
|
+
*/
|
|
143
|
+
export declare function saveWorkerResult(sessionId: string, result: WorkerResult): PairSession | undefined;
|
|
144
|
+
/**
|
|
145
|
+
* Save Reviewer result
|
|
146
|
+
*/
|
|
147
|
+
export declare function saveReviewerResult(sessionId: string, result: ReviewResult): PairSession | undefined;
|
|
148
|
+
/**
|
|
149
|
+
* Add message
|
|
150
|
+
*/
|
|
151
|
+
export declare function addMessage(sessionId: string, role: PairMessage['role'], content: string): void;
|
|
152
|
+
/**
|
|
153
|
+
* Cancel session
|
|
154
|
+
*/
|
|
155
|
+
export declare function cancelSession(sessionId: string): boolean;
|
|
156
|
+
/**
|
|
157
|
+
* Check if Worker can retry
|
|
158
|
+
*/
|
|
159
|
+
export declare function canRetry(sessionId: string): boolean;
|
|
160
|
+
/**
|
|
161
|
+
* Get session history
|
|
162
|
+
*/
|
|
163
|
+
export declare function getSessionHistory(limit?: number): PairSession[];
|
|
164
|
+
/**
|
|
165
|
+
* Clear all sessions (for testing)
|
|
166
|
+
*/
|
|
167
|
+
export declare function clearAllSessions(): void;
|
|
168
|
+
/**
|
|
169
|
+
* Format session status summary
|
|
170
|
+
*/
|
|
171
|
+
export declare function formatSessionSummary(session: PairSession): string;
|
|
172
|
+
/**
|
|
173
|
+
* Format full discussion history
|
|
174
|
+
*/
|
|
175
|
+
export declare function formatDiscussion(session: PairSession): string;
|
|
176
|
+
/**
|
|
177
|
+
* Calculate confidence as a 0-100 percentage based on worker result
|
|
178
|
+
*/
|
|
179
|
+
export declare function calculateConfidence(result: WorkerResult): ConfidencePercent;
|
|
180
|
+
/**
|
|
181
|
+
* Update confidence tracker with new result
|
|
182
|
+
*/
|
|
183
|
+
export declare function updateConfidenceTracker(sessionId: string, result: WorkerResult, attempt: number): void;
|
|
184
|
+
/**
|
|
185
|
+
* Check if confidence has degraded significantly
|
|
186
|
+
* Returns true if intervention is needed
|
|
187
|
+
*/
|
|
188
|
+
export declare function needsConfidenceIntervention(sessionId: string): boolean;
|
|
189
|
+
/**
|
|
190
|
+
* Get confidence summary for reporting
|
|
191
|
+
*/
|
|
192
|
+
export declare function getConfidenceSummary(sessionId: string): string;
|
|
193
|
+
/**
|
|
194
|
+
* Track failure and decide if fresh context is needed
|
|
195
|
+
* Call this when worker/reviewer iteration fails
|
|
196
|
+
*/
|
|
197
|
+
export declare function trackFailure(sessionId: string): void;
|
|
198
|
+
/**
|
|
199
|
+
* Reset failure streak on success
|
|
200
|
+
*/
|
|
201
|
+
export declare function resetFailureStreak(sessionId: string): void;
|
|
202
|
+
/**
|
|
203
|
+
* Check if fresh context should be used
|
|
204
|
+
*/
|
|
205
|
+
export declare function shouldUseFreshContext(sessionId: string): boolean;
|
|
206
|
+
/**
|
|
207
|
+
* Mark that fresh context was consumed (reset flag)
|
|
208
|
+
*/
|
|
209
|
+
export declare function consumeFreshContext(sessionId: string): void;
|
|
210
|
+
//# sourceMappingURL=agentPair.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agentPair.d.ts","sourceRoot":"","sources":["../../src/agents/agentPair.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,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