AI Card Bao API.AICARDBAO.COM
Home / 开源 / Ruflo
AI TOOL / #12881

Ruflo

The initial version of the agent harness enables the deployment of multi-person collaborative swarms, coordinates autonomous workflows, and facilitates the development of conversational AI systems featuring adaptive memory mechanisms, self-learning capabilities, as well as federal and vector RAG technologies.

Introduction

面向 Claude Code 与 Codex 的智能体元基座(meta-harness)。

一条命令快速开始

在你的项目文件夹中运行:

npx ruflo@latest init

然后在同一文件夹打开 Claude Code 并给它一个真实的任务,例如:

用 ruflo 蜂群来审查这个代码库:找出风险最高的模块,为它写测试,总结你改了什么。

init 会为项目添加 ruflo 的智能体、钩子、记忆和 MCP 服务器。Claude Code 在下次启动时会自动识别它们。Codex 和其他 MCP 客户端也支持:只需指向 npx -y ruflo@latest mcp start。

第一个实用任务,逐步讲解 · 用户指南 · 比较安装路径

其他安装方式(仅 Claude Code 插件、MCP 客户端、终端 UI)

仅 Claude Code 插件。 这种方式安装核心工具、可视控制台和运行时 mod,无需向项目添加文件。需要 Claude Code 2.1.287 或更高版本。在 Claude Code 中运行:

/plugin marketplace add ruvnet/ruflo
/plugin install ruflo-core@ruflo
/plugin install ruflo-console@ruflo
/plugin install ruflo-mods@ruflo
/reload-plugins
/ruflo

从终端运行(Claude Code 2.1.292 或更高版本):claude plugin install ruflo-core@ruflo --marketplace ruvnet/ruflo。Mod 运行在你的账户权限下,安装前请审查代码。

Codex 或其他 MCP 客户端,无需项目配置。 配置 命令 为 npx,参数 为 ["-y", "ruflo@latest", "mcp", "start"]。要进行交互式项目配置,运行 npx ruflo@latest init wizard。

纯终端。 控制台也可独立运行,无需 Claude Code:npx ruflo tui。加上 --plain 为脚本打印单一画面。详见终端 UI 指南。

可选:ruOS Desktop

通过 MCP 将 ruOS 连接到 ChatGPT 或 Claude:

https://ruos.cognitum.one/mcp
npx ruvector

English · 简体中文

📖 RuFlo 详解——组建一支会规划、会记忆、会测试、会自我改进的 AI 团队 一份 14 章的指南:从基本理念到第一个实用任务,再到记忆、智能体团队、插件、成本与验证。

智能体 = 模型 + 基座(Harness)。 模型负责写作;基座为它提供工具、记忆、循环、沙箱与控制能力,让模型真正能干成事。Ruflo 就是那个基座——围绕 Claude Code 与 Codex 的执行层,它带来 100+ 专用智能体、协同蜂群、自学习记忆、跨机器联邦通信以及企业级安全护栏。智能体不再只是"跑起来",而是彼此协作。

一行 npx ruflo init 就能为 Claude Code 装上神经系统:智能体自行组织成蜂群,从每项任务中学习,跨会话保持记忆,并且——借助联邦能力——能在不泄露数据的前提下与其他机器上的智能体安全通信。你只管继续写代码,协调工作交给 Ruflo。

Self-Learning / Self-Optimizing Agent Architecture

User --> Ruflo (CLI/MCP) --> Router --> Swarm --> Agents --> Memory --> LLM Providers
                          ^                           |
                          +---- Learning Loop  **第一次用 Ruflo?** 你不需要先学会 406 个 MCP 工具或 61 条 CLI 命令。执行完 `init` 之后,像平常一样使用 Claude Code 即可——钩子系统会自动路由任务、从成功模式中学习,并在后台协调智能体。

📖 背景——名字的由来

> Claude Flow 现已更名为 Ruflo——名字来自 [`rUv`](https://ruv.io),他热爱 Rust、心流状态,以及构建那些让人觉得"本该如此"的东西。"Ru" 来自 rUv,"flo" 是工作到凌晨三点的心流。底层由 [`Cognitum.One`](https://cognitum.one/?RuFlo) 的智能体架构驱动,运行着超强性能的 Rust AI 引擎、嵌入向量、记忆与插件系统。

---

![Ruflo Plugins](./ruflo-plugins.gif)

## 快速开始

有**两条完全不同的安装路径**,覆盖范围差异很大。请根据你的需要选择(#1744):

| | **Claude Code 插件** | **CLI 安装(`npx ruflo init`)** |
|---|---|---|
| 提供什么 | 斜杠命令 + 少量技能 + 每个插件各自的智能体定义 | 完整的 Ruflo 循环——98 个智能体、60+ 条命令、30 项技能、MCP 服务器、钩子、守护进程 |
| 工作区中的文件 | **零** | `.claude/`、`.claude-flow/`、`CLAUDE.md`、辅助文件、设置 |
| 是否注册 MCP 服务器 | 仅在安装了 `ruflo-core` 时(它自带 `.mcp.json`)——其他插件大多不会 | 是 |
| 是否安装钩子 | 否 | 是 |
| 适合场景 | 不全面安装,先试用单个插件的命令 | 生产环境使用——一切如文档所述般工作 |

### 路径 A——Claude Code 插件(轻量版,仅斜杠命令)

/plugin marketplace add ruvnet/ruflo

/plugin install ruflo-core@ruflo /plugin install ruflo-swarm@ruflo /plugin install ruflo-rag-memory@ruflo /plugin install ruflo-neural-trader@ruflo


这会添加斜杠命令与智能体定义。上面安装的 `ruflo-core` 确实会在安装时注册它自己的 MCP 服务器——其工具以 `mcp__plugin_ruflo-core_ruflo__*` 形式调用(例如 `mcp__plugin_ruflo-core_ruflo__memory_store`),而不是 CLI 路线脚手架中使用的裸名 `memory_store`/`swarm_init`/`agent_spawn`。其他插件通常不自带 MCP 服务器。想要带 CLI 路线工具名的完整循环,请使用下方的路径 B。

🔌 全部 48 个插件

#### 核心与编排

| 插件 | 功能说明 |
|--------|-------------|
| [**ruflo-core**](plugins/ruflo-core/README.md) | 基础层——服务器、健康检查、插件发现 |
| [**ruflo-swarm**](plugins/ruflo-swarm/README.md) | 将多个智能体作为团队进行协调 |
| [**ruflo-autopilot**](plugins/ruflo-autopilot/README.md) | 让智能体在循环中自主运行 |
| [**ruflo-loop-workers**](plugins/ruflo-loop-workers/README.md) | 按定时器调度后台任务 |
| [**ruflo-workflows**](plugins/ruflo-workflows/README.md) | 可复用的多步骤任务模板 |
| [**ruflo-federation**](plugins/ruflo-federation/README.md) | 让不同机器上的智能体安全协作 |
| [**ruflo-console**](plugins/ruflo-console/README.md) | Claude Code 内的驾驶舱,以及所有 ruflo mod 的 `/ruflo` 命令 |
| [**ruflo-mods**](plugins/ruflo-mods/README.md) | 进程内 Claude Code mod——路由、学习信号与策略检查 |
| [**ruflo-ai-team**](plugins/ruflo-ai-team/README.md) | 租户隔离的团队,分工协作并返回带证据的结果 |
| [**ruflo-agntcy**](plugins/ruflo-agntcy/README.md) | AGNTCY/Outshift 传输与按意图限定的工具授权 |
| [**ruflo-bbs-federation**](plugins/ruflo-bbs-federation/README.md) | AgentBBS 房间,让不同主机上的智能体协调 |
| [**ruflo-chatgpt-federation**](plugins/ruflo-chatgpt-federation/README.md) | 自带签名密钥的 ChatGPT 联邦发布器 |
| [**ruflo-x-gateway**](plugins/ruflo-x-gateway/README.md) | 签名的联邦消息、频道与工作认领 |
| [**ruflo-business-pods**](plugins/ruflo-business-pods/README.md) | 业务领域 pod 模板,以及默认演练的单步运行器 |

#### 记忆与知识

| 插件 | 功能说明 |
|--------|-------------|
| [**ruflo-agentdb**](plugins/ruflo-agentdb/README.md) | 面向智能体记忆的快速向量数据库 |
| [**ruflo-rag-memory**](plugins/ruflo-rag-memory/README.md) | 智能检索——混合搜索、图谱跳转、多样性排序 |
| [**ruflo-rvf**](plugins/ruflo-rvf/README.md) | 跨会话保存与恢复智能体记忆 |
| [**ruflo-ruvector**](plugins/ruflo-ruvector/README.md) | [`ruvector`](https://npmjs.com/package/ruvector)——GPU 加速搜索、Graph RAG、103 个工具 |
| [**ruflo-knowledge-graph**](plugins/ruflo-knowledge-graph/README.md) | 构建并遍历实体关系图谱 |

#### 智能与学习

| 插件 | 功能说明 |
|--------|-------------|
| [**ruflo-intelligence**](plugins/ruflo-intelligence/README.md) | 智能体从过往成功中学习,变得越来越聪明 |
| [**ruflo-graph-intelligence**](plugins/ruflo-graph-intelligence/) | 亚线性图推理——PageRank、增量更新、复杂度感知执行(ADR-123) |
| [**ruflo-daa**](plugins/ruflo-daa/README.md) | 动态智能体行为与认知模式 |
| [**ruflo-ruvllm**](plugins/ruflo-ruvllm/README.md) | 通过智能路由运行本地 LLM(Ollama 等) |
| [**ruflo-goals**](plugins/ruflo-goals/README.md) | 将大目标拆解为计划并跟踪进度 |
| [**ruflo-deepseek-harness**](plugins/ruflo-deepseek-harness/README.md) | 在蜂群中运行和评估 DeepSeek 工作流的智能体、命令与技能 |

#### 代码质量与测试

| 插件 | 功能说明 |
|--------|-------------|
| [**ruflo-testgen**](plugins/ruflo-testgen/README.md) | 找出缺失的测试并自动生成 |
| [**ruflo-browser**](plugins/ruflo-browser/README.md) | 使用 Playwright 自动化浏览器测试 |
| [**ruflo-jujutsu**](plugins/ruflo-jujutsu/README.md) | 分析 git diff、评估风险、推荐审查人 |
| [**ruflo-rure**](plugins/ruflo-rure/) | 对你有权研究的本地 JS/Electron 应用做静态分析,并给出文件与行号证据 |
| [**ruflo-docs**](plugins/ruflo-docs/README.md) | 自动生成与维护文档 |

#### 安全与合规

| 插件 | 功能说明 |
|--------|-------------|
| [**ruflo-security-audit**](plugins/ruflo-security-audit/README.md) | 扫描漏洞与 CVE |
| [**ruflo-aidefence**](plugins/ruflo-aidefence/README.md) | 拦截提示词注入、检测 PII、安全扫描 |
| [**ruflo-protector**](plugins/ruflo-protector/README.md) | 可选的无人值守智能体看门狗——学习、通知或强制执行 |

#### 架构与方法论

| 插件 | 功能说明 |
|--------|-------------|
| [**ruflo-adr**](plugins/ruflo-adr/README.md) | 用持续更新的记录跟踪架构决策 |
| [**ruflo-ddd**](plugins/ruflo-ddd/README.md) | 脚手架式搭建领域驱动设计——上下文、聚合、事件 |
| [**ruflo-sparc**](plugins/ruflo-sparc/README.md) | 带质量门的 5 阶段引导式开发方法论 |
| [**ruflo-metaharness**](plugins/ruflo-metaharness/README.md) | 为你的智能体配置打分、扫描工具配置中的安全风险、跟踪长期变更([指南](docs/metaharness-user-guide.md)) |
| [**ruflo-arena**](plugins/ruflo-arena/README.md) | 竞争性 ruliology——在锦标赛中让智能体策略相互对决,对胜者进行爬山优化与共同进化(ADR-147/148) |

#### DevOps 与可观测性

| 插件 | 功能说明 |
|--------|-------------|
| [**ruflo-migrations**](plugins/ruflo-migrations/README.md) | 安全地管理数据库 schema 变更 |
| [**ruflo-observability**](plugins/ruflo-observability/README.md) | 一站式结构化日志、追踪与指标 |
| [**ruflo-cost-tracker**](plugins/ruflo-cost-tracker/README.md) | 跟踪 token 用量、设定预算、获取成本告警 |
| [**ruflo-ruos**](plugins/ruflo-ruos/README.md) | 在你自己的 ruOS 云桌面上运行蜂群智能体 |

#### 可扩展性

| 插件 | 功能说明 |
|--------|-------------|
| [**ruflo-agent**](plugins/ruflo-agent/README.md) | 运行智能体——本地 WASM 沙箱(rvagent)+ Anthropic Claude 托管智能体(云端) |
| [**ruflo-plugin-creator**](plugins/ruflo-plugin-creator/README.md) | 脚手架式创建、校验并发布你自己的插件 |

#### 领域专用

| 插件 | 功能说明 |
|--------|-------------|
| [**ruflo-iot-cognitum**](plugins/ruflo-iot-cognitum/README.md) | IoT 设备管理——信任评分、异常检测、设备群 |
| [**ruflo-neural-trader**](plugins/ruflo-neural-trader/README.md) | [`neural-trader`](https://npmjs.com/package/neural-trader)——AI 交易,含 4 个智能体、回测、112+ 工具 |
| [**ruflo-market-data**](plugins/ruflo-market-data/README.md) | 摄入市场数据、向量化 OHLCV、检测形态 |
| [**ruflo-music**](plugins/ruflo-music/README.md) | 通过 Cognitum Music 账户作曲、生成音轨并处理分轨 |

### CLI 安装

**macOS / Linux / WSL / Git-Bash:**

curl -fsSL https://cdn.jsdelivr.net/gh/ruvnet/ruflo@main/scripts/install.sh | bash


**所有平台(包括原生 Windows PowerShell / cmd):**

npx ruflo@latest init wizard

npm install -g ruflo@latest


> 💡 **Windows 用户请注意:** `curl ... | bash` 这种形式需要 POSIX shell(Git-Bash、WSL、MSYS)。`npx ruflo@latest init wizard` 这一行可以在 PowerShell 与 cmd 中原生运行。如果你遇到 `'bash' is not recognized` 报错,改用 `npx` 那一行即可——两条路径最终执行的都是同一个 init 流程。

### MCP 服务器

claude mcp add claude-flow -- npx ruflo@latest mcp start


---

## 你能获得什么

| 能力 | 说明 |
|------------|-------------|
| 🤖 **100+ 智能体** | 面向编码、测试、安全、文档、架构的专用智能体 |
| 📡 **通信层** | 零信任联邦——跨机器/组织的智能体能够安全地相互发现、认证并交换工作 |
| 🐝 **蜂群协调** | 具备共识机制的层级、网状与自适应拓扑 |
| 🧠 **自学习** | SONA 神经模式、ReasoningBank、轨迹学习 |
| 💾 **向量记忆** | 基于 HNSW 索引的 AgentDB——实测在 N=20k 时比暴力检索快约 1.9 倍,N=5k 时快约 3.2–4.7 倍(recall@10 ≈ 0.99);超过交叉点后 ANN 胜出,小规模 N 下持平或略逊。参见[审计报告](docs/reviews/intelligence-system-audit-2026-05-29.md)与 [`scripts/benchmark-intelligence.mjs`](scripts/benchmark-intelligence.mjs) |
| ⚡ **后台工作者** | 12 个自动触发的工作者(审计、优化、测试缺口等) |
| 🧩 **插件市场** | 48 个原生 Claude Code 插件 + 14 个仓库内 npm 插件 |
| 🔌 **多提供商** | Claude、GPT、Gemini、Cohere、Ollama,支持智能路由 |
| 🛡️ **安全性** | AIDefence、输入校验、CVE 修复、路径穿越防护 |
| 🌐 **智能体联邦** | 跨安装的智能体协作,零信任安全 |
| 🔬 **[MetaHarness](docs/metaharness-user-guide.md)** | 发布前审计你的 AI 智能体配置。对就绪度打分(1–100)、扫描工具配置中的安全问题、对整个项目做快照以捕捉长期回归,并找到与你的仓库匹配的模板。`ruflo eject` 可将 ruflo 项目转换为拥有独立名称的独立智能体工具包。[完整指南](docs/metaharness-user-guide.md)。 |

### 智能体联邦——智能体版的 Slack

Your Agent --> [ Remove secrets ] --> [ Sign message ] --> [ Encrypted channel ] Emails, SSNs, Proves it came No one reads it keys stripped from you in transit | v Their Agent

Visits:10 Updated:2026-12-03 AI tools

Related