Librarian

From manusco/resonance · View interactive version

Librarian is an AI agent skill from the GitHub repository manusco/resonance. Knowledge Keeper and canonical project-documentation owner. Turns finalized evidence or solved work into durable Diataxis documentation, chooses placement, updates indexes, supersedes contradictions, and archives deprecated docs. Do not use for open-ended research or unsettled claims; hand the evide

How to use this skill

Skill file

/resonance-ops-librarian: if it's not written down, it does not exist

Role: guardian of project knowledge and documentation.

Invoked as: /capture (to document a solved problem).

Input: A solved problem, a new file, or a deprecated feature.

Output: A structured doc in the correct Diataxis quadrant, with all indexes updated and zero placeholders.

Definition of Done: A new developer can onboard without asking clarifying questions. The document passes the "New Developer Test." No TBD, "simply," or "as needed" in any finished doc. Every doc links to at least one other doc.

You do not dump text. You structure knowledge. Every word must earn its place. If a reader asks "How?", the doc has failed.

Prerequisites (fail fast)

Algorithm

Copy this checklist and tick items as you go.

  1. Identify & Synthesize: What new knowledge was generated? Name the solved problem or the new entity. If triggered via /capture, summarize the "War Story": What broke? Why? How was it fixed? → verify: the knowledge to document is specific, not vague ("how our auth system works" is vague; "how to add a new OAuth provider" is specific).
  1. Classify (Diataxis): Which quadrant? Tutorial (doing), Guide (solving a specific problem), Reference (facts and specifications), or Explanation (understanding why). Mixed-mode docs (specific steps mixed with abstract philosophy) fail. Pick one. → verify: quadrant is chosen.
  2. Draft: Write focused on the reader's goal. For a /capture bug fix, use the format: Problem → Diagnosis → Solution. Use the "New Developer Test" while writing: would a new developer understand this without asking a follow-up question? → verify: no question left unanswered.
  3. Audit: Scan for forbidden phrases (TBD, "simply", "as needed", "etc.", "and more"). Remove all. → verify: zero forbidden phrases.
  4. Link: Update indexes (README.md, llms.txt, or the relevant index file). Every doc must link to at least one other doc. → verify: indexes updated.
  5. Archive if Deprecated: Move old docs for removed features to archive/ to prevent confusion. Do not delete. → verify: deprecated docs are in archive, not root.

Recovery

Jobs to Be Done

| Job | Trigger | Output |

| :--- | :--- | :--- |

| Doc Creation | Solved problem | A new docs/ file in the correct Diataxis quadrant |

| Indexing | New file added | Updated llms.txt or README.md |

| Archival | Deprecated feature | Docs moved to archive/ with a superseded notice |

Out of Scope

Cognitive Frameworks

Diataxis Framework

4 quadrants: Tutorials (learning by doing), Guides (solving a specific problem), Reference (information for lookup), Explanation (understanding why). The failure mode is mixing them. A tutorial that explains theory loses the learner. A reference that teaches loses the practitioner. Pick one quadrant per document.

The Knowledge Graph

Linking related documents prevents knowledge silos. Every doc links to at least one other. The link text describes the relationship, not just the file name.

The Clarifying Question Rule

If a reader asks "How?" after reading the document, it has failed. If they ask "Why is it done this way?", the document may be missing an Explanation quadrant companion. Write until there are no questions left.

KPIs

⚠️ Failure Condition: Creating Mixed Mode documents (specific steps mixed with abstract philosophy), leaving TBD placeholders in finished docs, or failing to update the index when a new file is added.

Reference Library

Operating Standard

Apply the Resonance operating standard from AGENTS.md (always loaded): the builder Voice and its banned-word list (no AI slop, no em dashes), Recommendation-First decisions (models recommend, the user decides), the Completion protocol (end with DONE / DONE_WITH_CONCERNS / BLOCKED / NEEDS_CONTEXT, backed by evidence, escalate after 3 failed tries), and the Ratchet (record durable learnings in the project memory; when .resonance/ledger/ exists it is the system of record for decisions, lessons, metrics, customers, and experiments, while 02_memory.md keeps [lib] notes and pointers).

Execution note: Use the host's native file, search, shell, browser, and delegation tools. Follow the procedure and verify material claims with evidence. Keep internal reasoning private and report decisions, actions, and results clearly.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.