Omni-Agent Builder (OpenClaw)
Design and generate a complete OpenClaw agent workspace with robust defaults:
- secure-by-default operating rules
- optional multi-agent orchestration (Planner / Executor / Critic)
- Personal Intelligence (Pi) memory workflow (
MEMORY.md + daily logs)
- evaluation + acceptance tests
- CLI notes for fast local iteration
Canonical references (read these first)
- Workspace layout + bootstrap file load order + heartbeat rules:
references/openclaw-workspace.md
- File templates/snippets:
references/templates.md
- Background (agent architecture: planning / memory / tool use):
references/architecture.md
Default outputs (workspace files)
Minimum viable workspace (always generate):
AGENTS.md (cross-cutting rules; sub-agents only get this + TOOLS.md by default)
SOUL.md
TOOLS.md
IDENTITY.md
USER.md
HEARTBEAT.md (usually empty to avoid token sink)
BOOTSTRAP.md (one-time ritual; delete after completion)
Optional (generate if requested or clearly beneficial):
MEMORY.md (curated long-term memory; private/main session only)
memory/YYYY-MM-DD.md (daily log seed)
Workflow: build a new agent/team from scratch
Phase 1 — Tight interview (clarifying questions)
Ask only what you need. Prefer 1–2 short rounds.
Mission + autonomy
- Mission (1 sentence)
- Single agent or multi-agent orchestration?
- Autonomy: Advisor / Operator / Autopilot
Surfaces + boundaries
- Channels: Telegram/WhatsApp/Discord/iMessage/Slack/etc.
- Private DM only vs group channels?
- “Ask before outbound messages” rule (default: ALWAYS ask)
Tools + CLI usage
- Must it run local
openclaw CLI commands? Which quick aliases are desired?
- Any repos/paths it should assume?
Pi memory
- Should it maintain curated
MEMORY.md?
- Categories: preferences, projects, people/orgs, “never do”, conventions, vocab
- Privacy: what must never be stored?
Bootstrapping ritual
- Any first-run steps (connect channels, create folders, install deps)?
Evaluation
- What metrics define success?
- 5–10 acceptance tests you want it to pass (we’ll propose defaults if none)
Phase 2 — Generate the workspace files
Generate the files listed above. Use the templates but tailor to the user’s answers.
Required global guardrails to include (at minimum):
- Ask-before-destructive (prefer
trash over rm; create backups; show diffs)
- Ask-before-outbound (never send messages/emails/DMs/calls without explicit approval)
- Stop-on-CLI-error (unknown flag/exit code → run
--help, correct, retry)
- No secrets in repo (credentials/config belong under
~/.openclaw/…, not the workspace)
- Group etiquette (don’t claim to be the user; don’t leak private memory)
- Loop breaker (max iterations; escalate to user with options)
Phase 3 — Orchestration (if multi-agent)
If multi-agent, define roles in AGENTS.md:
Planner
- breaks tasks into steps
- identifies risks + guardrails
- defines acceptance tests
Executor
- runs tools/edits files
- maintains change log + rollback notes
- stops on errors and recovers via
--help / docs
Critic
- reviews outputs for safety + completeness
- checks for policy violations, overreach, and missing requirements
- proposes fixes (minimal diffs)
Delegation contract (must be in AGENTS.md):
- Context to pass: goal, constraints, definition of done, relevant workspace excerpts
- Explicit do-nots: no destructive actions; no outbound messages; no secrets
Phase 4 — Pi memory workflow (recommended defaults)
- Append raw notes to
memory/YYYY-MM-DD.md (daily log; append-only)
- Curate durable items into
MEMORY.md (preferences, stable facts, conventions)
- Only load/use
MEMORY.md in main private session; avoid in group channels
- If the user says “remember this”, persist it
Phase 5 — Evaluation + acceptance tests
Provide 5–10 short test prompts. Include at least:
- Safety test (draft but do not send; ask before sending)
- CLI recovery test (unknown flag →
--help recovery)
- Pi retention test (store + recall a preference correctly)
- Orchestration test (delegate; show what context was passed)
- Group chat etiquette test (avoid leaking private memory)
Workflow: iterate on an existing agent
- Identify the top failure modes (overreach, loops, verbosity, hallucinations, unsafe actions).
- Decide if changes belong in:
SOUL.md (tone/persona)
AGENTS.md (rules, delegation, memory workflow)
HEARTBEAT.md (keep tiny; avoid deep thinking)
TOOLS.md (environment notes + CLI aliases)
- Propose minimal diffs with rollback notes.
- Add/update acceptance tests.
Deliverable format
When you output a workspace:
- Print each file with a heading and a fenced code block.
- If generating a zip, include the complete directory tree and a short “how to install” section.
1---2name: omni-agent-builder3description: Build high-performing, secure OpenClaw agents and multi-agent teams end-to-end. Generates required OpenClaw workspace files (SOUL.md, IDENTITY.md, AGENTS.md, USER.md, TOOLS.md, HEARTBEAT.md, BOOTSTRAP.md, optional MEMORY.md + memory/YYYY-MM-DD.md). Incorporates best practices for team orchestration, Personal Intelligence (Pi) memory management, continuous evaluation, and CLI-driven setup/deployment.4---56# Omni-Agent Builder (OpenClaw)78Design and generate a complete **OpenClaw agent workspace** with robust defaults:9- secure-by-default operating rules10- optional multi-agent orchestration (Planner / Executor / Critic)11- Personal Intelligence (Pi) memory workflow (`MEMORY.md` + daily logs)12- evaluation + acceptance tests13- CLI notes for fast local iteration1415## Canonical references (read these first)16171) Workspace layout + bootstrap file load order + heartbeat rules: `references/openclaw-workspace.md` 182) File templates/snippets: `references/templates.md` 193) Background (agent architecture: planning / memory / tool use): `references/architecture.md`2021## Default outputs (workspace files)2223Minimum viable workspace (always generate):24- `AGENTS.md` (cross-cutting rules; **sub-agents only get this + TOOLS.md by default**)25- `SOUL.md`26- `TOOLS.md`27- `IDENTITY.md`28- `USER.md`29- `HEARTBEAT.md` (usually empty to avoid token sink)30- `BOOTSTRAP.md` (one-time ritual; delete after completion)3132Optional (generate if requested or clearly beneficial):33- `MEMORY.md` (curated long-term memory; private/main session only)34- `memory/YYYY-MM-DD.md` (daily log seed)3536## Workflow: build a new agent/team from scratch3738### Phase 1 — Tight interview (clarifying questions)3940Ask only what you need. Prefer 1–2 short rounds.41421) **Mission + autonomy**43 - Mission (1 sentence)44 - Single agent or multi-agent orchestration?45 - Autonomy: Advisor / Operator / Autopilot46472) **Surfaces + boundaries**48 - Channels: Telegram/WhatsApp/Discord/iMessage/Slack/etc.49 - Private DM only vs group channels?50 - “Ask before outbound messages” rule (default: ALWAYS ask)51523) **Tools + CLI usage**53 - Must it run local `openclaw` CLI commands? Which quick aliases are desired?54 - Any repos/paths it should assume?55564) **Pi memory**57 - Should it maintain curated `MEMORY.md`?58 - Categories: preferences, projects, people/orgs, “never do”, conventions, vocab59 - Privacy: what must never be stored?60615) **Bootstrapping ritual**62 - Any first-run steps (connect channels, create folders, install deps)?63646) **Evaluation**65 - What metrics define success?66 - 5–10 acceptance tests you want it to pass (we’ll propose defaults if none)6768### Phase 2 — Generate the workspace files6970Generate the files listed above. Use the templates but tailor to the user’s answers.7172Required global guardrails to include (at minimum):73- **Ask-before-destructive** (prefer `trash` over `rm`; create backups; show diffs)74- **Ask-before-outbound** (never send messages/emails/DMs/calls without explicit approval)75- **Stop-on-CLI-error** (unknown flag/exit code → run `--help`, correct, retry)76- **No secrets in repo** (credentials/config belong under `~/.openclaw/…`, not the workspace)77- **Group etiquette** (don’t claim to be the user; don’t leak private memory)78- **Loop breaker** (max iterations; escalate to user with options)7980### Phase 3 — Orchestration (if multi-agent)8182If multi-agent, define roles in `AGENTS.md`:8384- **Planner**85 - breaks tasks into steps86 - identifies risks + guardrails87 - defines acceptance tests8889- **Executor**90 - runs tools/edits files91 - maintains change log + rollback notes92 - stops on errors and recovers via `--help` / docs9394- **Critic**95 - reviews outputs for safety + completeness96 - checks for policy violations, overreach, and missing requirements97 - proposes fixes (minimal diffs)9899Delegation contract (must be in `AGENTS.md`):100- Context to pass: goal, constraints, definition of done, relevant workspace excerpts101- Explicit do-nots: no destructive actions; no outbound messages; no secrets102103### Phase 4 — Pi memory workflow (recommended defaults)104105- Append raw notes to `memory/YYYY-MM-DD.md` (daily log; append-only)106- Curate durable items into `MEMORY.md` (preferences, stable facts, conventions)107- Only load/use `MEMORY.md` in **main private session**; avoid in group channels108- If the user says “remember this”, persist it109110### Phase 5 — Evaluation + acceptance tests111112Provide 5–10 short test prompts. Include at least:113- Safety test (draft but do not send; ask before sending)114- CLI recovery test (unknown flag → `--help` recovery)115- Pi retention test (store + recall a preference correctly)116- Orchestration test (delegate; show what context was passed)117- Group chat etiquette test (avoid leaking private memory)118119## Workflow: iterate on an existing agent1201211) Identify the top failure modes (overreach, loops, verbosity, hallucinations, unsafe actions).1222) Decide if changes belong in:123 - `SOUL.md` (tone/persona)124 - `AGENTS.md` (rules, delegation, memory workflow)125 - `HEARTBEAT.md` (keep tiny; avoid deep thinking)126 - `TOOLS.md` (environment notes + CLI aliases)1273) Propose minimal diffs with rollback notes.1284) Add/update acceptance tests.129130## Deliverable format131132When you output a workspace:133- Print each file with a heading and a fenced code block.134- If generating a zip, include the complete directory tree and a short “how to install” section.