Docent pr
Point it at anything — a codebase, a PR, an essay, a paper, a URL — and get back a narrated, animated film that argues for what it explains. A closed grammar of explanation rendered by a coding agent, judged before it ships.
npx -y skills add benelser/docent --skill docent-prAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- 5 stars5 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
What its author says it does
Copied from the file, not written here
Render a PR-review film — a pull request reviewed the way a principal engineer would, with the load-bearing 5% surfaced, the trade-off named, and a verdict. Use when the user says "/docent-pr <repo> <pr-number>", asks to "review PR #N", "make a film about this PR", or hands over a GitHub PR URL and expects an artifact. The killer case is the sprawling AI-agent PR no human reads as a wall of text.
SKILL.md
5.9 KB, as published. Nobody here has run it
docent-pr — the PR-review film
You are running the entire docent cascade in PR-review mode against a pull request the user named: survey → treatment → spec → tts → clips → render → open. The output is one MP4 that explains the change the way a principal engineer would: why it exists, whether the design is sound, the core before → after, what ripples, what could break, and a verdict.
Arguments
/docent-pr <repo> <pr-number> [--id X] [--scale S] [--no-open]
<repo>— a repo path, a GitHub URL (https://github.com/owner/name), or the bareowner/nameform.<pr-number>— the pull-request number to review. Can be123or#123. If the user pasted a full PR URL as<repo>, extract both.--id X— override the auto-derived film id (default:<repo-name>-pr).--scale S— render scale. Default1. Pass0.5for fast turnarounds.--no-open— render without opening the result in the system player.
What to do
-
Pre-flight. Confirm
bun,ffmpeg, and the agent CLI (claudeorcodex) are on PATH. If anything obvious is missing, suggest/docent-doctorand stop. -
Survey — PR mode:
docent survey <repo> --mode pr --pr <n> [--id X]The survey lands at
analysis/<id>.md. Surface the path and the load-bearing finding (section 1 of the survey — the triage) before moving on. A PR survey's job is triage: of the diff, what is the load-bearing 5% — that you review with depth — and what is the rest you explicitly deprioritized. -
Commit to a style. Before the treatment, decide the visual register the film renders in:
bun run docent style recommend <id>For PR films the recommender will almost always return engineering — code-heavy, the dark console look. Take the recommendation unless the survey surfaces something exceptional (an exec-level retrospective of a release-blocking PR, for instance, may want executive). Surface the choice to the user in one line — "rendering in engineering — the load-bearing 5% is in
pkg/scheduler/...; rationale: file-level code review." — and move on. The spec compilation reads this off the survey's "Style commitment" section and pins it as the spec'sstyle: {preset, intent, rationale}field. The depth-review judge fails thestyle-committeddimension if the spec ships without it.
3b. Commit to a scene set. Same shape as the style commitment, one layer down — the cognitive moves the film will make.
bun run docent scene-fit recommend <id>
The recommender reads the survey and prints the top scene types with
rationales tying each to a specific survey finding. PR films almost
always include diff (the change) and closeup (the load-bearing
function annotated); tension is also load-bearing for the
trade-off. If the recommender returns warningOnDefault: true, the
survey collapsed to the default rut
(frame/structure/compare/tension/recap) — re-read the
triage and ask whether the load-bearing 5% actually wants
mechanism, walkthrough, causal-loop, timeline, or something
more specific. Pin the chosen scene set in the survey's
"Scene-set commitment" section.
-
Treatment.
docent treatment <id>Writes
treatments/<id>.md. Print the Angle line so the user sees the through-line you committed to before the spec is compiled. -
Spec — and interrogate it.
docent treatment <id> --to-spec docent review <id> --max-rounds 2The first compiles the treatment into
films/<id>.json. The second is mandatory —reviewruns the adversarial judge → revise → re-judge loop bounded to two rounds. On the corpus this reliably lifts a first-draft spec by ~7 points / 30 — the difference between a PR-review film that passes the depth contract and one that does not. Surface the verdict score and the weakest dimension before rendering. Ifreviewexhausts its round budget, stop and ask — do not ship a film the judge rejected. -
Render.
docent build <id> --scale 1 -
Open the result (unless
--no-open). On macOS:open out/<id>.mp4. -
Hand back. Three things to the user:
- the film id (so they can re-render via
/docent-build <id>), - the verdict score (e.g.
26/30), - one sentence of the verdict — what changes, what the residual risk is.
- the film id (so they can re-render via
Knowing when to stop and ask
Pause and ask the user instead when:
- The survey surfaces two plausible triages — the diff is too large to cover and you have to pick what to deprioritize.
- The PR is a refactor with no clear functional verdict; ask if the user wants the film to focus on the design trade-off rather than a yes/no ship decision.
reviewexhausts its round budget without passing the depth contract. Surface the failing dimensions; do not silently ship a film the judge rejected.
Failure modes
- No GitHub auth —
survey --mode prfetches diff / PR body / review threads viagh. Ifgh auth loginis needed, surface the message and stop. - Agent CLI missing —
surveyandtreatmentshell out toclaudeorcodex. If neither is on PATH, suggest/docent-doctor. - The judge keeps failing the triage dimension — that is a survey problem, not a render problem. The survey did not pick a load-bearing 5%; ask the user to point at the part of the diff that matters.