
walkthrough
Guided walkthrough of code, a diff/PR, architecture, tests, or docs — build the reader's mental model, explain the choices made and their tradeoffs, and critically evaluate the artifact. Use when the user wants to understand or audit something rather than change it. Adapts to expert vs learner; companion to the pair skill.
- Installs
- 142
- Last 24h
- —
- Trending rank
- —
- Security
- Not audited
Install
Works with every agent the skills CLI supports.
npx skills add https://github.com/davidlee/doctrine --skill walkthrough- 01
Install
Run the command in your project. The CLI asks which agents to install for.
- 02
Describe the task
Ask your agent for something this skill covers. It loads walkthrough automatically when relevant.
- 03
Review the result
The agent follows the SKILL.md steps, scripts and references bundled with the skill.
SKILL.md
The instructions your agent reads when the skill is triggered.
Walkthrough
Lead the user through an artifact so they genuinely understand it — and pressure-
test it as you go. You are a presenter-reviewer, not a narrator: surface the
choices, the tradeoffs, the risks, and where you'd push back. A walkthrough that
only describes is a worse cat.
Calibrate to expertise or you actively harm. Detailed remedial explanation helps a novice and hinders an expert (the expertise-reversal effect). Match the audience dial: scaffold the learner, skip straight to deltas and risk for the expert. Over-explaining to an expert is a failure, not thoroughness.
Covers any artifact: source, diff/PR, architecture, API, data model, tests, docs, build, deploy/ops flow, or a design doc.
Walkthrough has a dual identity: when understanding is the whole task, it is the governing activity itself; layered onto change work, it is a conduct posture over whatever stage governs. Same loop either way — but layered use never replaces the governing stage or its process.
Dials
Set by the user, else inferred, else defaults:
/walkthrough audience=expert depth=deep
- audience —
expert·mixed(default) ·learner— the governing dial.- expert: start from architecture, invariants, risk, deltas. Highlight non- obvious coupling, edge cases, operational consequences, alternatives. Compact. Assume they resolve local syntax/framework details themselves. Lead with "here's where I'd push back."
- learner: make tacit reasoning visible. Explain idioms at first use. Show a worked example before asking them to reason. Small checkpoints over lectures. Fade scaffolding as they demonstrate understanding.
- mixed: explain the system map, not every syntax detail; offer optional deeper dives; watch for signals to add rigor or scaffolding and re-calibrate.
- depth —
skim·guided(default) ·deep: how far down the important path you trace — headline map only, the main path, or every branch and invariant.
Loop
- Orient — artifact, the user's goal, audience, what they already know. Agree the budget: which paths get traced, what is out of scope, and when the walkthrough stops. A deep dive into a large system balloons without a stated stopping condition.
- Map — compact structure: entry points, components, data + control flow, dependencies, boundaries. The mental model before the details.
- Trace — walk the important path at the chosen depth. Prefer causal explanation: what happens, why, what depends on it, what breaks if it changes.
- Explain the choices — name the decisions the author/system made; give the likely motivation, the alternatives, the tradeoffs accepted.
- Challenge — see below.
- Check understanding — only when learning is a goal (see below).
- Record — close with: what's sound, what's questionable, what should
change, what's still uncertain. Then route what must outlive the session:
changes worth making re-enter the change loop (below); everything else
harvests per
lib:reference/harvest.md. A closing summary that lives only in chat evaporates — harvesting nothing is valid, but make it a decision, not a default.
Challenge
Always on, calibrated — the same posture as the pair skill. Raise a credible
concern on correctness, maintainability, security, performance, observability,
testability, scope, architectural fit, migration risk, brittle abstraction, or
misleading docs. When you do: name it, state the consequence, offer an
alternative, mark blocker vs preference. Don't litigate trivia.
Check understanding (learner / mixed only)
When the goal includes learning, use comprehension checks instead of just telling — they're how the model transfers, not a quiz:
- predict before reveal ("what must this variable hold before you read on?")
- compare-and-contrast two approaches
- "what breaks if this changes?"
- ask them to name an invariant, or why an alternative was rejected
Never gratuitous. A check that doesn't improve comprehension just slows the
session — cut it. For an expert audience, skip checks entirely.
Handoff to pair
When a walkthrough surfaces a concrete change worth making, hand off to the
pair skill to make it — preserving the current audience/depth as pairing
dials. Inverse too: pair hands back here when the user needs to understand what
changed, why a design was chosen, or how a subsystem behaves.
In a Doctrine repo the handoff target for a discovered change is /route, not
free pair edits — route picks the governing stage (slice/preflight/…), then you
pair within the resulting phase. A walkthrough must not become a governance bypass.
In a Doctrine repo (optional)
Portable; ignore elsewhere. Inside Doctrine, read entities via
doctrine <kind> show <ID> (both TOML and prose tiers) rather than raw files,
and treat /canon + memory as the authority on why a thing is the way it is.
Walking through to make a change still routes through the change loop, not free
edits. Harvest per lib:reference/harvest.md; the walkthrough-specific route:
closure-grade
findings on a reviewable artifact → /code-review and its RV ledger.
FAQ
What does the walkthrough skill do?
Guided walkthrough of code, a diff/PR, architecture, tests, or docs — build the reader's mental model, explain the choices made and their tradeoffs, and critically evaluate the artifact. Use when the user wants to understand or audit something rather than change it. Adapts to expert vs learner; companion to the pair skill.
How do I install walkthrough?
Run npx skills add https://github.com/davidlee/doctrine --skill walkthrough in your project. The skills CLI detects the agents you use and copies the skill into the right folder. For Claude Code you can also place the skill folder at ~/.claude/skills/walkthrough/ (personal) or .claude/skills/walkthrough/ (project).
Which AI agents can use walkthrough?
Any agent that supports the open Agent Skills format (a folder with a SKILL.md file), including Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, Windsurf, Cline, OpenCode and more.
Is walkthrough safe to install?
No partner security audit is available yet. Skills can run commands and scripts, so read the SKILL.md and any bundled files before installing.
Who maintains walkthrough?
It is published by davidlee in davidlee/doctrine. It has 142 recorded installs.
More from davidlee/doctrine
code-review
davidlee/doctrine
Use whenever reviewing code for quality and correctness — a diff, PR, module, or subsystem — producing verified, severity-ranked findings on the RV ledger. Not for comprehension tours (walkthrough) or doctrine-conformance hunts (inquisition, user-invoked only).
pair
davidlee/doctrine
Agentic pair programming — drive a change together with a human partner in the loop, narrating intent and pausing at decision points. Use when the user wants to work side-by-side rather than hand off a whole task. Calibrated by three dials (role, detail, autonomy) and an always-on challenge mandate.
consult
davidlee/doctrine
Use the moment you hit an unanticipated obstacle, a decision with competing tradeoffs, or emergent complexity mid-task — before adapting planned scope, adding a dependency, taking a shortcut, or making any impactful concession on your own.
handover
davidlee/doctrine
Use when handing work to a fresh context — first bring the durable harvest current, then emit a continuation at one of two weights — a printed continuation prompt (light) or a handover.md context packet (full). Use whenever a fresh agent would more efficiently continue.
canon
davidlee/doctrine
Use before making architectural or workflow choices, when correctness depends on project governance, or when entering an unfamiliar subsystem — to load the project's authoritative rules before you act on assumptions.
retrieve-memory
davidlee/doctrine
Use before making non-trivial assumptions — before touching a subsystem you have not this session, before running or changing a command pipeline, when code and docs conflict, when asked "what is the right way here?", when debugging a recurring failure, or when about to answer with "probably/usually/likely".
Popular code quality & workflow skills
grill-me
mattpocock/skills
A relentless interview to sharpen a plan or design.
improve-codebase-architecture
mattpocock/skills
Scan a codebase for deepening opportunities, present them as a visual HTML report, then grill through whichever one you pick.
handoff
mattpocock/skills
Compact the current conversation into a handoff document for another agent to pick up.
domain-modeling
mattpocock/skills
Build and sharpen a project's domain model. Use when discussing codebase terminology, writing or editing a GLOSSARY.md, or recording or editing an ADR.
codebase-design
mattpocock/skills
Shared vocabulary for designing deep modules. Use when the user wants to design or improve a module's interface, find deepening opportunities, decide where a seam goes, make code more testable or AI-navigable, or when another skill needs the deep-module vocabulary.
diagnosing-bugs
mattpocock/skills
Diagnosis loop for hard bugs and performance regressions. Use when the user says "diagnose"/"debug this", or reports something broken/throwing/failing/slow.