Skip to content

Development Lifecycle

Every non-trivial task follows this lifecycle:

OBSERVE → ROUTE → SHAPE → BUILD → PROVE → SHIP
PhaseWhat happensForgeplan commands
ObserveUnderstand current stateforgeplan health, memory_recall
RouteDetermine depth + pipelineforgeplan route "task"
ShapeCreate artifacts, fill requirementsforgeplan new prd, forgeplan validate
BuildImplement + testcargo test, pytest, pnpm test
ProveCreate evidence, scoreforgeplan new evidence, forgeplan score
ShipActivate, commit, PR, mergeforgeplan activate, gh pr create

Before doing anything — understand what’s happening:

Terminal window
# 1. Restore context from memory
memory_recall("project name")
# 2. Check project health
forgeplan health
# → Shows: blind spots, orphans, stale artifacts
# 3. Check current tasks
# Orchestra: mcp__orch__query_entities(status: "in_progress")
# Or: check TODO.md

Rule: if health shows blind spots or orphans — fix them FIRST, before starting new work.

Determine the right level of rigor:

Terminal window
forgeplan route "add payment processing"
# → Depth: Deep
# → Pipeline: PRD → Spec → RFC → ADR
# → Confidence: 92%
DepthWhat to doTime
TacticalJust code, no artifactsMinutes
StandardPRD → RFC → code → evidenceHours
DeepPRD → Spec → RFC → ADR → code → evidenceDays
CriticalEpic → PRD[] → Spec[] → RFC[] → ADR[]Weeks

Tactical = skip to Build. Everything else = continue to Shape.

Create the right artifacts and fill them:

Terminal window
# Create artifact
forgeplan new prd "Payment Processing"
# Fill MUST sections: Problem, Goals, Non-Goals, Target Users, FR
# Each FR: "[Actor] can [capability]" — no tech names
# Validate
forgeplan validate PRD-001
# → PASS (0 MUST errors)

Before coding — reason through alternatives:

Terminal window
forgeplan reason PRD-001
# → 3+ hypotheses
# → Predictions for each
# → Evidence check

If all hypotheses converge → code with confidence. If competing approaches → discuss with team before coding.

Deep/Critical: ADI is MANDATORY. Skipping it is a methodology violation.

Implement the solution:

Terminal window
# 1. Create branch
git checkout dev && git pull origin dev
git checkout -b feat/payment-processing
# 2. Code
# - Test every new public function IMMEDIATELY
# - Don't move to next function without test
# 3. Format + lint
cargo fmt && cargo fmt -- --check # Rust
ruff format && ruff check # Python
pnpm exec tsc --noEmit # TypeScript
# 4. Test
cargo test # Rust
pytest # Python
pnpm test # TypeScript
Terminal window
# Run multi-expert audit (4 agents: logic, architecture, security, tests)
/audit
# Fix all HIGH/CRITICAL findings
# Then RE-RUN tests after fixes — don't trust previous run

Create evidence that the solution works:

Terminal window
# Create evidence pack
forgeplan new evidence "Payment: 15 tests pass, Stripe benchmark 200ms"
# Add structured fields to body (REQUIRED):
# verdict: supports
# congruence_level: 3
# evidence_type: test
# Link to decision
forgeplan link EVID-001 PRD-001 --relation informs
# Check score
forgeplan score PRD-001
# → R_eff = 1.00

Activate the artifact and create PR:

Terminal window
# 1. Review + activate
forgeplan review PRD-001
forgeplan activate PRD-001
# 2. Push + PR
git push origin feat/payment-processing
gh pr create --base dev --title "[PRD-001] Payment Processing"
# 3. After merge — sync
git checkout dev && git pull origin dev
# 4. Save to memory
memory_retain("Payment processing: implemented, 15 tests, R_eff=1.00")
# 5. Update progress
# - RFC checkboxes: [x]
# - TODO.md: move to Done
Research → PRD → Spec → RFC → ADR → Build → Audit → Evidence

Everything is unknown. Need all artifacts. Start with Research.

Explore → Identify → {
feature: PRD → RFC → Build
bug: Problem → Fix
refactor: Audit → Problem → RFC → Build
migration: Research → ADR → RFC → Build
}

Code already exists. Start with Explore (understand what’s there).

New bounded context → Greenfield pipeline
Existing module → Brownfield pipeline

Choose pipeline by context, not by project.

The /forge-cycle command runs all phases automatically:

/forge-cycle PRD-001
Phase 0: OBSERVE → forgeplan health
Phase 1: ROUTE → forgeplan route
Phase 2: SPRINT → /sprint (plan waves)
Phase 3: BUILD → /team-up (implement)
Phase 4: AUDIT → /audit (adversarial review)
Phase 5: FIXES → fix HIGH/CRITICAL
Phase 6: EVIDENCE → forgeplan new evidence + score
Phase 7: COMMIT → git commit + PR
Phase 8: NEXT → forgeplan health → next task
Session typeDoDon’t
Tactical (concrete task)Code, test, commitDon’t drift into planning
Strategic (research, planning)Research, create artifactsDon’t start coding

If you notice scope drift → bookmark progress → start a new session of the right type.

  • Artifact filled (MUST sections)
  • Validation PASS
  • ADI reasoning done (Standard+)
  • Code implemented
  • Tests pass
  • Format + lint clean
  • Audit: 0 HIGH/CRITICAL
  • Evidence created with structured fields
  • R_eff > 0
  • Artifact activated
  • PR created and merged
  • Progress updated (RFC checkboxes, TODO.md)
  • Memory retained (if significant)