learn-diff-gate
Learning gate: explain the diff yourself, survive correction plus three why questions, then merge. Use before merging any agent PR.
- License 许可
- MIT
- 最近更新
- 2026-11-05
- Stars
- ★ 1
- Forks
- 0
01 前言 Front Matter
- name
- learn-diff-gate
- description
- Learning gate: explain the diff yourself, survive correction plus three why questions, then merge. Use before merging any agent PR.
- disable-model-invocation
- true
02 资源文件 2
- 参考文档agents/openai.yaml153 B
- 参考文档CREDITS.md407 B
03 SKILL.md 正文
Explain diff before merge
Deprecated from the merge path (2026-10-31): do not call from merge, ready-check, shipping, or opening-a-pr. Learning value folds into
/learn-teachorplan-interview. Execute path is/whipsonly.
A merge gate for learning: you may merge an agent PR only after proving you understand it. The agent never vouches for your understanding; it checks it.
Steps
- You explain first. Without re-reading the code, explain the diff in your own words: what changed, why, and what could break. Never copy the PR body back.
- The agent corrects. It marks each claim right, wrong, or incomplete against the diff, with file:line pointers. Skimmed or vague claims count as wrong.
- Three why questions. The agent asks three "craft-why" questions about the change (a tradeoff, a failure mode, a rejected alternative). Short answers accepted; hand-waving is not.
- Verdict. All correct means merge. Anything wrong means re-explaining that part, not merging around it. Two failed rounds means reopening the work (new questions for the authoring agent, or a
/learn-teachhandoff for the gap it exposed).
Rules
- Understanding is binary per claim: right or not yet. "Roughly" is not yet.
- The agent asks, never lectures. Explanations longer than the correction signal a teach moment: hand it to
/learn-teach. - Log recurring misses (same concept missed twice) as future lesson material, not as merge blockers.
Delegated learning (folded from the delegated-learning skill, 2026-10-31)
When the diff ahead is beyond your current reach but inside your learning zone, the same gate doubles as the classroom:
- Note gaps first. Name the concepts you cannot build unaided, in your own words, before the agent starts. Vague ("the backend part") means narrowing first: which call, which shape, which rule.
- Sliced diffs. The agent keeps the diff reviewable in small slices; each slice is one lesson. Never delegate what you could build in under an hour; never delegate two zones above your level.
- Three concepts. After the work lands, the agent picks the three load-bearing concepts and explains each against the exact lines that carry it. You restate each back until it holds without the code in front of you. A concept explained three times without sticking is a missing prerequisite: go one level down.
- Shaky ground becomes a
/learn-teachhandoff (/learn-handoffwrites it): mission, what failed to stick, what to drill next.
No LEARNED.md compounding log: /learn-teach learning records already keep the durable record, so a second log file only splits it.
04 同仓库更多 Skills
whips
Route any non-trivial task through one entry: match a playbook, drive HIT skills plus subagents, open a reviewed ready PR with ship-pr-shaped evidence.
verify-upkeep
Periodic upkeep for a project's verification skill: source wave plus live pass per feature, at most one PR of proven corrections. Use to audit the verify skill.
verify-statechart
Check a TLA+ model of a system that moves between states, such as a product flow, a protocol, or a service, and draw it as a Mermaid statechart. The report gives the shortest path to each state that breaks a rule. Use to show a bug as a path through states.
verify-new
Generate a project-local skill that drives the app like a user (launch, doctor, drive, evidence, feature map), proven once. Use when a project has no scripted proof.
ship-triage
Move issues and external PRs through a state machine of triage roles, categorise, verify, interview if needed, and write agent-ready briefs.
ship-runner
Run ready-for-agent issue queues on any schedule through /whips intake, one fresh worktree each, landing per risk tier, with the agent and model you pick at setup.