A tool that lets anyone build their own focused AI agent assistant — like ruflo, but uniquely theirs. With their own brand, their own agents, their own CLI command, running on Claude Code, Codex, pi.dev, or Hermes.
Live on GitHub: https://github.com/ruvnet/agent-harness-generator
If you want to build "an AI assistant for legal review" or "an AI assistant for trading" or "an AI assistant for incident response," you have two bad choices today. Option A: fork ruflo and rip out the 60+ agents you don't need. You inherit a tangled product and you lose every future update. Option B: build everything from scratch. You re-derive the MCP server, the memory database, the routing layer, the hooks system. Months gone before you write your first domain-specific prompt.
There's no middle path. The generator is the middle path.
You run one command:
npx create-agent-harness my-legal-bot
A wizard asks a few questions — what's it for, who's the host, what agents do you want, what skills, what memory backend. Then it scaffolds a complete, ready-to-publish npm package with:
- Your own command (
npx my-legal-bot init) - Your own brand (no "ruflo" anywhere unless you opt in)
- Your own MCP server
- Your own memory namespace
- Your own marketplace identity
- Your own selection of agents, skills, plugins, prompts
And under the hood, it shares the same battle-tested kernel as ruflo: the same MCP server, the same memory bridge, the same routing layer, the same intelligence pipeline. When the kernel gets a security fix, your harness gets it too via npm.
The kernel — the part that's the same in every generated harness — is Rust source code compiled to WebAssembly, with an optional native fallback through NAPI-RS for hot Node paths.
This sounds technical but the consequences are practical:
- Same code runs everywhere. Node, the browser, Cloudflare Workers, Deno, Bun, edge runtimes — all run the same kernel bytes. A harness you ship doesn't care where it runs.
- Deterministic. Two CI runners produce byte-identical kernel output. That's what makes the cryptographic witness manifest (Ed25519-signed file describing exactly what shipped) actually verifiable.
- Memory-safe. Rust's borrow checker eliminates a whole class of kernel bugs that JavaScript can't.
- Already works.
@ruvector/emergent-time@0.1.0ships through exactly this pipeline today. 55 KB. Loads in Node, browser, bundler. The agent-harness-generator kernel reuses the same machinery.
A harness you generate can target any of:
| Host | What it is |
|---|---|
| Claude Code | Anthropic's CLI. Richest hook system. The original ruflo target. |
| OpenAI Codex | OpenAI's CLI. MCP via TOML config. No first-class hooks. |
| pi.dev | badlogic/Pi coding agent. Token-conscious — deliberately ships without MCP. The adapter uses Pi's registerTool() API instead. |
| Hermes Agent | Nous Research's runtime. MCP-supported. Adapter scrubs <think> and stray <tool_call> text from Hermes-4 models. |
You can target one, or all four. The kernel and the content stay the same. Only the thin adapter layer changes per host.
This isn't just "scaffold and forget." The design commits to:
- CI guards — every release must pass a matrix build (wasm + 5 native targets), a
wasm-tools validatepass, a size budget, and a cross-platform parity test. Anything else andnpm publishis blocked. - Drift detection — uses Copier's regenerate-diff-merge model. The generator remembers what choices you made (
.harness/manifest.json), and when the template updates, it can re-apply the new template against your current customizations safely. - Anti-slop — derived trust tiers from measured signals (smoke test results, npm provenance, maintenance cadence, real usage) instead of editorial review. Cites SOTA from Socket.dev typosquatting detection, HF Model Cards, SLSA v1.0, VS Code Marketplace clean-room VMs, Chrome Web Store review.
- TDD — every primitive, every renamer, every template has a test contract specified before any code lands. London-school for the kernel, integration for the generator, contract tests for each host adapter.
- Provenance — Ed25519-signed witness manifest per generated harness, byte-deterministic across CI runners (which the WASM kernel enables). Mirrors ruflo's existing ADR-103.
The generator works at both ends:
- Practical: 3-agent customer-support harness, 5 minutes from
npxto your own published CLI - Vertical: trading harness with market-data plugins + risk agents + backtesting skills, drawn from a curated vertical pack
- Multi-host: same harness ships unchanged to Claude Code, Codex, AND Hermes
- Federated: multiple instances coordinate via a federation transport — your team's harness talks to your customer's harness with zero-trust security
- Self-evolving: harness uses its own learning loop to optimize its own routing rules over time. Uses
LearnedWeightsfrom@ruvector/emergent-time. - Plugin-author: harness publishes its own plugins back to the marketplace under its own scope
Design phase complete. 17 ADRs (Architecture Decision Records) landed today, each plain-language, SOTA-cited, and ending with a concrete test contract. No code yet — engineers will implement against the documents.
Read the design:
- Hero README: https://github.com/ruvnet/agent-harness-generator
- ADR series guide: https://github.com/ruvnet/agent-harness-generator/blob/main/docs/adrs/INDEX.md
- Tracking issue (discussion): ruvnet/ruflo#2376
- ADR PR branch (the source of truth for the design): https://github.com/ruvnet/ruflo/tree/feat/harness-generator-adrs
If you have 5 minutes:
- Read ADR-001 Goals & non-goals — what this is and isn't.
- Skim ADR-002 Kernel boundary — the single load-bearing decision.
- Skim ADR-003 Generator architecture — how the CLI actually works.
Everything else is reachable from the INDEX.
Phase 0 (kernel extraction) and Phase 1 (generator MVP) need engineers. The design is on file — review it, push back on the bad parts, then build against it.
Track issues: https://github.com/ruvnet/ruflo/issues?q=is%3Aissue+label%3Aharness-generator