/retrospect โ Release retrospective with validation enforcement
Run a structured retrospective on a shipped commit range (or single commit, or current session). Produces a 10-section markdown report with per-fix verdicts, validation status, action recommendations, and re-diagnosis when fixes failed. Writes findings to knowledge/logs/retrospect/ and runs aria's standard intake. Source spec: docs/specs/2026-05-03-retrospect-skill-design.md.
When to use
- After a release ships and the bug is partially or fully unresolved
- When the user reports a regression and a recent change set could be the cause
- Before proposing another fix to a bug that's already been "fixed" once
- As a soft-suggested response to user pushback ("review what you did," "are these changes necessary")
Step 0: Inputs & Mode Detection
Parse the invocation arguments. The first positional argument is the scope keyword; subsequent positional arguments are scope-specific. Seven scopes plus a no-args default:
| Scope | Trigger | Backward-compat flag (still accepted) | Bundle source |
|---|---|---|---|
| (no args) | /retrospect | โ | Auto-range: last push on current branch โ git log @{push}..HEAD if upstream is set, else git log -10 and ask user to confirm range |
| commit | /retrospect commit <hash> | --commit <hash> | Single commit |
| range | /retrospect range <ref1>..<ref2> | --range <ref1>..<ref2> | git log <ref1>..<ref2> |
| pr | /retrospect pr <num> | --pr <num> | gh pr view <num> --json commits then resolve to commit SHAs |
| session | /retrospect session | --session | Files Claude has touched in the current conversation (read from session state, not git). No deploy yet โ all fixes auto-tag ๐ซ unvalidatable. |
| release (NEW) | /retrospect release | (none) | Commits since the most recent semver tag. git describe --tags --abbrev=0 to find the tag, then git log <tag>..HEAD. If no tags exist on the repo, fall back to auto-range and warn the user. |
| deployment (NEW) | /retrospect deployment | (none) | Commits since the last deployment marker โ see "Deployment detection cascade" below. |
Argument parsing rules:
- If the first positional arg matches a scope keyword (case-insensitive), use it. Otherwise treat it as auto-range and try to parse the args under the legacy flag form.
- Backward-compat flag forms (
--range,--pr,--session,--commit) remain accepted indefinitely. Both/retrospect range a..band/retrospect --range a..bresolve identically. - Modifier flags (apply to any scope):
--ticket-post(post the retrospective verdict to detected tickets at end; legacy alias--linear-poststill accepted),--no-source(skip Step 3.5's Evidence-Sourcing Pass),--lens=overbuild(run the over-build review pass โ see "Over-build lens" section; opt-in, off by default).
Deployment detection cascade (Q2.1=3)
When invoked as /retrospect deployment, attempt to resolve the deployment marker by trying these signals in order. First success wins; on no-success, fall through to the prompt.
- GitHub Releases โ
gh release view --json publishedAt,tagName 2>/dev/null(most recent release). If returned, treat the release tag as the marker; bundle =git log <tag>..HEAD. - Semver tags โ
git tag --sort=-creatordate | head -1. If a tag matchesv?\d+\.\d+\.\d+(and step 1 returned nothing), use it as the marker. - Last commit on
main(ormaster) โgit log -1 --format=%H origin/main(ororigin/masterifmaindoesn't exist). Treat as the marker; bundle =git log <sha>..HEAD. This catches projects without releases or tags. - Prompt user โ if none of the above resolved (e.g., no remote, no tags, no
ghauth), ask: "I couldn't auto-detect the last deployment for/retrospect deployment. Provide a marker (commit hash, tag, or ISO timestamp), or typeauto-rangeto fall back to last-push behavior."
Print the resolved marker source ("Detected via gh release: v1.4.2 (2026-05-01)") in the Anchor block (ยง4.1) so the user can verify what the skill thought "deployment" meant.
After mode detection, gather:
- Goal โ Ask the user: "What was this release/range supposed to fix? (One sentence is fine.)" If they don't reply, fall back to commit message subjects + PR description.
- Tickets โ Scan commit messages with regex
\b([A-Z]{2,}-\d+)\bfor ticket IDs (the pattern is vendor-neutral โ it matches DEV-123, PROJ-45, JIRA-9 alike). If any are found AND a project-tracker MCP is available, fetch each ticket's Product/Technical Intake + recent comments. If a project-tracker MCP is unavailable, note "ticket context unavailable" but continue. - Post-deploy outcome โ Ask the user: "For each fix, what's the post-ship evidence? (โ closed / โ partial / โ failed / โ untested)" Show the per-commit list and accept inline replies. If user can't supply evidence for any fix, mark those โ and note that ยง10 will recommend instrumentation.
If scope is session (or invoked via --session), skip post-deploy outcome (no production yet) and tag all fixes ๐ซ unvalidatable; their actions will resolve to HOLD-PENDING-DEPLOY.
Step 0.5: Active Knowledge Surfacing
If the user's config (~/.gemini/antigravity/aria-knowledge.local.md) has active_knowledge_surfacing: true (default as of v2.15.0), surface relevant tagged knowledge BEFORE Steps 1-3 so loaded files inform pattern selection and evidence sourcing. If the field is false, skip this step entirely (note Active surfacing: disabled in the Anchor block).
Algorithm:
- Build references. The CLI reads what the scope is about itself; you hand it references, never text:
- every scope that resolves to a commit range โ no args (auto-range),
commit(<hash>^..<hash>),range,pr(its base and head commits),release(<tag>..HEAD),deployment(<marker>..HEAD) โ--git-range '<a>..<b>'; - scope
session(no commits yet) โ write the Goal sentence from Step 0, the touched files' names and any detected ticket IDs (e.g.,ABC-123) to a NEW, uniquely named file in your runtime's scratchpad directory (else the system temp directory; never an existing file) with your runtime's file-write tool โ never a shell redirect,echo,printfor heredoc โ then--file '<that scratch path>'. - โ If a path or ref contains
', a backtick or$, do not pass it โ git refs from a cloned remote are third-party text. Use the commit hashes git shows instead, or noteActive surfacing: unavailable (unsafe reference)and skip to Step 1.
2โ6. Rank and select (one CLI call โ do not re-implement it). Run the surfacing CLI with those references, every argument in single quotes: if an ARIA SURFACE โ "<path>" line reached you at session start, use that path, as sh '<path>'; otherwise use sh "${CLAUDE_PLUGIN_ROOT}/bin/aria-surface.sh" with the same arguments. Pass --file and --git-range together when the scope has both:
sh '<path>' --git-range '<a>..<b>'
sh '<path>' --file '<file path>'
โ Never put task text โ a goal sentence, a PR title, a commit subject, pasted text โ on the command line, in a heredoc or through a pipe: the shell runs backticks, $(โฆ) and $VAR there. A path or a ref range is a reference you chose, and single quotes keep it literal; the CLI reads the range's commit subjects, or the file's headings and first lines, itself. It reads the tag index, matches tags (including the configured-project vocabulary and aliases) and ranks the candidates; it prints line 1 tags: <matched tags> followed by up to 5 ranked paths, one per line, relative to <knowledge_folder> (resolve <knowledge_folder> from the config's knowledge_folder field). It prints nothing when surfacing does not fire (no matching tag, or below the firing rule) โ in that case note Active surfacing: 0 matches (below threshold) in the Anchor block and skip to Step 1. โ If it prints unavailable: <reason> (no config, no index, an unreadable index, or an internal error), or the command is not found or exits non-zero, note Active surfacing: unavailable (<the reason or error>) in the Anchor block instead โ never Active surfacing: 0 matches, which would claim the index was searched โ and skip to Step 1. The ranking lives in that script alone: never re-order, re-cap or re-filter its output.
- Ledger filter (best-effort). The ledger is the file named by
ledger=in this session'sARIA CONFIGline โ the session-start hook names it, in the private per-user state directory, with this session's own id. If that file exists, read it and drop any matched paths already listed there โ they were surfaced by an earlier hook/skill in this session. โ Ifledger=isnone, or noARIA CONFIGline reached you, or the file is absent, skip nothing: proceed UNFILTERED and say so in the surfacing block (Ledger: none for this session โ proceeding unfiltered). โ Never substitute a path of your own: another session's ledger DROPS files never surfaced to this session, so the filter would suppress exactly the knowledge this step exists to load. The ledger records paths RELATIVE to<knowledge_folder>, the same form the index lists them in and (in Claude Code) the CLI prints them in, so compare paths against ledger lines exactly as printed; do not resolve them first.
- Read matched files. For each remaining path (up to 5), resolve it against
<knowledge_folder>to an absolute path beforeRead(the tool needs an absolute path; paths come relative), thenReadthe full file into context. Read the top 5 as ranked. Then, if none of the paths you read is underlogs/retrospect/, look under the tags on the CLI'stags:line in## Tag Indexof<knowledge_folder>/index.mdforlogs/retrospect/lines andReadat most ONE โ the most recent by its dated filename โ and say in the surfacing block that it was added for loop closure (past retros inform new retros on the same topic). Never reorder or drop any of the top 5.
- Summarize. Before Step 1's Anchor Block, emit a 3-line surfacing block:
```
Active Knowledge Surfacing:
Tags matched: <tag1> <tag2> ...
Files loaded: <N> (<file1>, <file2>, ...)
Relevance: <one sentence per file: why this informs the retrospective>
```
- Carry-forward. These loaded files become input to Step 2 (Load Pattern Libraries โ past retros may already have catalogued the relevant failure-mode patterns) and Step 3.5 (Evidence-Sourcing Pass โ they may already provide validation or falsification for fixes in this range).
- Tracked artifacts surfacing (added v2.16.1). After Step 10's carry-forward, ALSO surface CODEMAP + STITCH for the analyzed range's project. The shared lib at
${CLAUDE_PLUGIN_ROOT}/bin/lib-tracked-artifacts.shimplements equivalent logic for hooks; this step inlines the algorithm for skill-context portability.
a. Detect project tag from changed file paths. Run git diff --name-only <range> for the analyzed bundle. For each changed file, check whether any projects_list[<tag>].path appears as substring. Count matches per tag; pick the tag with the most matches. Tie-breaker: explicit project flag if provided. If no detection (e.g., bundle touches knowledge folder only, no project files), skip the rest of Step 11.
b. Resolve project root via Bash. Parse projects_list: from ~/.gemini/antigravity/aria-knowledge.local.md frontmatter (comma-separated tag:path). For the detected tag, compute project_root = $HOME/Projects/<path>. If directory doesn't exist, skip.
c. CODEMAP directory load (if {project_root}/CODEMAP.md exists). Compute boundary via awk '/^## [0-9]+\.|^---$/ && NR>5 {print NR; exit}' "{project_root}/CODEMAP.md"; Read limit = (end - 1) (fallback 50 if awk empty). Compute age = (today - mtime).days; read codemap_staleness_threshold_days (default 14). If age > 2*threshold, refuse and emit [refused โ run /codemap update first]. Else if age > threshold, annotate [STALE โ consider /codemap update]. Else fresh. Unless refused: Read {project_root}/CODEMAP.md offset=0 limit=<end-1>.
d. STITCH load (only if {project_root}/STITCH.md exists โ multi-repo signal). Same staleness logic with stitch_staleness_threshold_days (default 30). Unless refused: Read {project_root}/STITCH.md (full file).
e. Ledger dedup. Use the same ledger โ the file named by ledger= in ARIA CONFIG (see item 7). Before loading in (c)/(d), grep ledger for each artifact path; if found, silent skip (already surfaced by earlier T-1/T-2/T-3 trigger) and emit Tracked artifacts: (already loaded earlier this session for {tag}) in the surfacing block. After loading, append loaded paths to the ledger. If ledger= is none or absent, skip the dedup and load.
f. Output. Extend the Step 9 surfacing block with a 4th line:
```
Tracked artifacts: CODEMAP directory + STITCH for {tag} ({N} / {M} days fresh)
```
Variants: CODEMAP directory only for single-repo (no STITCH); (no CODEMAP for {tag}) if missing; [STALE โ consider /codemap update] annotation; (already loaded earlier this session) if ledger-deduped; (none โ no project detected) if (a) returned nothing.
g. Carry-forward. The loaded artifacts become available to Steps 3+ โ particularly Step 3 (Enumerate Fixes; CODEMAP sections map changed files to features/responsibilities) and Step 3.5 (Evidence-Sourcing Pass; CODEMAP can validate that a fix actually touches the expected feature surface).
Skip Step 11 entirely if active_knowledge_surfacing: false (already gated above).
Step 1: Print the Anchor Block
Before producing any verdict, emit the anchor so the rest of the report can be traced to inputs:
Anchor:
Goal: <stated goal>
Mode: <auto-range | commit | range | pr | session | release | deployment>
Range: <commit range descriptor, e.g. v0.4.2..HEAD, 12 commits, 38 files>
Tickets: <ABC-123 (Acceptance: ...), ABC-456 (...) | (none) | (unavailable)>
Outcome: <user-supplied per-fix status table | (untested) | (per-session โ no deploy)>
Step 2: Load Pattern Libraries
Read the canonical pattern library at <knowledge_folder>/rules/retrospect-patterns.md (resolved per ~/.gemini/antigravity/aria-knowledge.local.md knowledge_folder).
If the bundle is detected to belong to a known project (commits include paths under a configured projects_list[<tag>].project_root), additionally read <knowledge_folder>/projects/<tag>/retrospect-patterns.md if it exists.
Hold both pattern lists in context for use in ยง4.4 (Failure-Mode Pattern Check). Do not run pattern detection yet โ this step is just loading.
Step 3: Enumerate Fixes & Preliminary Triage
For the loaded bundle, enumerate each fix. A fix is one of:
- A commit whose message describes a fix or change (
fix:,feat:,refactor:, etc.) - A logical sub-change within a multi-concern commit (rare; usually 1 commit = 1 fix)
Number them #1, #2, โฆ in commit order. For each fix, capture:
- Short SHA
- Subject line
- Files touched (path list)
- LOC added/deleted
- Preliminary Bundle-verified? โ provisional โ verified / ๐คท unverified / N/A (session mode). Use the user-supplied evidence from Step 0 #3 as a starting point. Step 3.5's bundle-marker pass will attempt to upgrade ๐คท by sourcing the deployed bundle.
- Preliminary Validated? โ provisional classification using the Step 5 taxonomy (โ / โ partial / โ / โ / ๐ซ). Use the user-supplied post-deploy outcome from Step 0 #3 as the starting point. Step 3.5's outcome pass will attempt to upgrade โ /โ/๐ซ by sourcing post-deploy evidence (logs, repro tests, ticket comments). These are DRAFT values โ the FINAL Validated? values emitted in ยง4.3 reflect post-Step-3.5 state.
If session scope, enumerate by file-touch sets that resolve a single concern (Claude's judgment from session context). Preliminary Bundle-verified? = N/A and Preliminary Validated? = ๐ซ unvalidatable (no deploy yet).
After preliminary triage, list every fix whose Preliminary Bundle-verified? is ๐คท โ these are candidates for Step 3.5's bundle-marker pass. Separately, list every fix whose Preliminary Validated? is โ partial / โ unvalidated / ๐ซ unvalidatable โ these are candidates for Step 3.5's outcome pass. โ Invalidated fixes skip Step 3.5 (they go directly to REVERT/REDO-MINIMAL in ยง4.3 unless the user contests the falsification). โ Validated fixes also skip Step 3.5 (already confirmed).
Step 3.5: Evidence-Sourcing Pass
Two sub-passes that run in order before the report is rendered. Goal: convert as many ๐คท / โ / โ / ๐ซ candidates from Step 3 to โ or โ as possible before ยง4.2 emits its bundle-verification verdict and ยง4.3 emits its per-fix Validated? verdict.
This step can be skipped with the --no-source flag for a quick structural review. When skipped, all preliminary statuses pass through to ยง4.2 and ยง4.3 unchanged and ยง4.10 lists every gap as NOT-ATTEMPTED.
The synchronous-barrier discipline applies: if a sub-pass surfaces a USER-INPUT ask, hold for response. Default to one ask at a time unless the user asks for a batch.
3.5.1: Bundle-Marker Sub-Pass (resolves ๐คท)
For each fix from Step 3 with Preliminary Bundle-verified? = ๐คท, attempt to confirm the fix's code is present in the deployed bundle.
Auto-source candidates (most retrospects fall here):
- Bundle fetch + grep โ
Bash curl -s -o '<new scratch file>' '<deployed-bundle-url>', thenBash grep -cF -e '<unique-marker-string>' '<new scratch file>'(a URL or marker holding', a backtick or$goes through WebFetch instead). The unique marker is either a function name from the diff, a comment string the fix added, or a[<TAG>-DIAG]instrumentation marker. Source the deployed-bundle-url from the user (Step 0) or from common conventions (<deploy-domain>/static/js/main.<hash>.jsfor Vercel/Webpack builds). - WebFetch on bundle URL โ same as above but via
WebFetchwhen the URL is public and HTML-wrapped. - CI artifact check โ
Bash gh run view <run-id> --log(resolved from the commit's CI status) โ confirm the deploy job ran AND the artifact hash matches. - Source-map verification โ fetch the deployed source-map, confirm it references the post-fix line numbers.
- Deploy log inspection โ Vercel logs MCP, Bitbucket pipeline output via
gh api, etc.
USER-INPUT escape hatch:
- If no bundle URL is known and the user hasn't provided one, ask: "Need a deployed-bundle URL or unique in-bundle marker for fix #N (<short-sha>: <subject>) to verify it shipped. Provide URL+marker, paste a curl-grep result, or skip (fix stays ๐คท)."
Record per fix using the same shape as /prospect's 3.5.2:
Fix #N โ bundle-marker result:
Question: Did fix #N's code reach the deployed bundle?
Tool used: <Bash curl <url> | WebFetch <url> | gh run view <id> | mcp__vercel__get_logs | ASK <surfaced-to-user>>
Finding: <one-paragraph factual summary, with URL anchor or grep hit>
Verdict: UPGRADED-TO-โ
verified | UPGRADED-TO-โ NOT-IN-BUNDLE | NO-MOVEMENT-CAPABILITY | NO-MOVEMENT-STRUCTURAL | INCONCLUSIVE
New Bundle-verified?: <updated tag>
When this sub-pass completes, every fix has a final Bundle-verified? value (โ verified / ๐คท unverified / โ not-in-bundle). ยง4.2 emits this state directly. โ NOT-IN-BUNDLE is a strong signal โ the fix definitively did not ship; its action defaults to REVERT or RESHIP-AND-VERIFY in ยง4.3.
3.5.2: Outcome Sub-Pass (resolves โ partial / โ unvalidated / ๐ซ unvalidatable)
For each fix from Step 3 with Preliminary Validated? = โ / โ / ๐ซ AND Bundle-verified? โ ๐คท (a fix that didn't ship can't be outcome-validated), attempt to confirm the fix's outcome in production.
Generate the decisive question โ what observable evidence would change the verdict from โ /โ/๐ซ to โ Validated or โ Invalidated? Format:
Fix #N: <subject>
Preliminary Validated?: <โ /โ/๐ซ>
Decisive question: <one-line โ "what observable evidence would close this?">
Answer source: AUTO-SOURCEABLE | USER-INPUT | MIXED
Sourcing plan: <tools/queries to run>
Auto-source candidates (retrospect-specific):
- Production log queries โ
mcp__vercel__get_logs,mcp__supabase__get_logs,Bash gh run view, log-tail via SSH. Look for: (a) absence of the error event the fix targeted, (b) presence of the success event, (c) post-deploy regression signals. - Ticket comments โ via whichever project-tracker MCP is connected (Linear, Jira/Atlassian, Asana, Monday, ClickUp, Notion-as-tracker, GitHub Issues), using that server's list-comments verb โ e.g.
mcp__linear__list_comments <ticket-id>on Linear. Probe for what is actually connected rather than assuming a vendor; skip this source if none is. For any ticket cited in commit messages. QA, support, and product comments often record post-deploy outcome ("verified fixed in PROD," "still reproducing," etc.). High-signal source. - Repro test execution โ if the bug had a documented repro and the test infrastructure is local, run it:
Bash <test-command>(read-only or sandboxed). NEVER run repro tests that mutate production data. - GH commit/check status โ
Bash gh api repos/<owner>/<repo>/commits/<sha>/check-runsโ CI green / red post-fix. - Web fetch on monitoring dashboards โ only if URLs are known and public (rare; usually demoted to USER-INPUT).
git logon the touched files since deploy โ if other commits have already modified the same lines after the fix, that may constitute a regression signal.
USER-INPUT escape hatch (and when to demote to it):
- Reproduction tests that require staging access, real user accounts, or interactive QA โ demote.
- Subjective acceptance ("does this feel fast enough now?") โ demote.
- Anything requiring credentials Step 3.5 doesn't have authorization to use โ demote.
Surface format mirrors /prospect's 3.5.3 exactly:
[ASK #M of K] Fix #N โ <subject> (<short-sha>)
Why this matters:
<one-line โ what changes about Fix #N's verdict if we know this>
What I tried autonomously (if MIXED):
<one-line โ e.g., "Queried Vercel logs since deploy; found 0 occurrences of the targeted error and 4 of an adjacent error. Ambiguous โ need your read on whether the adjacent one is a regression.">
Citations / context inline:
<log excerpts, ticket comment quotes, test output โ whatever the answer depends on>
Options:
1) <option, with one-line consequence>
2) <option, with one-line consequence>
3) Other โ describe in reply
4) Skip โ leave fix #N at <preliminary status>; it will HOLD-PENDING-EVIDENCE in ยง4.10
Same rules as /prospect's 3.5.3: neutral framing, separate Recommendation line allowed below options, per-question explicit pick, bare-number replies pick, "Skip" defaults to HOLD-PENDING-EVIDENCE / HOLD-PENDING-DEPLOY / HOLD-PENDING-VERIFICATION as appropriate.
Record per fix:
Fix #N โ outcome result:
Question: <repeat decisive question>
Tool used: <listed>
Finding: <factual summary with citations>
User pick (if any): <option N | "skip" | "other: <text>">
Verdict: UPGRADED-TO-โ
Validated | UPGRADED-TO-โ partial | UPGRADED-TO-โ Invalidated | NO-MOVEMENT-CAPABILITY | NO-MOVEMENT-STRUCTURAL | INCONCLUSIVE
โ A no-movement verdict MUST pick one of the two โ in both sub-passes (3.5.1 bundle-marker and 3.5.2 outcome). They respond to a better pass in opposite directions, so a pooled tally cannot be interpreted later: a falling unresolved rate becomes indistinguishable from a shift in what kind of claims the range happened to contain.
NO-MOVEMENT-CAPABILITYโ you attempted it and could not settle it from reachable inputs: ran out of search paths, time-boxed out, sources disagreed, the trace got too deep. A more capable or less constrained pass could plausibly settle it from the same inputs.NO-MOVEMENT-STRUCTURALโ the answer is not in reachable inputs at all: needs a live deploy or served-artifact read, a running system, production data, a device, or a named human's confirmation. No amount of reasoning settles it. This is the common case for a bundle marker whose only oracle is the deployed bundle.
โ Classify at the moment you stop, while you still know why you stopped โ not afterwards from the residual's Attempt status label. Measured 2026-08-22 across 5 such entries, 3 were mislabelled: they carried ATTEMPTED-FAILED while describing an on-device recording, a package fetch, and an SSH read of a live box.
New Validated?: <updated tag with sub-tag where applicable>
3.5.3: Constraints (apply to both sub-passes)
- Rule 33 โ verify against current docs: When sourcing third-party API/SDK behavior post-deploy, read the official current docs.
- No credential reads without explicit per-session permission.
- No destructive probes โ read-only commands only. No
rm,git reset,git push,gh pr merge, no migration runs, no PROD writes of any kind. - No PROD-mutating repro tests โ if a repro requires writing to production data, demote to USER-INPUT.
- Time-box per fix: ~5 tool-call rounds maximum per decisive question. INCONCLUSIVE after that; demote residual to USER-INPUT.
- Evidence quality bar: a single corroborating source upgrades only to โ partial (with sub-tag
closed-part-of-target). Two independent sources required for โ Validated. One contradicting authoritative source falsifies to โ.
3.5.4: Pass Summary
When both sub-passes complete, emit a one-block summary before moving to Step 4:
Evidence-Sourcing Pass complete.
Bundle-marker sub-pass (ยง3.5.1):
Candidates examined: <N>
Upgraded to โ
verified: <N>
Upgraded to โ not-in-bundle: <N>
No movement (still ๐คท): <N>
Skipped by user: <N>
Outcome sub-pass (ยง3.5.2):
Candidates examined: <N>
Upgraded to โ
Validated: <N>
Upgraded to โ partial: <N>
Upgraded to โ Invalidated: <N>
No movement (still โ /โ/๐ซ): <N>
Skipped by user: <N>
Total tool calls: ~<N>
Skipped by --no-source: <N> (entire pass)
The post-pass values feed ยง4.2 (Bundle-verified?) and ยง4.3 (Validated?). The residual ๐คท / โ / โ / ๐ซ plus their attempt-status feed ยง4.10.
Step 4: Produce the 10-Section Retrospective Report
Render a markdown document with the 10 sections below in order. Each section heading uses ### N. <title> format. Sections that don't apply to the current scope are emitted with a one-line "N/A: <reason>" โ never silently skipped.
4.1. Section 1 โ Anchor & Inputs
Re-emit the anchor block from Step 1, verbatim, as Section 1 of the report. This makes the report self-contained when read outside the chat.
4.2. Section 2 โ Bundle-Verification Gate
For each fix from Step 3, emit the post-Step-3.5.1 Bundle-verified? status. ยง4.2 is the bundle-deployment ledger; its values come directly from Step 3.5.1's Bundle-Marker Sub-Pass, which already attempted to source the marker autonomously and surfaced any USER-INPUT asks that were needed.
Three possible statuses per fix:
- โ
Verified โ bundle contains the fix's marker. Evidence comes from one of: unique in-bundle marker grep on the deployed asset (e.g.,
curl https://<deployed-url>/<bundle> | grep <marker>), deploy log + bundle hash matching the commit's CI artifact, or source-map verification. Step 3.5.1's "Tool used" + "Finding" cite the source. - ๐คท Bundle-unverified โ Step 3.5.1 attempted to source the marker but could not confirm. Reasons captured from 3.5.1's verdict (NO-MOVEMENT, INCONCLUSIVE, or DEFERRED-BY-USER). Fix does NOT receive a Validated? status in ยง4.3 โ its action defaults to HOLD-PENDING-VERIFICATION and ยง4.10 will list the residual evidence ask.
- โ Not-in-bundle โ Step 3.5.1 positively confirmed the fix did NOT ship (e.g., bundle returned 200 but the marker grep was empty, OR the deploy log shows a failed/superseded job). This is a strong signal: the fix's action defaults to RESHIP-AND-VERIFY (REDO-MINIMAL bound to a re-deploy) or REVERT (if the fix was a refactor whose absence isn't blocking) in ยง4.3. Validated? is N/A (can't validate code that didn't ship).
Render as a clear list per fix:
Fix #N: <subject> (<short-sha>) โ <โ
Verified | ๐คท Bundle-unverified | โ Not-in-bundle>
Source: <Step 3.5.1 tool/finding citation, e.g., "curl <url> | grep '[CSB-DIAG-042]' โ 1 hit">
(For ๐คท) Reason: <Step 3.5.1 verdict tag>
(For โ) Implication: <RESHIP-AND-VERIFY or REVERT, deferred to ยง4.3 action>
If the scope is session, this section emits "N/A: session scope (no deploy yet)." Step 3.5.1 is also a no-op in this scope.
4.3. Section 3 โ Per-Fix Verdict
For each fix from Step 3 that passed ยง4.2 (bundle verified or session mode), emit a horizontal-rule-separated block with these fields. Mirror the formatting style of the baseline review tag taxonomy (โ , โ partial, โ over-engineered, โ theory-wrong, โ counterproductive).
Required fields:
- Status tag โ one of โ / โ partial / โ over-engineered / โ theory-wrong / โ counterproductive
- Necessary? โ YES / NO / UNCLEAR with one-sentence reason
- Complications introduced โ concrete list, or "None"
- Minimal alternative โ "the smallest version of this change that would have addressed the goal." If the actual fix is the minimal version, write "This is the minimal version." Forces Rule 13.
- Maintenance cost โ "what future contributors must now know / maintain because of this change." Forces Rule 12 / Rule 14.
- Validated? โ one of the 5 statuses from Step 5, post-Step-3.5.2. The Step 3.5.2 outcome sub-pass had its chance to upgrade this from the preliminary value emitted in Step 3; this field reflects the FINAL state. Use ๐คท if ยง4.2 flagged the fix Bundle-unverified (Step 3.5.2 doesn't run on those โ outcome can't be validated for code that didn't ship). Use N/A if ยง4.2 emitted โ Not-in-bundle.
- Action โ one of: KEEP / REVERT / REDO-MINIMAL / RESHIP-AND-VERIFY / FOLLOWUP-TICKET / HOLD-PENDING-EVIDENCE / HOLD-PENDING-DEPLOY (session scope only) / HOLD-PENDING-VERIFICATION (bundle-unverified only). RESHIP-AND-VERIFY is for โ Not-in-bundle fixes whose code is correct but didn't ship โ re-deploy and re-run /retrospect after.
Optional fields:
- Evidence sourced โ when Step 3.5.2 produced a verdict-changing finding, summarize it in one line with citation. Example: "Auto-sourced via mcpvercelget_logs since deploy 2026-05-04 โ 0 occurrences of error E_FOO; upgraded โโโ ." If Step 3.5.2 produced no movement OR was skipped, omit this field.
- Rule cite โ if a complication maps to a Universal Rule overstep, cite it inline (e.g., "violates Rule 14 โ abstraction beyond purposeful layers")
Render each fix as a block, not a wide table:
Fix #N: <subject> (<short-sha>)
Status: <tag>
Necessary?: <YES/NO/UNCLEAR> โ <reason>
Complications: <list or None>
Minimal alternative: <description>
Maintenance cost: <description>
Validated?: <status> (post-Step-3.5.2)
Evidence sourced (optional): <one-line with citation>
Action: <action>
Rule cite (optional): <rule>
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Hard rule (action gating):
- KEEP requires post-Step-3.5.2 Validated? of โ or โ partial.
- โ Unvalidated โ HOLD-PENDING-EVIDENCE (forces ยง4.10 residual ask).
- ๐ซ Unvalidatable โ HOLD-PENDING-DEPLOY (session scope) or HOLD-PENDING-EVIDENCE (otherwise).
- ๐คท Bundle-unverified (ยง4.2) โ HOLD-PENDING-VERIFICATION (Step 3.5.1 already attempted; user must verify).
- โ Not-in-bundle (ยง4.2) โ RESHIP-AND-VERIFY (default) or REVERT (only if fix was non-blocking refactor that's safer to drop than re-ship).
- โ Invalidated (ยง4.3) โ REVERT or REDO-MINIMAL (per the smallest-alternative analysis).
The hard rule mirrors /prospect's discipline: actions cannot upgrade past their evidence floor. Step 3.5 has already attempted to lift evidence floors; what remains is genuine residual uncertainty that gates action selection.
4.4. Section 4 โ Failure-Mode Pattern Check
Run the bundle against both pattern libraries loaded in Step 2 (canonical + project-specific if applicable). Detection is judgment-based โ read each pattern's "Detection cues" and assess whether the bundle, commit messages, or session transcript exhibits them.
For each pattern hit, emit:
[PATTERN] <pattern-name> (source: rules/retrospect-patterns.md | projects/<proj>/retrospect-patterns.md)
Evidence: <what in the bundle/transcript triggered the hit>
Counter-discipline: <one-line reminder of the pattern's counter-discipline>
If no patterns hit, emit: "No catalogued failure-mode patterns detected. (See ยง9 for novel patterns.)"
4.5. Section 5 โ Cross-Change Tally
Emit raw counts only โ no interpretation in v1.
Tally:
Fixes shipped: <N>
Validated (โ
): <N> (post-Step-3.5.2)
Partially validated (โ ): <N> (post-Step-3.5.2)
Invalidated (โ): <N> (post-Step-3.5.2)
Unvalidated (โ): <N> (post-Step-3.5.2)
Unvalidatable (๐ซ): <N> (post-Step-3.5.2)
Bundle-verified (โ
): <N> (post-Step-3.5.1, ยง4.2)
Bundle-unverified (๐คท): <N> (post-Step-3.5.1, ยง4.2)
Not-in-bundle (โ): <N> (post-Step-3.5.1, ยง4.2)
Theory-driven refactors: <N>
Required by ticket acceptance: <N>
Discovered-during-process: <N>
Pattern hits this run: <N>
Evidence-Sourcing Pass โ bundle-marker sub-pass (ยง3.5.1):
Candidates examined: <N>
Upgraded to โ
verified: <N>
Upgraded to โ not-in-bundle: <N>
No movement (still ๐คท): <N>
Skipped by user: <N>
Evidence-Sourcing Pass โ outcome sub-pass (ยง3.5.2):
Candidates examined: <N>
Upgraded to โ
Validated: <N>
Upgraded to โ partial: <N>
Upgraded to โ Invalidated: <N>
No movement (still โ /โ/๐ซ): <N>
Skipped by user: <N>
Sourcing pass overall:
Total tool calls: ~<N>
Skipped by --no-source: <N> (entire pass)
A "theory-driven refactor" is a fix that rewrote working code based on a hypothesis rather than a confirmed bug location. Discovered-during-process means the fix addresses a bug found while working on something else (not the original goal).
Interpretation of these counts is left to ยง4.6, ยง4.7, and ยง4.9.
4.6. Section 6 โ Re-frame Check
Three questions, in order. Answer each in 1โ2 sentences with the supporting evidence.
- Is the original problem statement still right? Or did the bundle reveal that the user-reported bug is a different bug than the bundle was aimed at?
- Was the bug correctly scoped? Single bug, or multiple bugs presenting as one?
- Is the user-reproducible scenario still the right test? Or has the testing surface drifted?
If the answer to #1 is "no," explicitly note: "Re-frame triggered. Hold all fixes targeting the previous problem statement pending re-diagnosis (ยง4.7)."
4.7. Section 7 โ Re-diagnosis
List the surviving hypotheses for the actual root cause (only run this section if any fix's post-Step-3.5.2 Validated? is โ Invalidated or โ partial, OR ยง4.6 triggered re-frame). For each hypothesis:
Hypothesis: <one-line statement>
Used by fixes: <#1, #3, #5>
Evidence FOR: <observations consistent with this hypothesis โ INCLUDE Step 3.5.2 sourced findings with citations>
Evidence AGAINST: <observations inconsistent โ INCLUDE Step 3.5.2 sourced findings>
Sourcing attempted: <YES (see Step 3.5.2 result for fixes #N) | NO (auto-sourcing skipped, declined, or not categorized as auto-sourceable)>
Confidence: LOW / MEDIUM / HIGH
To confirm: <specific signal to look for โ feeds ยง4.10>
Evidence FOR/AGAINST must integrate any findings from Step 3.5.2's outcome sub-pass. If Step 3.5.2 produced a finding that moved a fix to โ partial (e.g., closed-part-of-target upgrade from โ), cite that finding here as Evidence FOR the partial-success hypothesis AND as Evidence AGAINST the full-fix-worked hypothesis. If Step 3.5.2 produced a contradicting finding the user contested or overrode, note both perspectives.
Discarded hypotheses (ones the bundle's outcomes OR Step 3.5.2's sourcing proved wrong) are listed separately under "Hypotheses ruled out by this retrospective or sourcing pass" with one-line reasons and source citations where applicable. This is learning, not waste โ captures what was considered AND what evidence retired it.
If all fixes are post-Step-3.5.2 โ validated and ยง4.6 didn't trigger, this section emits "N/A: all fixes validated (Step 3.5.2 closed all gaps)."
4.8. Section 8 โ Action Verdict
Per fix, the action determined in ยง4.3. Render as a clear list:
Action verdict:
Fix #1: <ACTION> โ <one-line reason>
Fix #2: <ACTION> โ <one-line reason>
...
For REVERT actions, provide the exact git revert <sha> command. For REDO-MINIMAL actions, provide the minimal alternative diff (from ยง4.3). For FOLLOWUP-TICKET actions, draft a ticket title + Product/Technical Intake skeleton. For RESHIP-AND-VERIFY actions (introduced when ยง4.2 emitted โ Not-in-bundle), provide: (a) the re-deploy command appropriate to the project (gh workflow run deploy.yml --ref main, vercel --prod, project-specific deploy script โ pick from aria-config.md's projects_list[<tag>] if present, otherwise prompt user), and (b) a one-line directive: "After re-deploy, re-run /retrospect deployment to confirm the bundle now contains the fix and validate outcome."
End with an Overall recommendation in 1โ3 sentences.
4.9. Section 9 โ Process Retrospective
What the prior decision-making should have done differently. Format per item:
What I did: <observed behavior>
What I should have done: <better behavior>
Trigger condition: <how to detect this situation in the future>
Pattern reference: <pattern-name from library | (novel)>
If a behavior matches an existing pattern in the library, cite it. If a behavior is novel (not in either pattern library), prompt the user:
"Identified a new failure-mode pattern:
<pattern-name>. Add to:
1) Canonical (
rules/retrospect-patterns.md) โ applies project-agnostic
2) Project-specific (
projects/<proj>/retrospect-patterns.md)
3) No โ surface in this report only
Choose: "
If user chooses 1 or 2, append a new entry to the corresponding file using the format defined in rules/retrospect-patterns.md ("Pattern entry format" section). The new entry's "First identified" field is today's date and the current retrospective's filename.
4.10. Section 10 โ Next-Step Evidence Ask (Residual)
Anti-speculation barrier. This section lists ONLY the residual evidence asks โ the questions Step 3.5 either could not source autonomously, the user deferred, or were not attempted. Items resolved during Step 3.5 (โ
upgrades, โ partials with Step 3.5.2 evidence, or โ falsifications) DO NOT appear here โ they're recorded in ยง4.3 (Evidence sourced field), ยง4.7 (Evidence FOR/AGAINST), and ยง4.5 (Evidence-Sourcing Pass tally blocks).
For each remaining ๐คท / โ / โ / ๐ซ fix, emit the residual ask with its attempt-status:
For Fix #N (<subject>) โ current status: <๐คท / โ partial / โ / ๐ซ>
Attempt status: NOT-ATTEMPTED | ATTEMPTED-FAILED | DEFERRED-BY-USER | SKIPPED-BY--no-source
Sub-pass: BUNDLE-MARKER (ยง3.5.1) | OUTCOME (ยง3.5.2)
Why residual: <one-line โ e.g., "Auto-source attempted via Bash curl <bundle-url>; URL returned 403. Demoted to USER-INPUT; user picked Skip.">
What's needed: - <specific instrumentation step 1 โ log query, repro test, ticket comment, deploy log inspection, etc.>
- <specific instrumentation step 2>
- <add a unique [<TAG>-DIAG] marker so deployment verification is possible>
Who can resolve: <USER | AUTOMATED-RETRY-LATER (e.g., re-query logs after 1h) | EXTERNAL-PARTY <name> (e.g., QA team, customer report)>
Then group the residual asks by surviving hypothesis (from ยง4.7) so the user can see which hypothesis each piece of evidence would advance:
To confirm Hypothesis A (<short label, from ยง4.7>):
- Fix #N residual: <one-line>
- Fix #M residual: <one-line>
To confirm Hypothesis B (<short label>):
- ...
Attempt-status meanings (mirror /prospect's ยง4.10):
- NOT-ATTEMPTED โ Step 3.5 did not generate a sourcing plan for this question (rare; usually means a misclassified candidate).
- ATTEMPTED-FAILED โ Step 3.5 ran tools but the answer wasn't found / source was unreachable / two corroborating sources couldn't be obtained / log time window had no signal.
- DEFERRED-BY-USER โ Step 3.5 surfaced a USER-INPUT ask and the user picked "Skip".
- SKIPPED-BY--no-source โ entire pass was skipped via the
--no-sourceflag.
If all fixes are post-Step-3.5 โ Validated and ยง4.2 emitted โ Verified for all, emit: "N/A: all fixes validated and bundle-verified (Step 3.5 closed all gaps). Proceed to next work."
If Step 3.5 was skipped via --no-source, prefix every entry with "(Sourcing pass skipped โ re-run /retrospect <scope> without --no-source to attempt autonomous resolution.)"
End the section with this verbatim warning:
Do not ship another speculative fix until at least one item in this section is satisfied. If a new fix is proposed without new evidence, re-run
/retrospect.
Step 5: Validation Status Taxonomy (reference)
When assigning Validated? in ยง4.3, choose one of the 5 statuses below. Bundle-unverified (๐คท) is a precondition gate handled in ยง4.2, not a status.
| Status | Definition | Required sub-tag (in report) |
|---|---|---|
| โ Validated | Evidence shows the fix achieved its stated goal in the deployed state | Evidence type: log event \| reproduction-then-fix-verified \| production instrumentation \| deployed-state check. "Code review confirmed" is not validation. |
| โ Partially validated | Evidence shows the fix changed something, but didn't fully close the bug | Sub-tag: closed-part-of-target \| closed-different-bug |
| โ Invalidated | Evidence shows the fix did NOT close the bug, or introduced a regression | Sub-tag: didnt-fix \| introduced-regression |
| โ Unvalidated โ evidence requestable | No evidence yet, but the skill can describe the specific test/check that would validate | (none) |
| ๐ซ Unvalidatable | Cannot be validated from current vantage point (requires production traffic, edge case not yet reproduced) | (none) |
When emitting a Validated? value, always include the required sub-tag where applicable. Examples:
Validated?: โ Validated (log event: apify_schema_mismatch confirmed absent post-deploy)Validated?: โ Partially validated (closed-part-of-target: rehost cap raised but profile-image source still missing)Validated?: โ Invalidated (didnt-fix: bug reproduces on test #3)Validated?: โ Unvalidated โ evidence requestable: needs <specific check>Validated?: ๐ซ Unvalidatable: requires production traffic to surface
Step 6: Write Outputs
After Step 4 produces the report, write outputs to the configured destinations:
Always
- Render the full report to terminal (chat).
Default (configurable in `~/.gemini/antigravity/aria-knowledge.local.md` under `retrospect:` block โ to be added when needed)
- Persistent log: Write the full report to
<knowledge_folder>/logs/retrospect/<YYYY-MM-DD>-<scope>-<slug>.mdwhere<scope>is the resolved scope keyword from Step 0 (commit,range,pr,session,release,deployment, orauto-rangefor the no-args default) and<slug>is derived from the goal or referenced ticket(s). Resolve<knowledge_folder>from the config'sknowledge_folderfield. Create thelogs/retrospect/subfolder lazily on first use. Existing files written under the older<YYYY-MM-DD>-<slug>.mdpattern are grandfathered (no rename).
Prepend a structured YAML frontmatter block to the report before writing. Schema:
```yaml
type: retrospect
date: <YYYY-MM-DD>
scope: <commit | range | pr | session | release | deployment | auto-range>
goal: <one-line stated goal from ยง4.1 Anchor>
tickets: [<ABC-123>, <ABC-456>] # empty list if none
fixes_count: <N>
model: <model executing this gate, e.g. claude-opus-5 โ or unrecorded if unknown>
effort: <output of printf '%s\n' "${CLAUDE_EFFORT:-unrecorded}" โ run it, copy verbatim; never infer or guess>
sourcing_pass:
bundle_marker:
candidates: <N>
upgraded_verified: <N>
upgraded_not_in_bundle: <N>
no_movement: <N> # pooled total; MUST equal the two below
no_movement_capability: <N> # attempted, could not settle โ a better pass may resolve
no_movement_structural: <N> # needs a live deploy read / running system / a human
outcome:
candidates: <N>
upgraded_validated: <N>
upgraded_partial: <N>
upgraded_invalidated: <N>
no_movement: <N> # pooled total; MUST equal the two below
no_movement_capability: <N>
no_movement_structural: <N>
patterns_hit: [<pattern-name-1>, <pattern-name-2>] # from ยง4.4; empty list if none
overall_outcome: <closed | partial | unresolved | mixed> # derived from ยง4.5 tally + ยง4.8 overall recommendation
related: [<paths to overlapping prior runs โ see below>]
tags: [retrospect, <scope>, <project-tag-if-detected>, <pattern-tag-if-applicable>]
```
effort: is read, never inferred. Run printf '%s\n' "${CLAUDE_EFFORT:-unrecorded}" in Bash and copy the output verbatim. Where the runtime sets $CLAUDE_EFFORT (Claude Code does, in each Bash subprocess, to the effort level in effect when it starts; a subagent sees its own level), that output is the recorded level; where it is unset the command prints unrecorded โ record that rather than a guess. You cannot see your own effort setting (self-reported values disagreed with the harness record on 24% of 140 matched logs).
overall_outcome derivation: closed if every fix's post-Step-3.5 Validated? is โ
; unresolved if any fix is โ Invalidated or โ Not-in-bundle; partial if any fix is โ partial AND none are โ; mixed for any other combination.
related auto-detection (Q1.2=1, ticket-based): Before writing, glob <knowledge_folder>/logs/prospect/*.md AND <knowledge_folder>/logs/retrospect/*.md for files whose frontmatter tickets: array shares at least one ticket ID with the current report's tickets. Record their paths (relative to <knowledge_folder>/) in the related: array. If no tickets in the current report, leave related: empty. Cap at 10 most-recent overlaps.
tags: field: always includes retrospect and the scope keyword. Add a project tag when the bundle is detected to belong to a configured project (commits/files match a projects_list[<tag>].project_root). Add pattern-name tags for any ยง4.4 hits. These tags make the file discoverable via /index and /context (per Q1.3=1 โ /index extends its scan to logs/{prospect,retrospect}/).
- Aria intake: Suggest entries for the four backlogs based on the report content:
- Insights โ observations like "fix #N's theory was wrong because <evidence>"
- Decisions โ "Reverted fix #N; reapplied minimal version" with rationale
- Approaches โ instrumentation patterns that worked (e.g., "[<TAG>-DIAG] marker pattern for bundle verification")
- Working rules โ if ยง4.9 identified a behavior that should become a Universal Rule, suggest it (do not persist without user approval per Rule 23)
Project-scoped intake goes to projects/<proj>/; agnostic intake goes to the shared knowledge tree. Follow the standard aria intake confirmation flow (suggest, user reviews, write on approval).
Opt-in
- Tracker comment: Only when invoked with
--ticket-post(legacy alias--linear-post). Post a summary (the Overall recommendation from ยง4.8 + the action verdict list) to each ticket detected in commit messages. Use a project-tracker MCPsave_comment. Never post the full report โ too much detail for the ticket.
Pattern library write-backs
If ยง4.9 produced a novel pattern and the user approved adding it, the pattern entry is written to either:
<knowledge_folder>/rules/retrospect-patterns.md(canonical), or<knowledge_folder>/projects/<proj>/retrospect-patterns.md(project-specific)
Pattern write-backs are separate from intake โ they go directly to the patterns file, not through backlog review.
Step 7: Soft-Suggest Trigger Logic (Claude-side judgment)
When the skill is not directly invoked, Claude monitors user messages for cues that suggest a retrospective is warranted. When detected AND the current session has shipped recent fixes (commits in the last hour or since the last /retrospect), Claude offers โ never auto-executes โ /retrospect.
Cues (non-exhaustive, judgment-based):
- "still broken," "still happening," "didn't fix," "no change"
- "regression," "same outcome," "reproducing again," "same bug"
- The user shares a test session log, transcript, or repro evidence that indicates failure
- Audit-shaped requests: "review what you did," "audit the changes," "are these necessary," "what did you change"
Standard offer (paraphrase as appropriate):
"It sounds like the last release didn't fully close the bug. Before I propose another fix, want me to run
/retrospecton the change set first? That'll force a validation check + re-diagnosis pass before we ship anything new."
Cue weight is judgment, not regex. When the cue is faint, just acknowledge and proceed. When the cue is clear, offer. Never auto-execute from a cue โ always ask.
This logic also fires the pushback-as-cue pattern (see rules/retrospect-patterns.md) โ they share the same trigger surface.
Over-build lens (opt-in: `--lens=overbuild`)
Off unless --lens=overbuild is passed. When off, this skill behaves exactly as documented above โ zero behavior change. When on, after the standard per-fix pass, run one additional pass over the in-scope diff:
- Load the rubric. Read
rules/overbuild-patterns.md(sameknowledge_folder/template path used forretrospect-patterns.md). Hold the ladder + smell list. - Walk each diff hunk against the ladder, then the smell detection cues.
- Marker-respect. If a hunk carries an
aria:simplificationmarker matchingaria:simplification โ .+ | limitation: .+ | upgrade: .+, report it asresolved (marked)and do NOT flag it. An obvious simplification with NO marker is theunmarked-simplificationsmell. - Emit findings in the existing per-fix block style, each REQUIRING: the failed ladder rung, the matched smell name, and a concrete leaner alternative. A finding that cannot name the smaller version is suppressed (matches this skill's existing "name the smaller version or it's not a finding" discipline).
- Verdict mapping. Over-build findings map to the existing verdict vocabulary:
dependency-for-a-oneliner/framework-for-a-functionโ recommend revert-and-shrink;unmarked-simplificationโ recommend add-the-marker (not a revert).
Findings append to the report as an ### Over-build lens subsection; they never alter the non-lens verdicts.
Step 8: Validation Gates
Before finalizing the retrospective, verify:
- Anchor printed? ยง4.1 must contain Goal, Mode, Range, Tickets, Outcome lines. For
deploymentscope, must also include the resolved marker source (per Step 0's deployment-detection cascade). - Evidence-Sourcing Pass run (or explicitly skipped)? Step 3.5 must have addressed every preliminary ๐คท candidate (3.5.1 bundle-marker sub-pass) and every preliminary โ /โ/๐ซ candidate (3.5.2 outcome sub-pass) โ each must end with one of: UPGRADED-TO-โ / UPGRADED-TO-โ / NO-MOVEMENT / INCONCLUSIVE / DEFERRED-BY-USER / SKIPPED-BY--no-source. No silent skips. The pass summary (Step 3.5.4) must be emitted.
- Bundle-verification gate run? ยง4.2 must address every fix from Step 3 with one of three values (โ Verified / ๐คท Bundle-unverified / โ Not-in-bundle), reflecting post-Step-3.5.1 state. Each per-fix render must cite the Step 3.5.1 source.
- Per-fix verdicts complete? Every fix has all required fields (Status, Necessary?, Complications, Minimal alternative, Maintenance cost, Validated?, Action). Validated? values reflect post-Step-3.5.2 state. Missing field = incomplete report.
- Validation hard rule respected? No fix has Action: KEEP unless post-Step-3.5.2 Validated? is โ or โ partial. โ Not-in-bundle (ยง4.2) โ RESHIP-AND-VERIFY or REVERT. ๐คท Bundle-unverified โ HOLD-PENDING-VERIFICATION. โ/๐ซ โ HOLD-PENDING-EVIDENCE / HOLD-PENDING-DEPLOY. Verify the full hard-rule ladder from ยง4.3 before emitting.
- Pattern check ran? ยง4.4 must reference both pattern libraries (canonical + project-specific if applicable).
- Tally consistent? Counts in ยง4.5 must match the per-fix data in ยง4.3 (post-Step-3.5.2) and ยง4.2 (post-Step-3.5.1). The two
Evidence-Sourcing Passblocks in ยง4.5 must match Step 3.5.4's summary verbatim. - Hypotheses present when needed? ยง4.7 is required if any fix's post-Step-3.5.2 Validated? was โ Invalidated or โ partial, or ยง4.6 triggered re-frame. Evidence FOR/AGAINST must integrate Step 3.5.2 findings where applicable.
- Action verdict complete? ยง4.8 must have an action for every fix in ยง4.3. RESHIP-AND-VERIFY actions must include the project-appropriate re-deploy command + the re-run-/retrospect directive.
- Residual evidence asks correctly scoped? ยง4.10 must list ONLY residual items (NOT-ATTEMPTED / ATTEMPTED-FAILED / DEFERRED-BY-USER / SKIPPED-BY--no-source). Items resolved by Step 3.5 (โ upgrades, โ partials with ยง3.5.2 evidence, or โ falsifications) must NOT appear in ยง4.10. Cross-check: every ยง4.10 entry must have current status of ๐คท / โ / โ / ๐ซ.
- Outputs written? Confirm the persistent log was written to disk at
<knowledge_folder>/logs/retrospect/<YYYY-MM-DD>-<scope>-<slug>.md, with structured YAML frontmatter (type, date, scope, goal, tickets, fixes_count, sourcing_pass, patterns_hit, overall_outcome, related, tags) prepended. Confirm intake suggestions were surfaced. related:cross-refs computed? If the report contains tickets, therelated:frontmatter array must list overlapping prior runs (capped at 10) fromlogs/prospect/andlogs/retrospect/. If empty (no tickets), confirm the empty-list state explicitly.
If any check fails, self-correct once. If self-correction can't close the gap (e.g., the user must supply evidence), surface the gap explicitly in the report rather than silently skipping.