Summary
claude-flow init --codex currently generates a much weaker AGENTS.md than the canonical AGENTS.md checked into this repo.
The generated default template misses key operational guidance that the repo version already documents clearly, especially around the Codex/claude-flow execution model.
Reproduction
- Clone
ruvnet/ruflo.
- Run
claude-flow init --dual in a clean directory or inspect the Codex generator output.
- Compare the generated
AGENTS.md against the repository root AGENTS.md.
Actual Behavior
The generated file is a generic template with basic project/setup/security sections, but it omits important guidance already present in the repo copy, including:
claude-flow = LEDGER / Codex = EXECUTOR
- the rule to continue working immediately after coordination commands
- stronger MCP/memory workflow guidance
- practical quick commands and richer execution examples
Expected Behavior
The default Codex AGENTS.md template should be at least as strong as the repo's canonical guidance, or derive from the same source so they do not drift.
Likely Root Cause
The Codex init path uses the stale generic default template in:
v3/@claude-flow/codex/src/generators/agents-md.ts
The CLI maps claude-flow init --codex to the default template unless --minimal or --full is passed.
Suggested Fix
- Update the default AGENTS generator content to include the canonical Codex/claude-flow workflow guidance.
- Add a regression test in
v3/@claude-flow/codex/tests/generators.test.ts that checks for the missing execution-model and MCP/memory guidance.
- Longer term: consider generating the repo
AGENTS.md and the init template from a shared canonical source to avoid future drift.
Validation
A useful regression check would assert that the generated default template contains items like:
claude-flow = LEDGER
Codex = EXECUTOR
DON'T STOP AFTER CALLING CLAUDE-FLOW
memory_search(query="task keywords")
swarm_init(topology="hierarchical")
## MCP Integration
Summary
claude-flow init --codexcurrently generates a much weakerAGENTS.mdthan the canonicalAGENTS.mdchecked into this repo.The generated default template misses key operational guidance that the repo version already documents clearly, especially around the Codex/claude-flow execution model.
Reproduction
ruvnet/ruflo.claude-flow init --dualin a clean directory or inspect the Codex generator output.AGENTS.mdagainst the repository rootAGENTS.md.Actual Behavior
The generated file is a generic template with basic project/setup/security sections, but it omits important guidance already present in the repo copy, including:
claude-flow = LEDGER/Codex = EXECUTORExpected Behavior
The default Codex
AGENTS.mdtemplate should be at least as strong as the repo's canonical guidance, or derive from the same source so they do not drift.Likely Root Cause
The Codex init path uses the stale generic default template in:
v3/@claude-flow/codex/src/generators/agents-md.tsThe CLI maps
claude-flow init --codexto thedefaulttemplate unless--minimalor--fullis passed.Suggested Fix
v3/@claude-flow/codex/tests/generators.test.tsthat checks for the missing execution-model and MCP/memory guidance.AGENTS.mdand the init template from a shared canonical source to avoid future drift.Validation
A useful regression check would assert that the generated default template contains items like:
claude-flow = LEDGERCodex = EXECUTORDON'T STOP AFTER CALLING CLAUDE-FLOWmemory_search(query="task keywords")swarm_init(topology="hierarchical")## MCP Integration