Overview

Ruflo (formerly Claude Flow) is a multi-agent AI orchestration platform designed to extend Claude Code into a coordinated swarm system. Published on npm as ruflo (v3.7.0-alpha.21), it provides 300+ MCP tools, 49 CLI commands, 32 installable plugins, and 100+ specialized agent definitions that enable agents to self-organize, learn from outcomes, share vector-indexed memory, and collaborate across trust boundaries via federation.

Problem solved: Claude Code operates as a single-context assistant. Ruflo adds a coordination layer — swarm topologies (hierarchical, mesh, adaptive), persistent HNSW-indexed vector memory, self-learning (SONA neural patterns), background workers, and zero-trust agent federation — so multiple AI agents can collaborate on complex tasks rather than working in isolation.

Tech stack:

  • Runtime: TypeScript (ES2022, ES modules), Node.js >= 20
  • Core language: 1,542 TypeScript source files, 630K+ lines of TypeScript code
  • Native/WASM: 18 Rust source files compiled to WASM (policy engine, embeddings, GNN graph analysis, formula execution via gastown-bridge)
  • Web UI: SvelteKit 2 + Svelte 5 + MongoDB (the ruvocal chat interface at flo.ruv.io)
  • Build: TypeScript compiler (tsc), pnpm workspaces for V3 monorepo, tsup for plugin bundling
  • Testing: Vitest (280 test files), 1,933 tests in the CLI suite alone
  • Validation: Zod schemas for all MCP tool inputs, Ajv for tool registration validation
  • Transports: stdio, HTTP, WebSocket, in-process — for MCP server communication
  • CI/CD: GitHub Actions (9 workflow files), pnpm-based monorepo builds
  • Deployment: Docker + docker-compose, Google Cloud Run (cloudbuild.yaml)

Key Findings

Architecture

Ruflo follows a microkernel/plugin architecture (documented in ADR-004) with a layered design:

User → Claude Code / CLI → MCP Server (300+ tools) → SwarmCoordinator → Agents → Memory (AgentDB + HNSW)
                                                                              ↓
                                                                      LLM Providers (Claude, GPT, Gemini, Cohere, Ollama)

Key architectural components:

  • MCP Server (v3/mcp/server.ts, 792 lines) — JSON-RPC 2.0 server with connection pooling, session management (100 sessions, 30-min timeout), multi-transport support, and built-in metrics. Protocol version 2024.11.5.
  • Tool Registry (v3/mcp/tool-registry.ts, 602 lines) — O(1) Map-based lookup with category/tag indices, Ajv schema validation, batch registration, and per-tool performance tracking.
  • SwarmCoordinator (v3/src/coordination/application/SwarmCoordinator.ts, 459 lines) — Manages agent lifecycle, topology-aware connection management (hierarchical, mesh, adaptive), load-balanced task distribution, and memory-backed event sourcing.
  • Agent Domain Entity (v3/src/agent-lifecycle/domain/Agent.ts, 157 lines) — Clean domain model with status lifecycle (active/idle/busy/terminated), capability-based task routing, and task execution via callback pattern.
  • PluginManager (v3/src/infrastructure/plugins/PluginManager.ts, 276 lines) — Microkernel pattern with dependency resolution, version compatibility checks, extension point registration with priorities, and lifecycle management.
  • AgentDB Backend (v3/src/memory/infrastructure/AgentDBBackend.ts, 206 lines) — HNSW-indexed vector search with configurable M (default 16) and efConstruction (default 200), cosine similarity, and metadata filtering.

The project maintains 158 ADRs (Architecture Decision Records) in v3/implementation/adrs/ and v3/docs/adr/, documenting every significant design choice from the plugin system to encryption-at-rest (ADR-096) and federation budget circuit breakers (ADR-097).

Implementation Quality

Strengths:

  • Well-typed interfaces: All public APIs use TypeScript interfaces defined in v3/src/shared/types/index.ts. MCP tool inputs validated with Zod schemas (e.g., agent-tools.ts uses z.enum() for allowed agent types to prevent arbitrary execution).
  • Security-conscious design: Input validation at system boundaries, parameterized queries, path traversal prevention (PathValidator), command injection protection (SafeExecutor), environment variable sanitization (blocks LD_PRELOAD, NODE_OPTIONS, DYLD_*), file mode 0600 enforcement, stdin DoS cap (10MB), and AES-256-GCM encryption at rest for session/memory stores.
  • Secure ID generation: Agent IDs use crypto.randomBytes(12) rather than predictable counters.
  • Comprehensive tooling: Agent type allowlist with 50+ known types, preventing arbitrary agent type injection.
  • Performance targets documented and tracked: Server startup <400ms, tool registration <10ms, tool execution <50ms overhead, HNSW search 150x-12,500x faster than brute force.

Concerns:

  • AgentDB backend is in-memory: The current AgentDBBackend implementation uses Map<string, Memory> — the HNSW integration is stubbed. The comment says “For now, using in-memory storage for test compatibility.” The production HNSW path depends on the agentdb optional dependency.
  • Agent task execution is a placeholder: Agent.executeTask() calls processTaskExecution() which just does setTimeout with 1-10ms delays. Real work is done via task.onExecute() callback, meaning the agent entity itself is mostly a coordination record, not an executor.
  • Large surface area: 300+ MCP tools, 49 CLI commands, 32 plugins, 100+ agent definitions. The breadth is enormous for what appears to be primarily a single-developer project (ruvnet). Maintaining quality across this surface is challenging.
  • Alpha version: 3.7.0-alpha.21 — still in alpha. Many ADRs describe deferred phases.

Test Coverage and CI

  • 280 test files across the codebase, with the CLI package alone having 1,933 tests (0 failures, 46 intentionally skipped).
  • CI pipelines: 9 GitHub Actions workflows covering security audits, linting, type checking, integration tests, marketplace validation, verification pipeline, and V3-specific builds.
  • CI tolerates SIGSEGV: The V3 CI explicitly tolerates exit code 139 (segfault) from native bindings (onnxruntime-node, ruvector) during cleanup — a pragmatic but concerning workaround.
  • Tests are non-blocking in CI: The main CI pipeline uses continue-on-error: true for security audits and type checking, and tolerates test failures. This means CI is more of a status check than a gate.
  • Federation plugin tests: 366 tests specifically for the agent federation plugin, indicating serious investment in the federation feature.

Plugin Ecosystem

The 32 plugins in plugins/ruflo-* range from core infrastructure to domain-specific:

CategoryExamples
Coreruflo-core, ruflo-swarm, ruflo-autopilot, ruflo-workflows
Memoryruflo-agentdb, ruflo-rag-memory, ruflo-ruvector, ruflo-rvf
Intelligenceruflo-intelligence, ruflo-daa, ruflo-ruvllm, ruflo-goals
Securityruflo-security-audit, ruflo-aidefence
DevOpsruflo-observability, ruflo-cost-tracker, ruflo-migrations
Domainruflo-iot-cognitum, ruflo-neural-trader, ruflo-market-data

The V3 plugins/ directory contains advanced research-oriented plugins (code-intelligence, cognitive-kernel, hyperbolic-reasoning, prime-radiant, quantum-optimizer, etc.) that appear to be experimental/academic in nature, using GNN bridges, spectral analysis, and category theory engines.

Web UI (Ruvocal)

The ruflo/src/ruvocal/ directory contains a full SvelteKit 2 chat application (based on HuggingFace’s chat-ui architecture) that provides:

  • Multi-model chat (Qwen, Claude, Gemini, OpenAI via OpenRouter)
  • Parallel MCP tool execution with visual step indicators
  • In-browser WASM tool gallery (18 tools running client-side)
  • MongoDB-backed persistence with in-memory fallback
  • Docker deployment with embedded MongoDB
  • Hosted at flo.ruv.io

Federation System

The agent federation (v3/mcp/tools/federation-tools.ts) provides:

  • Ephemeral agent spawning with TTL
  • Swarm registration and broadcast messaging
  • Consensus proposals and voting
  • Budget circuit breakers (ADR-097) with maxHops: 8 default to prevent recursive delegation loops
  • Zero-trust model: mTLS + ed25519 challenge-response, PII stripping pipeline, behavioral trust scoring

Assessment

Strengths

  • Ambitious and comprehensive vision: Ruflo attempts to solve real problems in multi-agent AI orchestration — coordination, memory persistence, cross-machine collaboration, and security. The architecture is well-thought-out with clean domain boundaries.
  • Security-first approach: Zod validation on all MCP inputs, allowlisted agent types, secure ID generation, encryption at rest, command injection prevention, path traversal protection, and a formal security policy with 48-hour response SLA.
  • Excellent documentation: 158 ADRs, detailed README, STATUS.md, USERGUIDE.md, verification docs, and per-module CLAUDE.md files. The documentation culture is exceptional.
  • Plugin architecture: The microkernel pattern with dependency resolution, version compatibility, and extension points is well-designed and allows the system to grow without coupling.
  • Web UI shipping: A functional multi-model chat UI with MCP tool calling is a significant differentiator from other agent frameworks.

Concerns

  • Placeholder implementations: Key components like AgentDB vector search and Agent task execution contain stubs. The HNSW backend is in-memory only, and agents don’t actually execute code — they’re coordination records. The real execution is delegated to Claude Code / the host environment.
  • Breadth vs. depth: 300+ tools, 100+ agent types, 32 plugins, 14 V3 research plugins — the surface area is enormous. Some plugins (quantum-optimizer, hyperbolic-reasoning, prime-radiant) appear experimental with unclear practical utility.
  • Alpha stability: The 3.7.0-alpha.21 version and CI’s tolerance for test failures and segfaults suggest this is not production-ready. The npm package name is claude-flow despite the rebrand to Ruflo, indicating incomplete migration.
  • Single-developer risk: The project appears to be primarily authored by ruvnet (with AI assistance). The AGENTS.md file is essentially instructions for AI coding agents on how to use the system, suggesting heavy reliance on AI-generated code.
  • Complexity: The learning curve is steep. The README itself says “You don’t need to learn 314 MCP tools or 26 CLI commands” — which is both honest and revealing about the complexity.

Recommendations

  • Focus on core stability: Before shipping new plugins, stabilize the core AgentDB, swarm coordination, and MCP server implementations. Replace stubs with real implementations.
  • Reduce CI tolerance: Stop using continue-on-error: true for security audits and type checking. Make CI a proper gate.
  • Consolidate the plugin surface: Evaluate which of the 32+ plugins are actively used versus aspirational. Archive or remove low-value plugins.
  • Resolve the naming inconsistency: The npm package is claude-flow, the CLI binary is claude-flow, but the brand is Ruflo. Complete the rename or revert it.
  • Add integration tests for critical paths: The federation tools, memory persistence, and swarm coordination need end-to-end tests that exercise real behavior, not just in-memory stubs.
  • analyzing-bifrost — Both are multi-agent orchestration systems; Ruflo focuses on Claude Code integration while Bifrost takes a different approach to agent communication
  • analyzing-litellm — Ruflo’s multi-provider LLM routing (Claude, GPT, Gemini, Ollama) addresses similar problems to LiteLLM’s unified LLM API

Source: ruvnet/ruflo at commit c08ac225170f8c45a49ab8a69ea668be94e37960