Conventions
Code style
- Use
clapderive for CLI argument parsing - Use
serdederive for all data types - Use
serde_yamlfor frontmatter parsing - Use
similarcrate for diffing (pure Rust, no shelldiffdependency) - Use
serde_jsonfor agent response parsing - Use
std::process::Commandfor git operations (notgit2) - Use
toml + serdefor config file parsing - No async — sequential per-run
- Use
anyhowfor application errors
Instruction files
CLAUDE.mdis the primary instruction file- Personal overrides:
CLAUDE.local.md(gitignored) - Actionable over informational. Instruction files contain the minimum needed to generate correct code. Reference material belongs in
README.md. - Update with the code. When a change affects patterns, conventions, or module boundaries, update instruction files as part of the same change.
Version management
- Never bump versions automatically — the user will bump versions explicitly.
- Commits that include a version change should include the version number in the commit message.
- Use
BREAKING CHANGE:prefix in VERSIONS.md entries for incompatible changes. - Update
SPEC.mdwhen agent-doc functionality changes (commands, formats, algorithms).
Workflow
Follow a research, plan, implement cycle:
- Research — Read the relevant code deeply.
- Plan — Write a detailed implementation plan.
- Implement — Execute the plan. Run
make checkcontinuously. - Precommit — Run
make precommitbefore committing.