ClaudeMods
☰
ZH-CN
● 0 人在线 · 浏览 0 次
赞助提交作品
GitHub 仓库 · 发布者 ruvnet

ruflo-autopilot

面向 Claude Code 的自主 /loop 驱动任务完成插件,提供学习、预测、进度追踪和 10 个 autopilot_* MCP 工具。

ruvnet@ruvnet

ruvnet/ruflo/tree/main/plugins/ruflo-autopilot

已翻译

关于这个 mod

ruflo-autopilot 是一个 Claude Code 插件,封装 10 个 autopilot_* MCP 工具(status、enable、disable、config、reset、log、progress、learn、history、predict),利用 Claude Code 原生的 /loop 和 ScheduleWakeup 驱动持久、了解缓存的任务完成循环。它会跨 team-tasks、swarm-tasks 和文件清单追踪进度,把成功模式学习到 autopilot-patterns AgentDB 命名空间,并预测最佳下一步操作。它也以 function-hook mod 的形式提供,hooks 会与插件一起载入:默认开启的防护会阻止 autopilot_log/autopilot_learn 写入机密或令牌,也会阻止超过上限的 maxIterations;/autopilot-mod 命令(status、scan、limits)在本地回答;状态文件位于 .claude-flow/autopilot-mod/status.json。选项包括默认开启的 guard 和 iterationCap(1000)。使用 /plugin marketplace add ruvnet/ruflo 和 /plugin install ruflo-autopilot@ruflo 安装;用 smoke.sh(预期 10 passed, 0 failed)或 claude plugin validate/test 验证。

安装

请先查看作者 README 确认 marketplace 和插件名称;命令可能随仓库结构改变。

claude plugin marketplace add ruvnet/ruflo
claude plugin install ruflo-autopilot
原文 / README

ruflo-autopilot

Autonomous /loop-driven task completion with learning and prediction.

Combines Ruflo's 10 autopilot MCP tools with Claude Code's native /loop + ScheduleWakeup for persistent, cache-aware task completion loops.

Install

/plugin marketplace add ruvnet/ruflo
/plugin install ruflo-autopilot@ruflo

Features

  • Autonomous loops: Enable autopilot, then /loop drives iterative task completion
  • Progress tracking: Monitors team-tasks, swarm-tasks, and file checklists
  • Learning: Discovers success patterns from completed tasks via AgentDB
  • Prediction: Predicts optimal next action based on state and learned patterns
  • Cache-aware: ScheduleWakeup at 270s keeps prompt cache warm between iterations

Commands

  • /autopilot -- Enable, configure, or disable autopilot
  • /autopilot-status -- Quick progress summary

Skills

  • autopilot-loop -- How to run an autopilot /loop iteration
  • autopilot-predict -- Use learned patterns to pick the next task

MCP surface (10 tools)

| Tool | Purpose | |------|---------| | autopilot_status | Current autopilot state + learning stats | | autopilot_enable | Turn autopilot on for the project | | autopilot_disable | Turn autopilot off | | autopilot_config | Read/update configuration | | autopilot_reset | Clear learned patterns and progress (testing) | | autopilot_log | Append a structured log entry | | autopilot_progress | Progress summary across team/swarm/file checklists | | autopilot_learn | Train on a completed task; writes to autopilot-patterns | | autopilot_history | Browse past iterations | | autopilot_predict | Predict the optimal next action from learned patterns |

All 10 are wired in v3/@claude-flow/cli/src/mcp-tools/autopilot-tools.ts.

Compatibility

  • CLI: pinned to @claude-flow/cli v3.6 major+minor.
  • MCP surface: the 10 tools above.
  • Verification: bash plugins/ruflo-autopilot/scripts/smoke.sh is the contract.

Cache-aware /loop integration

Autopilot pairs with Claude Code's native /loop + ScheduleWakeup skills. The recommended fallback heartbeat is 270 seconds — under the 5-minute prompt-cache TTL so the next wake-up reads conversation context cached. Going past 300s pays a cache-miss; rounding to 5 minutes is the worst-of-both case.

For event-driven loops, arm a Monitor and let the 270s wake be the safety net.

Namespace coordination

This plugin owns the autopilot-patterns AgentDB namespace (kebab-case, follows the convention from ruflo-agentdb ADR-0001 §"Namespace convention"). Reserved namespaces (pattern, claude-memories, default) MUST NOT be shadowed.

autopilot_learn writes to this namespace via agentdb_pattern-store semantics — see ruflo-intelligence ADR-0001 for the 4-step pipeline this feeds (RETRIEVE → JUDGE → DISTILL → CONSOLIDATE).

Verification

bash plugins/ruflo-autopilot/scripts/smoke.sh
# Expected: "10 passed, 0 failed"

Architecture Decisions

As a mod

Autopilot also ships as a function-hook mod (ADR-445 pattern; hooks in hooks/, loaded with the plugin). No network, no process, no model call.

  • Guard (default on): refuses an autopilot_log or autopilot_learn write that holds a key, token or password, and an autopilot_config maxIterations above iterationCap. It only tightens: it never allows anything the session would deny, and the refusal never repeats the secret. Turn it off with the guard option.
  • /autopilot-mod: answered locally. /autopilot-mod status, /autopilot-mod scan <text>, /autopilot-mod limits.
  • Status file: .claude-flow/autopilot-mod/status.json (version, updatedMs, counters), written at session start and whenever a call is refused; the console reads it.
  • Options (userConfig): guard (on by default), iterationCap (1000).

Test: claude plugin validate plugins/ruflo-autopilot, claude plugin test plugins/ruflo-autopilot, and bash plugins/ruflo-autopilot/scripts/smoke.sh.

更多类似作品