Explains why code looks the way it does: the commits that shaped a file, a function or a few lines, what each one changed and why, and the issues, tickets and pull requests they mention. Use when the user asks "why is this here?", "why was this changed?", "who added this and what for?", "what's the story behind X?", or is about to change code they don't understand.
Collected from public GitHub. Every version is saved exactly as it was and never changes. Install it at an exact version with the mdr tool, and every file is checked before it reaches your agent. The main file is checked against the SHA-256 fingerprint recorded here, and the others against the fingerprints GitHub keeps for its source commit. The automatic checks below grade the latest version, and the same checks always give the same file the same grade.
What the file says
## Steps
1. **Find the code.** If the user named a function or class rather than lines, find its file and line range with
code-review-graph (`semantic_search_nodes_tool`) or by reading the file. Ask only if it is still ambiguous.
2. **Get the history:**
```bash
lfg why <file>:<start>-<end> --json # or <file> for the whole file
```
Each commit has `sha`, `author`, `date`, `subject`, `body`, `fix` and `refs` (issue numbers, tracker keys and PRs
with links, built from the repo's remote and the Linear workspace; nothing is fetched).
3. **Read the important commits**, at most three: `git show <sha> -- <file>` for the ones whose message explains a
decision or a fix. If a ref is a Linear key and the Linear tools are available, read that issue for the reason.
4. **Answer in plain words**, newest reason first:
- one or two sentences: why the code is like this today;
- the turning points: `sha` (date, author): what changed and why, with the issue or PR link when there is one;
- fixes in this code (`fix: true`) and what they were for: these are what will break again if changed carelessly;
- what to keep in mind before changing it.
…
The line at the top of this page pins the label git:20261024.606c03c, which is what most people want. This one pins the sha256 fingerprint of the contents instead, so it survives a label being moved. Either way the exact version is written to mdr.lock, and mdr install downloads and checks those contents again, so it installs them exactly or stops with an error.
A 17 of 17 checks passed. Fixed automatic checks with no AI involved, so the same checks give the same answer every run.
pass: Frontmatter block present
pass: Frontmatter declares a name
pass: Frontmatter declares a description
pass: Size between 200 bytes and 200 KB (1846 bytes)
pass: No zero-width or bidi control characters
pass: No instruction hidden inside an HTML comment
pass: No link to an exfiltration or paste host
pass: No credential-shaped string
pass: No instruction to send local credentials anywhere
pass: No text hidden with inline styles
pass: No prompt-injection phrasing
pass: No curl or wget piped into a shell
pass: No recursive delete of root, home or parent
pass: No instruction to read or print local credentials
pass: No base64 blob over 200 characters
pass: No link to a raw IP address
pass: No script tag
Source
GitHub
varun-singhh/lfg · 10 stars · license MIT · pushed 2026-10-26 · branch main
API
GET https://markdownregistry.com/api/v1/artifacts/art_hxvgdcj2vtdy2fq4
GET https://markdownregistry.com/api/v1/resolve?ref=varun-singhh/lfg/why
GET https://markdownregistry.com/api/v1/blob/aa8d85bc6046350f07c05280d03d6cdba852fc47406824665987c700165e1119
Your AI assistant does the legwork. You hear about the deals worth your word. Hand yours the standing instructions at modelranch.com and it joins the network that reads files like this one.
varun-singhh/lfg · plugin/skills/check/SKILL.md · The green gate: fixes lint (never suppresses), type-checks, runs affected tests then the full suite, builds like CI…
varun-singhh/lfg · plugin/skills/explain/SKILL.md · Answers questions about how the code works from the knowledge graphs first (code-review-graph, then graphify, then…
varun-singhh/lfg · plugin/skills/explain5/SKILL.md · Explain code in plain English like you're explaining to a 5-year-old. Use when the user asks "explain this", "what does…
varun-singhh/lfg · plugin/skills/fix/SKILL.md · Diagnoses and fixes a bug or regression: builds a tight pass/fail loop first, then reproduces, hypothesises, finds the…
varun-singhh/lfg · plugin/skills/grill/SKILL.md · Interviews the user one question at a time, informed by the code graphs, until the goal, users, acceptance criteria and…
varun-singhh/lfg · plugin/skills/handoff/SKILL.md · Writes a compact handoff note into the run folder (state, next step, which skills to use) and updates progress.md, so a…
varun-singhh/lfg · plugin/skills/health/SKILL.md · Scans the codebase for deepening opportunities (shallow modules, leaky seams, hard-to-test areas) using the graphs, and…
varun-singhh/lfg · plugin/skills/impact/SKILL.md · Shows the blast radius of the current diff or a named symbol: callers, dependents, affected flows and the tests that…
varun-singhh/lfg · plugin/skills/inbox/SKILL.md · Pulls new Linear issues (read-only) into dev-graph and proposes a triage state for each: needs-info, ready-for-agent or…
varun-singhh/lfg · plugin/skills/learn/SKILL.md · Retro on a run (or a week of runs): turns what happened into dev-graph Learning and Principle nodes, repo playbooks…
varun-singhh/lfg · plugin/skills/lfg/SKILL.md · Runs the whole LFG pipeline on an idea or a Linear issue: grill → plan → build → check ∥ secure ∥ pentest → review →…
cursor/plugins · harness/pstack/claude-code/skills/why/SKILL.md · Use for 'why does X work this way', 'why we picked Y', design rationale, regressions, postmortems, or data-backed…
cursor/plugins · pstack/skills/why/SKILL.md · Use for 'why does X work this way', 'why we picked Y', design rationale, regressions, postmortems, or data-backed…
nightly-labs/openbot · marketplace/production-catalog/bundles/pstack/skills/why/SKILL.md · Use for 'why does X work this way', 'why we picked Y', design rationale, regressions, postmortems, or data-backed…
michael-denyer/pstack-claude · plugins/pstack/skills/why/SKILL.md · Use for 'why does X work this way', 'why we picked Y', design rationale, regressions, postmortems, or data-backed…
backnotprop/pstack · skills/why/SKILL.md · Use for 'why does X work this way', 'why we picked Y', design rationale, regressions, postmortems, or data-backed…
bastani-inc/atomic · packages/workflows/skills/why/SKILL.md · Use for 'why does X work this way', 'why we picked Y', design rationale, regressions, postmortems, or data-backed…
millw14/merrymen · plugins/merrymen/skills/why/SKILL.md · Explain why the user's Merrymen trading agent has or hasn't traded, from its recorded state, blockers and recent…
iap/pstack-hermes · skills/why/SKILL.md · Use for 'why does X work this way', 'why we picked Y', design rationale, regressions, postmortems, or data-backed…