/nlsmdn:library-docs [target dir] [--refresh] [--force-all]from nlsmdn
Generate and refresh a per-repo `library-use` reference — official docs, changelog links, pinned versions, and distilled correct-usage conventions for the repo's fast-moving / niche libraries. Use when the user says "library-docs", "doc links", "document the libraries we use", "generate/refresh library docs", "library conventions", or wants a per-repo doc-links reference the agent (and `review-library-use`) can consult. On re-run it version-checks every entry and updates it.
Ships in nlsmdn. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Build (and keep current) a per-repo reference of the libraries this project actually depends on: canonical docs + changelog URLs, the version the repo resolves, and a short list of the most important correct-usage conventions for that version — the things a model gets wrong from stale training data.
The reference is written as a repo-local skill at .claude/skills/library-use/SKILL.md
so it (a) auto-triggers when the agent touches one of those libraries and (b) is the
convention source that review-library-use audits code against. This skill is the
generator/maintainer; review-library-use is the reviewer. Keep them distinct.
review-library-use checks code against it..git or a manifest)..claude/skills/library-use/SKILL.md yet) → generate from scratch.--refresh) → refresh mode (Step 6).--force-all reconsiders the full dependency list even for entries you previously excluded.Read the manifest(s) and their lockfiles to get declared deps + the resolved (pinned) version:
| Ecosystem | Manifest | Lockfile (pinned version source) |
|---|---|---|
| Node | package.json | pnpm-lock.yaml / package-lock.json / yarn.lock |
| Dart/Flutter | pubspec.yaml | pubspec.lock |
| Go | go.mod | go.sum / go.mod |
| Rust | Cargo.toml | Cargo.lock |
| Python | pyproject.toml / requirements.txt | uv.lock / poetry.lock / pinned == |
| Ruby | Gemfile | Gemfile.lock |
Curate — this is the point of the skill. Include a library only if it earns its tokens:
react, express, lodash, axios, pg, dayjs, zod, standard test/lint tooling. Documenting these is always-on noise.Documenting 7 of 41 deps (skipped popular/stable). Add one back with: library-docs --force-all or by naming it.For each kept library, find the official docs URL and the changelog/releases URL — prefer
first-party sources (project site, the repo's CHANGELOG.md or GitHub Releases), and prefer
a version-specific docs URL when the docs are versioned. Use the project's normal
doc-fetching path (web search + read the page; GitHub for changelogs). Do not invent URLs —
open the page and confirm it resolves before recording it.
Read enough of the docs for the pinned version to write 3–6 bullets per library covering the correct-usage rules most likely to be gotten wrong:
Keep bullets short and imperative. If a library's docs yield nothing beyond what the model obviously knows, record just the links and a single note — don't pad.
Write .claude/skills/library-use/SKILL.md from assets/library-use.template.md:
{LIB_LIST} in the description with the documented library names (drives auto-trigger).{REPO_NAME}, {DATE} (from git log -1 --format=%cd --date=short, since wall-clock isn't available), {MANIFESTS}.## <library> \`` block each, with Docs, Changelog, and Conventions..agents/skills/library-use symlink pointing at the Claude copy if the repo uses the .agents/skills convention (match sibling skills), so other agents pick it up.CLAUDE.md if none exists — Library docs & conventions: see .claude/skills/library-use — but only with the user's ok, and only one line.Report what you documented (a table of lib → version → #conventions) and stop.
For each existing entry, compare the recorded version to the current lockfile version, and handle new/removed deps:
BREAKING, removed/renamed/relocated APIs in the changelog) → do NOT silently rewrite. Instead:
<lib> <old>→<new> with the specific API changes (from the changelog).To decide "same API vs API changed", read the changelog/releases between the two versions; semver-major is a strong signal but confirm against the changelog (minors sometimes break; majors sometimes don't touch what this repo uses).
End refresh with a summary: {n} unchanged, {n} auto-updated (same API), {n} need migration (asked), {n} added, {n} removed.
User: library-docs
Actions:
pubspec.yaml + pubspec.lock. 41 deps; curate to 7 (keep maplibre-react-native, better_auth, niche plugins; skip http, provider, etc.)..claude/skills/library-use/SKILL.md + .agents/skills/library-use symlink.
Result: "Documented 7 of 41 deps. maplibre-react-native 10.0.0 (4 conventions), … Skipped 34 popular/stable. Re-run library-docs after upgrades to refresh."User: library-docs --refresh
Actions:
drizzle-orm 0.36→0.38: changelog shows no API change to what the repo uses → auto-update version + conventions.better-auth 1.2→2.0: major, changelog lists renamed emailAndPassword config → report the delta, grep finds 3 files using it, draft the migration, ask before applying.
Result: "5 unchanged, 1 auto-updated (drizzle-orm), 1 needs migration (better-auth 1.2→2.0 — 3 files) — proposed changes below, approve to apply."Cause: Library has no official hosted docs (common for small packages).
Solution: Fall back to the repo's README/CHANGELOG.md on GitHub as both docs and changelog. If there's genuinely nothing, record the repo URL and one note; don't fabricate a docs site.
Cause: Changelog is thin or missing. Solution: Compare the two release tags' notes/diffs on GitHub; check for major-version bump and any removed/renamed exports. If still unclear, treat it as API changed (the safe side — report + ask rather than silently rewrite).
Cause: Curation was too permissive.
Solution: Re-run and tighten Step 2 — drop popular/stable libs back out. The reference should be the tail, not the whole package.json.
Cause: The repo artifact must not be named library-docs (this skill's name) or both load at once.
Solution: The artifact is always library-use. Never write a repo-local skill named library-docs.
library-docs (this, generates) → library-use (per-repo reference) → review-library-use (audits code against it, auto-invoked by code-review).git (git log -1 --date=short), not from a live clock.What SKILL.md sets; muted values are Claude Code's defaults
mediumOther plugins' skills for the same job
npx claudepluginhub nielsmadan/skills --plugin nlsmdn65 skills in this plugin
/blind-spotsSurface consequential decisions a plan, design, or research brief left silently assumed, by interviewing the user in dependency order. Use when the user says "blind spots", "grill me", "stress-test this plan", "poke holes in this", "what am I missing", "interrogate this design", "what haven't I decided", or needs a loose idea or research brief clarified before work begins. Do NOT use for a clear factual lookup, to explain a previous reply in more detail (use `huh`), to generate ideas when it is unclear what to build (use `ideation`), or to review an already-written plan with agents (use `review-plan`)./brainstormWork out how to solve a problem the user can already name — interview them with `blind-spots` to understand it, generate structurally different approaches, validate each with an independent critic, then present the survivors with trade-offs and a recommendation. Use when the user says "brainstorm", "brainstorm approaches", "how should we solve/approach/tackle X", "what are our options", "compare approaches", "think this through with me", or wants solutions weighed before committing. Works on any topic, with codebase recon when a repo is involved; `--debate` adds external advisors for high-stakes calls. Do NOT use when stuck on what to build or what the problem is (use `ideation`), to probe an already-chosen plan (use `blind-spots`), or to pick a library or service (use `evaluate-tech`)./check-agent-logsSearch past Claude Code, Codex, Cursor CLI, Devin CLI, Droid, and Pi session logs to recover context from earlier work across the current project and sibling checkouts. Use when a bug, topic, or decision was handled in a previous session but its agent or checkout is unknown; when the user says "we fixed/discussed this before", "find the session where", "recover prior context", "check agent logs", "check Claude projects", "search past sessions/transcripts", or "which checkout was that in". Do not use for aggregate failure-pattern analysis; use review-logs for that./codebase-reviewReview a whole codebase aspect by aspect, with aspects fitted to the project type (mobile, desktop, web frontend, static site, CLI, backend, library) — docs truth-check, architecture, tests, security, the type's foundations, feature deep dives, consistency, roadmap — writing a doc per aspect and a verified findings ledger that doubles as the TODO. Plans first (recon, `blind-spots`, `review-plan`, plan approval), then walks the plan with the user aspect by aspect — agents review and verify in the background, the user confirms rulings and decides judgment calls one at a time. `--auto` runs independently after the gate, with decision waves at the end. `--fix` hands settled findings through `crew` to worker sessions, integrated locally, never pushed. Use for "codebase review", "review the whole codebase", "onboard me to this repo", "deep dive this app", "audit the code base", "review and fix everything". Not for a diff or PR (code-review), a CLI release pass (release-review), or building a feature (longshot)./codebase-review-typescriptSupply TypeScript and JavaScript structural evidence to codebase-review using dependency-cruiser, ESLint complexity, and Git churn. Use for whole-codebase import-cycle and complexity-hotspot investigation, or when discovered as a project-local codebase-review extension. Does not replace review-typescript's type-design checks or review a diff./code-guideCoach the user through writing a feature themselves, one small step at a time, the way an experienced developer would build it. Each step comes with the code to type and a checkpoint that proves it works, such as logging the endpoint's response shape before typing it, or rendering a hardcoded value before wiring the real one. After each step the agent reads the user's diff and verifies it. The happy path comes first and edge cases come last. Use when the user says "code-guide", "guide me to write", "help me write this myself", "I want to code it myself", "coach me through implementing", "walk me through building this feature", "don't write it for me", or wants to learn by typing the code. Do NOT use for console or dashboard setup (use guide), explaining existing code (use code-tour), or when the agent should implement the change itself (use plan or longshot).