🌊 The original agent harness. Deploy intelligent multi-player swarms, coordinate autonomous workflows, and build conversational AI systems. Features adaptive memory, self-learning intelligence, federation, vector RAG integration, and native Claude Code / Codex / Hermes and many more Integrated
TypeScript agentic-aiagentic-frameworkagentic-workflowagentsai-agentsai-assistantai-skillsautonomous-agentsclaudecodexdsh-pluginharnessmcp-servermulti-agentmulti-agent-systemsnpmskillsswarmswarm-intelligencetypescript
🔖 Checkpoint: Edit /workspaces/claude-code-flow/src/cli/simple-commands/automation-executor.js
rUva62677b212f6
diff --git a/.claude/checkpoints/1754345143.json b/.claude/checkpoints/1754345143.jsonnew file mode 100644index 0000000000..ee7fd14151--- /dev/null+++ b/.claude/checkpoints/1754345143.json@@ -0,0 +1 @@+{"branch": "checkpoint/pre-edit-20250804-220543", "file": "/workspaces/claude-code-flow/src/cli/simple-commands/automation-executor.js", "timestamp": "2025-08-04T22:05:43Z", "type": "pre-edit", "original_branch": "alpha-85"}diff --git a/.claude/checkpoints/1754345144.json b/.claude/checkpoints/1754345144.jsonnew file mode 100644index 0000000000..209528dd89--- /dev/null+++ b/.claude/checkpoints/1754345144.json@@ -0,0 +1 @@+{"tag": "checkpoint-20250804-220544", "file": "/workspaces/claude-code-flow/src/cli/simple-commands/automation-executor.js", "timestamp": "2025-08-04T22:05:44Z", "type": "post-edit", "branch": "alpha-85", "diff_summary": " .claude-flow/metrics/performance.json | 2 +- .claude-flow/metrics/system-metrics.json | 48 ++++++++++++++++++++++++++ .claude-flow/metrics/task-metrics.json | 6 ++-- .claude/checkpoints/1754345133.json | 1 + .claude/checkpoints/1754345135.json | 1 + claude-flow-wiki | 0 src/cli/simple-commands/automation-executor.js | 3 ++ 7 files changed, 57 insertions(+), 4 deletions(-) "}diff --git a/src/cli/simple-commands/automation-executor.js b/src/cli/simple-commands/automation-executor.jsindex 82be8c1844..a929f2c6a7 100644--- a/src/cli/simple-commands/automation-executor.js+++ b/src/cli/simple-commands/automation-executor.js@@ -944,6 +944,67 @@ COORDINATION KEY POINTS:return result;} else {// When Claude integration is enabled, delegate to actual Claude instance++ // Check if we have a master coordinator (interactive mode)+ const masterCoordinator = this.claudeInstances.get('master-coordinator');+ if (masterCoordinator && !this.options.nonInteractive) {+ // Interactive mode: All tasks are coordinated by the master coordinator+ console.log(` 🎯 Task delegated to Master Coordinator: ${task.description}`);++ // In interactive mode, the master coordinator handles all tasks+ // We just wait for the master coordinator process to complete+ const completionPromise = new Promise((resolve, reject) => {+ masterCoordinator.process.on('exit', (code) => {+ if (code === 0) {+ resolve({ success: true, code });+ } else {+ reject(new Error(`Master coordinator exited with code ${code}`));+ }+ });++ masterCoordinator.process.on('error', (err) => {+ reject(err);+ });+ });++ // For interactive mode, we use a longer timeout since user interaction is involved+ const timeout = Math.max(this.options.timeout, 1800000); // 30 minutes minimum for interactive+ const timeoutPromise = new Promise((_, reject) => {+ setTimeout(() => reject(new Error('Interactive session timeout')), timeout);+ });++ try {+ await Promise.race([completionPromise, timeoutPromise]);++ const result = {+ success: true,+ taskId: task.id,+ duration: Date.now() - startTime,+ output: {+ status: 'completed',+ agent: 'master-coordinator',+ executionTime: Date.now() - startTime,+ metadata: {+ timestamp: new Date().toISOString(),+ executionId: this.executionId,+ mode: 'interactive-coordination'+ }+ }+ };++ // Store result in memory+ if (this.hooksEnabled) {+ await this.storeTaskResult(task.id, result.output);+ }++ return result;++ } catch (error) {+ throw new Error(`Task execution failed: ${error.message}`);+ }+ }++ // Non-interactive mode or no master coordinator: use individual Claude instancesconst claudeInstance = this.claudeInstances.get(task.assignTo);if (!claudeInstance) {// If no pre-spawned instance, create one for this task