Skip to main content
skill CX Codex

V3 Deep Integration — Claude Code skill: claude-flow on agentic-flow

This skill turns claude-flow into a specialized extension of agentic-flow@alpha per ADR-001. It drops duplicate modules and wires in SONA, Flash Attention and AgentDB.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add ruvnet/ruflo --skill v3-deep-integration -a claude-code
npx skills add ruvnet/ruflo --skill v3-integration-deep -a claude-code
Open on GitHub

What V3 Deep Integration does

The skill lays out the migration of claude-flow onto agentic-flow@alpha. Instead of keeping its own swarm coordination, agent management and task scheduler, the project becomes a layer on top of the existing agentic-flow systems. Overlap across the four modules runs from 50% to 80%, so those implementations get deleted.

Work happens in three phases. First an adapter, ClaudeFlowAgent, extends AgenticFlowAgent and keeps the old API alive through a compatibility layer. Then SwarmCoordinator, AgentManager and TaskScheduler are replaced by the swarm, lifecycle and task graph from agentic-flow. Finally the files src/core/SwarmCoordinator.ts, src/agents/AgentManager.ts and src/task/TaskScheduler.ts are removed. The target is under 5,000 lines against 15,000+ today.

You drive it with Task(...) calls against the v3-integration-architect subagent, and several can run in parallel. It brings in 5 SONA learning modes, Flash Attention at 2.49x-7.47x speedup, AgentDB with HNSW indexing at 150x-12,500x, plus 213 built-in MCP tools and 19 hook types. Migration is gradual: old and new systems run side by side until feature parity is confirmed. Without agentic-flow@alpha in the project the adapter layer has nothing to extend.

What it helps with

  • remove duplication between claude-flow and agentic-flow
  • move swarm coordination onto the existing implementation
  • wire up 5 SONA learning modes
  • replace linear search with AgentDB HNSW indexing
  • keep the old API working during migration

Example prompts for the agent

  • Design the agentic-flow@alpha adapter layer with the v3-integration-architect subagent
  • Integrate the 5 SONA modes and Flash Attention in parallel
  • Set up AgentDB with HNSW indexing for cross-agent memory

How to install V3 Deep Integration

1Skills CLI (Vercel)

npx skills add ruvnet/ruflo --skill v3-deep-integration -a claude-code
npx skills add ruvnet/ruflo --skill v3-integration-deep -a claude-code

2Manually: put the files in place

~/.claude/skills/v3-integration-deep/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/v3-integration-deep/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about V3 Deep Integration

How do I install V3 Deep Integration in Claude Code?

Run npx skills add ruvnet/ruflo --skill v3-deep-integration -a claude-code, then npx skills add ruvnet/ruflo --skill v3-integration-deep -a claude-code. The skill file lands at ~/.claude/skills/v3-integration-deep/SKILL.md.

What does V3 Deep Integration do?

It moves claude-flow from a parallel implementation to a specialized extension of agentic-flow@alpha. Duplicate modules go away, and SONA, Flash Attention, AgentDB, MCP tools and hooks come in.

Do I need agentic-flow@alpha for this skill?

Yes. The ClaudeFlowAgent adapter extends AgenticFlowAgent from that package. Without it the migration to the existing swarm, lifecycle and task graph cannot start.

Source text

SKILL.md · MIT
---
name: "V3 Deep Integration"
description: "Deep agentic-flow@alpha integration implementing ADR-001. Eliminates 10,000+ duplicate lines by building claude-flow as specialized extension rather than parallel implementation."
---

# V3 Deep Integration

## What This Skill Does

Transforms claude-flow from parallel implementation to specialized extension of agentic-flow@alpha, eliminating massive code duplication while achieving performance improvements and feature parity.

## Quick Start

```bash
# Initialize deep integration
Task("Integration architecture", "Design agentic-flow@alpha adapter layer", "v3-integration-architect")

# Feature integration (parallel)
Task("SONA integration", "Integrate 5 SONA learning modes", "v3-integration-architect")
Task("Flash Attention", "Implement 2.49x-7.47x speedup", "v3-integration-architect")
Task("AgentDB coordination", "Setup 150x-12,500x search", "v3-integration-architect")
```

## Code Deduplication Strategy

### Current Overlap → Integration
```
┌─────────────────────────────────────────┐
│  claude-flow          agentic-flow      │
├─────────────────────────────────────────┤
│ SwarmCoordinator  →   Swarm System      │ 80% overlap (eliminate)
│ AgentManager      →   Agent Lifecycle   │ 70% overlap (eliminate)
│ TaskScheduler     →   Task Execution    │ 60% overlap (eliminate)
│ SessionManager    →   Session Mgmt      │ 50% overlap (eliminate)
└─────────────────────────────────────────┘

TARGET: <5,000 lines (vs 15,000+ currently)
```

## agentic-flow@alpha Feature Integration

### SONA Learning Modes
```typescript
class SONAIntegration {
  async initializeMode(mode: SONAMode): Promise<void> {
    switch(mode) {
      case 'real-time':   // ~0.05ms adaptation
      case 'balanced':    // general purpose
      case 'research':    // deep exploration
      case 'edge':        // resource-constrained
      case 'batch':       // high-throughput
    }
    await this.agenticFlow.sona.setMode(mode);
  }
}
```

### Flash Attention Integration
```typescript
class FlashAttentionIntegration {
  async optimizeAttention(): Promise<AttentionResult> {
    return this.agenticFlow.attention.flashAttention({
      speedupTarget: '2.49x-7.47x',
      memoryReduction: '50-75%',
      mechanisms: ['multi-head', 'linear', 'local', 'global']
    });
  }
}
```

### AgentDB Coordination
```typescript
class AgentDBIntegration {
  async setupCrossAgentMemory(): Promise<void> {
    await this.agentdb.enableCrossAgentSharing({
      indexType: 'HNSW',
      speedupTarget: '150x-12500x',
      dimensions: 1536
    });
  }
}
```

### MCP Tools Integration
```typescript
class MCPToolsIntegration {
  async integrateBuiltinTools(): Promise<void> {
    // Leverage 213 pre-built tools
    const tools = await this.agenticFlow.mcp.getAvailableTools();
    await this.registerClaudeFlowSpecificTools(tools);

    // Use 19 hook types
    const hookTypes = await this.agenticFlow.hooks.getTypes();
    await this.configureClaudeFlowHooks(hookTypes);
  }
}
```

## Migration Implementation

### Phase 1: Adapter Layer
```typescript
import { Agent as AgenticFlowAgent } from 'agentic-flow@alpha';

export class ClaudeFlowAgent extends AgenticFlowAgent {
  async handleClaudeFlowTask(task: ClaudeTask): Promise<TaskResult> {
    return this.executeWithSONA(task);
  }

  // Backward compatibility
  async legacyCompatibilityLayer(oldAPI: any): Promise<any> {
    return this.adaptToNewAPI(oldAPI);
  }
}
```

### Phase 2: System Migration
```typescript
class SystemMigration {
  async migrateSwarmCoordination(): Promise<void> {
    // Replace SwarmCoordinator (800+ lines) with agentic-flow Swarm
    const swarmConfig = await this.extractSwarmConfig();
    await this.agenticFlow.swarm.initialize(swarmConfig);
  }

  async migrateAgentManagement(): Promise<void> {
    // Replace AgentManager (1,736+ lines) with agentic-flow lifecycle
    const agents = await this.extractActiveAgents();
    for (const agent of agents) {
      await this.agenticFlow.agent.create(agent);
    }
  }

  async migrateTaskExecution(): Promise<void> {
    // Replace TaskScheduler with agentic-flow task graph
    const tasks = await this.extractTasks();
    await this.agenticFlow.task.executeGraph(this.buildTaskGraph(tasks));
  }
}
```

### Phase 3: Cleanup
```typescript
class CodeCleanup {
  async removeDeprecatedCode(): Promise<void> {
    // Remove massive duplicate implementations
    await this.removeFile('src/core/SwarmCoordinator.ts');    // 800+ lines
    await this.removeFile('src/agents/AgentManager.ts');      // 1,736+ lines
    await this.removeFile('src/task/TaskScheduler.ts');       // 500+ lines

    // Total reduction: 10,000+ → <5,000 lines
  }
}
```

## RL Algorithm Integration

```typescript
class RLIntegration {
  algorithms = [
    'PPO', 'DQN', 'A2C', 'MCTS', 'Q-Learning',
    'SARSA', 'Actor-Critic', 'Decision-Transformer'
  ];

  async optimizeAgentBehavior(): Promise<void> {
    for (const algorithm of this.algorithms) {
      await this.agenticFlow.rl.train(algorithm, {
        episodes: 1000,
        rewardFunction: this.claudeFlowRewardFunction
      });
    }
  }
}
```

## Performance Integration

### Flash Attention Targets
```typescript
const attentionBenchmark = {
  baseline: 'current attention mechanism',
  target: '2.49x-7.47x improvement',
  memoryReduction: '50-75%',
  implementation: 'agentic-flow@alpha Flash Attention'
};
```

### AgentDB Search Performance
```typescript
const searchBenchmark = {
  baseline: 'linear search in current systems',
  target: '150x-12,500x via HNSW indexing',
  implementation: 'agentic-flow@alpha AgentDB'
};
```

## Backward Compatibility

### Gradual Migration
```typescript
class BackwardCompatibility {
  // Phase 1: Dual operation
  async enableDualOperation(): Promise<void> {
    this.oldSystem.continue();
    this.newSystem.initialize();
    this.syncState(this.oldSystem, this.newSystem);
  }

  // Phase 2: Feature-by-feature migration
  async migrateGradually(): Promise<void> {
    const features = this.getAllFeatures();
    for (const feature of features) {
      await this.migrateFeature(feature);
      await this.validateFeatureParity(feature);
    }
  }

  // Phase 3: Complete transition
  async completeTransition(): Promise<void> {
    await this.validateFullParity();
    await this.deprecateOldSystem();
  }
}
```

## Success Metrics

- **Code Reduction**: <5,000 lines orchestration (vs 15,000+)
- **Performance**: 2.49x-7.47x Flash Attention speedup
- **Search**: 150x-12,500x AgentDB improvement
- **Memory**: 50-75% usage reduction
- **Feature Parity**: 100% v2 functionality maintained
- **SONA**: <0.05ms adaptation time
- **Integration**: All 213 MCP tools + 19 hook types available

## Related V3 Skills

- `v3-memory-unification` - Memory system integration
- `v3-performance-optimization` - Performance target validation
- `v3-swarm-coordination` - Swarm system migration
- `v3-security-overhaul` - Secure integration patterns

© ruvnet · MIT · ruvnet/ruflo

Similar skills

All skills for Agent setup: memory, context, orchestration →

From the same set146

github-release-management Automates GitHub releases: drafts, changelogs, builds, multi-target deploys. Handy when releases ship often and manual steps eat the afternoon. CX Codex +1 1,200installs sparc-methodology Structures development into SPARC phases with Claude Flow multi-agent orchestration. Useful for running projects from specification and architecture down to TDD tests and review. CX Codex +1 1,200installs Pair Programming This skill runs AI-assisted pair programming with driver and navigator roles, code checks, testing, and dedicated TDD, debugging, and mentor modes. CX Codex +1 1,200installs github-multi-repo A skill for coordinating several repositories at once: it aligns package versions, checks cross-package integration and suggests structure changes. CX Codex +1 1,200installs AgentDB Learning Plugins Generates and trains reinforcement learning plugins for autonomous agents across 9 algorithms using AgentDB. CX Codex +1 1,100installs AgentDB Advanced Features Skill for distributed AgentDB systems: QUIC-synchronized nodes, multi-database management, custom distance metrics, and hybrid vector-plus-metadata search across AI agent networks. CX Codex +1 1,100installs AgentDB Performance Optimization Skill for vector database optimization in AgentDB: reduce memory 4–32x via quantization, speed up search 150x via HNSW indexing, add caching and batch inserts. CX Codex +1 1,100installs ReasoningBank with AgentDB Adds adaptive memory to coding agents using the AgentDB vector engine. Useful for recording agent execution paths, judging outcomes, and distilling recurring patterns. CX Codex +1 1,100installs

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor