lean-ctx-review
À propos
Cette compétence audite les performances des outils lean-ctx MCP en analysant les transcriptions des sessions Claude Code pour identifier quand les outils ctx_* ont échoué ou sont revenus à des alternatives natives. Elle extrait des données d'appel détaillées et fournit des règles de triage structurées pour soumettre des rapports de bugs en amont pour les problèmes confirmés. Utilisez-la lorsque les utilisateurs demandent des revues de performance des outils, rencontrent des échecs avec les outils ctx_*, ou souhaitent signaler des bugs de lean-ctx.
Installation rapide
Claude Code
Recommandénpx skills add yvgude/lean-ctx -a claude-code/plugin add https://github.com/yvgude/lean-ctxgit clone https://github.com/yvgude/lean-ctx.git ~/.claude/skills/lean-ctx-reviewCopiez et collez cette commande dans Claude Code pour installer cette compétence
Documentation
lean-ctx session review
Upstream repo: yvgude/lean-ctx (https://github.com/yvgude/lean-ctx).
Reads a Claude Code session transcript, so it applies to agents that write
~/.claude/projects/*/*.jsonl. Other harnesses need their own extractor; the
triage rules below are harness-independent.
1. Extract
Run from this skill's directory (needs python3):
python3 scripts/scan_session.py
Defaults to the newest transcript under ~/.claude/projects/*/ — the live
Claude Code session. Pass a path to review a different one. -d N dumps call
#N in full.
The script reports facts, not verdicts: every ctx_* call in order, which
results the harness flagged is_error, which calls repeated identical
arguments, which asked for raw/fresh output, and how many native
Read/Grep/Bash calls happened. It deliberately does not guess which of
those is a problem — that judgment is yours, below.
Transcripts run to megabytes, so read the table, not the raw JSONL.
2. Triage
Start from is_error. In practice every genuine tool failure carries it.
Then read the call list for the softer signals: identical retries, raw/fresh
re-reads, native calls clustered right after a ctx_* call, or a sequence that
only completed once ctx_* was abandoned.
Before absolving anything, do these two things
Skipping them is how this review returns a false "nothing to report". Both cost one command each.
Search the tracker for the guard or tool you are about to excuse. Do this during triage, not at step 4. A closed issue defines intended behaviour: if a shipped fix says a form is supported and you just watched it fail, that is a regression and one of the most valuable things this review finds. It also stops you re-filing a settled design decision.
gh issue list --repo yvgude/lean-ctx --search "<guard or tool keyword>" --state all
Probe the stated rationale — never accept a message's self-description. An error explains itself, and that explanation can be wrong. Three checks, each one command:
- Does the sanctioned alternative achieve the same thing? If the block is bypassable through a route the message itself recommends, it constrains syntax, not capability. Sometimes that is deliberate (structured input parses reliably where a shell string does not) — decide which, do not assume.
- Does the stated reason match the observed rule? Vary one axis at a time. A guard blaming payload size that actually keys on path, or blaming a pipe on a command that is piped, is misdiagnosing itself.
- Does the message contradict itself? A rejection that also states the rejected form is allowed is a finding on its own, whichever way the policy should go.
A wrong diagnostic is a real bug even when the block is correct: it sends the next caller down a route that cannot work.
Not a finding
- Words inside returned content. A file containing
http.StatusConflict, agit rebaseprintingCONFLICT (content):,ghreturning"mergeable":"CONFLICTING", a test run printingnot found. The tool returned exactly what was asked for. Judge the tool's own behaviour, never the payload's vocabulary. - Self-reference. Any result that quotes a previous scan, this skill, or a transcript will echo every error word in it.
- Guard blocks — only after they survive the probe above. Inline env
overrides (
GIT_EDITOR=), shell redirects (>/>>), non-allowlisted commands, paths outside the project root. "It offered an alternative and the alternative worked" is not enough to clear one: that is true of a guard whose reason is wrong, whose rule is different from its description, or that contradicts itself. Clear it only once the stated rationale holds up. - Malformed tool input.
InputValidationErroron__unparsedToolInputis the caller's own JSON serialization — commonly a raw tab or newline inside a string — rejected before lean-ctx ever ran. - My own wrong arguments, a genuinely missing file, a failing build.
Confirmable
The tool did something wrong or unhelpful given correct input:
- wrong, lossy, or truncated output where the mode promises otherwise
- content injected into output documented as verbatim, or anything that breaks a documented output format (e.g. corrupting batch-read separators)
- a crash, hang, or schema mismatch against the documented parameters
- a documented mode behaving differently than described
- a retry that only succeeded after dropping to native tools
- a wrong or self-contradicting diagnostic, even where the block itself is right — naming the wrong cause sends the next caller down a route that cannot work, and costs more than the block did
- a regression against a closed issue: a shipped fix says the form is supported, and it is not
3. Reproduce
No minimal repro, no issue. Re-run the exact tool and arguments. If it passes, try to isolate the trigger; if you cannot, do not file — report the observation to the user instead, saying plainly that it did not reproduce and what you tried. Guessing at internals is worse than silence.
lean-ctx --version for the version line.
Zero confirmed findings is a valid and common result. Say so and file nothing.
4. File
Only for confirmed findings, one issue per distinct problem. You searched the tracker during triage; widen it here if the finding shifted:
gh issue list --repo yvgude/lean-ctx --search "<keywords>" --state all
Skip if already reported — and read the close text before re-filing, since a closed issue may have already conceded the point you are about to raise. When a finding contradicts a closed fix, cite it and frame the issue as the gap in that fix. Otherwise:
gh issue create --repo yvgude/lean-ctx --title "..." --body-file <file>
Body: what happened, expected, minimal repro (exact tool + args), version, OS.
No speculation about internals. End every issue body with the Claude Code
attribution footer. Report the issue html_url back to the user.
Dépôt GitHub
Questions fréquentes
Qu’est-ce que le Skill lean-ctx-review ?
lean-ctx-review est un Skill Claude créé par yvgude. Un Skill regroupe des instructions et des ressources que Claude charge à la demande pour effectuer des tâches liées à lean-ctx-review sans consigne supplémentaire.
Comment installer lean-ctx-review ?
Utilisez les commandes d’installation de cette page : ajoutez lean-ctx-review à Claude Code comme plugin ou clonez son dépôt dans votre dossier skills, puis redémarrez Claude pour charger le Skill.
À quelle catégorie appartient lean-ctx-review ?
lean-ctx-review appartient à la catégorie Documentation.
lean-ctx-review est-il gratuit ?
Oui. lean-ctx-review est référencé sur AIMCP et son installation est gratuite.
Compétences associées
Cette compétence récupère la documentation actuelle de Railway pour répondre aux questions sur les fonctionnalités, le fonctionnement ou des URL spécifiques de la documentation. Elle garantit que les développeurs reçoivent des informations précises et à jour directement depuis les sources officielles de Railway. Utilisez-la lorsque les utilisateurs demandent comment fonctionne Railway ou font référence à la documentation de Railway.
Cette compétence Claude offre un accompagnement expert pour écrire du code Python dans les nœuds Code de n8n, en particulier pour utiliser la bibliothèque standard de Python et travailler avec la syntaxe spéciale de n8n comme `_input`, `_json` et `_node`. Elle aide les développeurs à comprendre les limites de Python dans n8n et recommande d'utiliser JavaScript pour la plupart des workflows, tout en proposant des solutions Python pour des besoins spécifiques de transformation de données.
La compétence Archon offre une recherche sémantique alimentée par RAG et une gestion de projet via une API REST. Utilisez-la pour interroger la documentation, gérer des projets/tâches hiérarchiques et effectuer de la recherche de connaissances avec des capacités de téléchargement de documents. Priorisez toujours Archon en premier lors de la recherche dans une documentation externe avant d'utiliser d'autres sources.
Cette compétence Claude fournit des conseils d'expert pour écrire du code JavaScript dans les nœuds Code d'n8n. Elle couvre la syntaxe essentielle spécifique à n8n comme les variables `$input`/`$json`, les assistants HTTP et la gestion des DateTime, tout en résolvant les erreurs courantes. Utilisez-la lors du développement de workflows n8n nécessitant un traitement JavaScript personnalisé dans les nœuds Code.
