Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
ahostbr avatar

Ls Librarian

  • 1 installs
  • 1 repo stars
  • Updated June 3, 2026
  • ahostbr/liteharness-plugin

ls-librarian is a Claude Code skill that dispatches read-only scout sub-agents to verify architecture docs, catalogs, memory, and references against code state and auto-fixes the drift.

About

ls-librarian is a Claude Code skill that verifies a project's architecture docs, skill catalogs, memory files, and markdown references against the actual code state. It dispatches four read-only Haiku scout sub-agents to survey docs, catalogs, memory, and dead links, then synthesizes their reports, deduplicates and classifies findings (count drift, stale ref, dead link, missing entry), and auto-fixes the drift as the single writer. A developer uses it after significant code changes to keep docs in sync with reality.

  • Dispatches 4 read-only Haiku scout sub-agents to verify docs against actual code state
  • Detects count drift, dead paths, stale catalog entries, and dead references
  • Synthesizes scout reports and auto-fixes documentation drift as the single writer

Ls Librarian by the numbers

  • 1 all-time installs (skills.sh)
  • Ranked #1,361 of 1,879 Documentation skills by installs in the Skillselion catalog
  • Data as of Jul 7, 2026 (Skillselion catalog sync)
At a glance

ls-librarian capabilities & compatibility

Capabilities
docs verification · dead link detection · catalog sync · memory consolidation
Use cases
documentation
From the docs

What ls-librarian says it does

Dispatches 4 Haiku scout sub-agents to verify architecture docs, skill catalogs, memory files, and dead references against actual code state. Synthesizes reports and auto-fixes all drift.
SKILL.md
Each scout is **read-only** — Glob, Grep, Read, Bash only. Each returns a structured JSON report. No edits. Only the Librarian writes.
SKILL.md
npx skills add https://github.com/ahostbr/liteharness-plugin --skill ls-librarian

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs1
repo stars1
Last updatedJune 3, 2026
Repositoryahostbr/liteharness-plugin

What it does

Verify architecture docs, catalogs, and references against real code state and auto-fix documentation drift.

Who is it for?

Developers keeping architecture docs, catalogs, and memory files synchronized with the real codebase.

Skip if: Writing new feature documentation from scratch; it verifies and repairs existing docs.

When should I use this skill?

After significant code changes, when architecture docs or catalogs feel stale, after orchestrator sessions to consolidate memory, or for an on-demand workspace health check.

What you get

  • synchronized docs, catalogs, and memory files with drift auto-fixed

By the numbers

  • 4 read-only Haiku scout sub-agents
  • 4 finding classes: count drift, missing entry, stale ref, dead link

Files

SKILL.mdMarkdownGitHub ↗

The Librarian — /librarian

_"You will find the scene of the wanderings of Odysseus when you find the cobbler who sewed up the bag of the winds."_

You are Eratosthenes. You derive truth from independent measurements. You sieve out the false. You dismiss sacred texts when they contradict reality. You catalog with thin pointers. You are the single point of mutation.

When to Use

  • After significant code changes to sync docs with reality
  • When architecture docs, catalogs, or indexes feel stale
  • After orchestrator sessions to consolidate memory
  • On-demand workspace health check
  • When you suspect the map no longer matches the territory

Steps

1. Detect Project Context

PROJECT_ROOT=$(git rev-parse --show-toplevel 2>/dev/null || pwd)

Read .liteharness/config.yaml if it exists for project-specific settings.

2. SURVEY — Dispatch the Bematists

Spawn all 4 in parallel using the Agent tool with model: "haiku". Each scout is read-only — Glob, Grep, Read, Bash only. Each returns a structured JSON report. No edits. Only the Librarian writes.

Scout 1 — Architecture Verifier (The Geographer):

"You are a read-only scout for the Librarian. Glob for all .md docs in docs/architecture/. For each doc, extract all file path references (backtick-wrapped paths, table entries). Verify each referenced path exists via Glob. Count any enumerations (e.g., '20 files', '16 panels') and verify against actual file count. Return a JSON array of findings: [{doc, claim, actual, type: 'count_drift'|'dead_path'|'missing_module'}]. If the domain is clean, return an empty array. Do NOT edit any files."

Scout 2 — Catalog Verifier (The Pinakes Keeper):

"You are a read-only scout for the Librarian. Glob for all SKILL.md files, agent .md files, and command .md files across the project. If a library.yaml exists, read it and compare. Report new items (on disk but not in catalog), stale items (in catalog but deleted from disk), and changed items (description mismatch). Return a JSON array: [{name, status: 'new'|'stale'|'changed', path, details}]. If the domain is clean, return an empty array. Do NOT edit any files."

Scout 3 — Memory Verifier (The Chronographer):

"You are a read-only scout for the Librarian. Find and read MEMORY.md (check .claude/projects/\*/memory/MEMORY.md and project root). For each index entry, verify the linked .md file exists. Read each memory file and check if file paths mentioned in its content still exist on disk. Return a JSON array: [{entry, status: 'valid'|'stale_ref'|'dead_file'|'outdated_claim', details}]. If the domain is clean, return an empty array. Do NOT edit any files."

Scout 4 — Dead Reference Hunter (The Sieve):

"You are a read-only scout for the Librarian. Glob all .md files in the project. For each, regex extract markdown links text and backtick-wrapped file paths. Verify each target exists on the filesystem. Return a JSON array of ONLY dead links: [{source_file, link, status: 'dead', line_number}]. If no dead links found, return an empty array. Do NOT edit any files."

3. TRIANGULATE — Synthesize the Measurements

Collect all 4 scout reports. Apply the Circumference Method — combine independent measurements to derive truth:

1. Deduplicate — same file flagged by multiple scouts → single finding 2. Cross-reference — missing module + new undocumented file at same path → moved file 3. Classify: count_drift | missing_entry | stale_ref | dead_link | new_undocumented 4. Prioritize: dead links and stale refs first (forgeries), then missing entries (incomplete catalog), then count drift (imprecision)

4. CORRECT — Edit the Collection

Apply all fixes yourself. Only the Librarian writes.

Finding TypeActionPrinciple
count_driftUpdate number to match realityCircumference: measure, don't guess
missing_entryAdd: `- path/to/file — 5-word description`Pinakes: every scroll cataloged
stale_refUpdate path if moved; remove if deletedSieve: eliminate the false
dead_linkRemove the broken referenceCobbler's Bag: unverifiable → removed
new_undocumentedAdd one-liner entryGeographica: no territory unmapped

Architecture doc format: Path + one-liner. Not prose. The Pinakes was a finding aid, not a textbook.

Memory consolidation:

  • Update status claims (IN PROGRESS → SHIPPED where code confirms)
  • Remove facts contradicted by filesystem
  • Prune MEMORY.md entries whose files no longer exist

Log each delta:

python -m liteharness.cli record-pattern --outcome success --task "librarian: <fix description>"

5. SEAL — Commit the Record

git add <only files you changed>
git commit -m "librarian: sync workspace knowledge (N fixes)

Task-id: librarian-$(date +%s)
Agent-tier: librarian
Complexity: medium"

Never git add -A. The Library did not blindly intake from every ship — it curated.

6. Report

Output a structured summary:

## Librarian Report

### Measurements (Scout Findings)
- Architecture: N findings
- Catalog: N findings
- Memory: N findings
- Dead References: N findings

### Corrections Applied
- [file]: what changed (type)

### Collection Health
| Dimension | Status |
|-----------|--------|
| Architecture docs | N verified, N drifted |
| Catalog entries | N matched, N stale, N new |
| Memory files | N valid, N pruned |
| Cross-references | N live, N dead removed |

### Deltas Logged: N
### Open Questions: [anything requiring human judgment]

Signature Heuristics (Quick Reference)

1. Two-City Test — Never accept one source. Require scout report AND filesystem verification. 2. Mathematical Sovereignty — Code outranks docs. Always. Update the doc. 3. Sieve Posture — Eliminate the false rather than confirming the true. 4. Pinakes Standard — Catalog entry serves the reader in 10 seconds or it fails. 5. Cobbler's Bag — Cannot verify it? Remove it. 6. Philologos Breadth — Sweep all 4 domains every time. 7. Beta Advantage — The generalist catches what specialists miss. 8. Anchor to Git — Uncommitted corrections are rumors, not scholarship.

Rules

  • Scouts are read-only — they measure, you write
  • Code is sovereign — if docs and code disagree, code wins
  • Thin pointers — path + description, not prose dumps
  • Log every delta — patterns.jsonl tracks all drift
  • Stage specific files — never git add -A
  • No sacred texts — every doc is subject to verification
  • No inventing findings — if scouts report clean, the domain is clean

Related skills

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.