Reference

Command Reference

All REAP interactions go through /reap.* slash commands. These are the primary interface for both users and AI agents.

Lifecycle Commands

CommandDescription
/reap.evolveRun an entire generation lifecycle (recommended). The primary command for day-to-day development. Loops through all stages — learning, planning, implementation, validation, completion.
/reap.startStart a new generation. Prompts for a goal, creates current.yml, and sets stage to learning. If pending backlog exists and --backlog <filename> is omitted, prompts for selection; use --no-backlog to explicitly skip.
/reap.nextAdvance to the next lifecycle stage. Verifies artifact exists and nonce chain before advancing.
/reap.backReturn to a previous stage (micro loop). Usage: /reap.back [--reason "<reason>"]
/reap.early-closeLightweight termination from implementation/validation — preserves partial value, runs streamlined reflect (no fitness/adapt), and auto-defers incomplete tasks to a new backlog item for the next generation. Options: --reason, --source-action <hold|stash|none> (default hold), --defer-tasks <true|false> (default true).
/reap.abortAbort current generation. 2-phase process: confirm (shows what will happen) then execute. Options: --phase execute, --reason, --source-action <rollback|stash|hold|none>, --save-backlog.

Collaboration Commands

CommandDescription
/reap.mergeMerge lifecycle for parallel branches. Usage: /reap.merge [--type merge --parents "<branchA>,<branchB>"]
/reap.pullFetch remote changes and detect merge opportunities.
/reap.pushValidate REAP state (warn if generation in progress) and push the current branch to remote.

General Commands

CommandDescription
/reap.initInitialize REAP in a project. Auto-detects greenfield vs existing codebase.
/reap.knowledgeManage genome, environment, and context knowledge. Subcommands: reload, genome, environment.
/reap.configView/edit project configuration (.reap/config.yml).
/reap.statusCheck current generation state, stage progress, and backlog summary.
/reap.helpShow available commands and topics.
/reap.runExecute a lifecycle command directly. For fine-grained stage and phase control.
/reap.updateRun migration from v0.15 to v0.16.

Script Orchestrator Architecture

Every slash command is a 1-line .md wrapper that calls reap run <cmd>. The TypeScript script handles all deterministic logic and returns structured JSON instructions for the AI agent. Pattern: Gate (precondition check) → Steps (work execution) → Artifact (recorded to .reap/life/).

CLI Commands (reference)

CLI commands (reap ...) run in your terminal. They handle project setup and maintenance — init, status, run, fix, clean, destroy, make backlog, cruise. They do not interact with the AI agent.