description: Post-flight analysis for continuous improvement. Use after a flight is completed to capture lessons learned and improve the methodology.
---
# Flight Debrief
Perform comprehensive post-flight analysis for continuous improvement.
## Prerequisites
- Project must be initialized with `/init-project` (`.flightops/ARTIFACTS.md` must exist)
- A flight must have status `landed` before debriefing
## Workflow
### Phase 1: Context Loading
1.**Identify the target project**
- Read `projects.md` to find the project's path
2.**Verify project is initialized**
- Check if `{target-project}/.flightops/ARTIFACTS.md` exists
- **If missing**: STOP and tell the user to run `/init-project` first
- Do not proceed without the artifact configuration
3.**Read the artifact configuration**
- Read `{target-project}/.flightops/ARTIFACTS.md` for artifact locations and formats
4.**Load flight documentation**
- Read the mission for overall context and success criteria
- Read the flight for objectives, design decisions, and checkpoints
- Read ALL legs to understand the planned implementation
- Read the complete flight log for ground truth on what happened
5.**Load project context**
- Read the target project's `README.md` and `CLAUDE.md`
- Identify key implementation files from leg outputs and flight log
6.**Examine actual implementation**
- Read files created or modified during the flight
- Compare intended vs actual implementation
- Note deviations, workarounds, or unexpected discoveries
### Phase 2: Crew Debrief Interviews
Read `{target-project}/.flightops/agent-crews/flight-debrief.md` for crew definitions and prompts (fall back to defaults at `.claude/skills/init-project/defaults/agent-crews/flight-debrief.md`).
**Validate structure**: The phase file MUST contain `## Crew`, `## Interaction Protocol`, and `## Prompts` sections with fenced code blocks. If the file exists but is malformed, STOP and tell the user: "Phase file `flight-debrief.md` is missing required sections. Either fix it manually or re-run `/init-project` to reset to defaults."
#### Developer Interview
1.**Spawn a Developer agent** in the target project context (Task tool, `subagent_type: "general-purpose"`)
- Provide the "Debrief Interview" prompt from the flight-debrief phase file's Prompts section
- The Developer examines code changes, test coverage, patterns, and technical debt
- In addition to the crew prompt, the Flight Director directly instructs the Developer to: run the full test suite once, capture per-suite wall-clock timing, pass/fail counts (with names of any failing tests), skipped/ignored counts, and any flakes observed on the run; then read prior flight debriefs in the project and compare current metrics against any earlier numbers they find. Report findings as narrative — naming suites, quoting deltas, and proposing likely causes when visible from this flight's changes.
- Run the full test suite as part of the debrief and record metrics: per-suite wall-clock timing, pass/fail counts, skipped/ignored tests, and any flakes observed on this run.
- Read prior flight debriefs in this project for earlier metrics observations. Compare current numbers against whatever priors exist.
- Surface meaningful changes — significant slowdowns, new failures, growing skip lists, recurring flakes — as narrative observations in whichever existing section best fits (Technical, Key Learnings, or What Could Be Improved).
- If this is the first flight to capture metrics, the numbers seed comparisons for future flights.