librarian

librarian is an agent for Claude Code from HirogaKatageri/hirokata. It costs 148 tokens per session (3,435 once invoked), scanned A, original, MIT.

A documentation agent that records the business rules, design decisions, and reasons behind completed work in a linked knowledge store. It helps preserve why a system works the way it does.

In plain words
What is it for?
Use it to document requirements, subsystem behavior, and decisions after implementation.
Why use it?
It prevents important context from disappearing after a feature is built, so future developers do not have to reconstruct decisions from old changes.

Agent for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: model in frontmatter.

Part of the guild plugin — 20 skills, 15 agents shipped together

Good fit Use it to document requirements, subsystem behavior, and decisions after implementation.

Compare 6 agents from other repositories ↓
Install with agentmods
npx agentmods add agents/hirogakatageri/hirokata/librarian
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/HirogaKatageri/hirokata

Made for: Claude Code.

Or install guild, the plugin that ships this one along with the rest of its 20 skills, 15 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for librarian

README.md
[![agentmods](https://agentmods.dev/badge/agents/hirogakatageri/hirokata/librarian/github.svg)](https://agentmods.dev/agents/hirogakatageri/hirokata/librarian)
Your own site
<a href="https://agentmods.dev/agents/hirogakatageri/hirokata/librarian"><img src="https://agentmods.dev/badge/agents/hirogakatageri/hirokata/librarian/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for librarian

Your own site · 80×15
<a href="https://agentmods.dev/agents/hirogakatageri/hirokata/librarian"><img src="https://agentmods.dev/badge/agents/hirogakatageri/hirokata/librarian.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 148 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 3,435 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00148 $0.03435
Opus 5.5 $0.00059 $0.01374
Sonnet 5.5 $0.00030 $0.00687
Haiku 4.5 $0.00015 $0.00344

Measured 25d ago against content hash 07402538860c, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

librarian scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 25d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/guild/agents/librarian.md · 284 lines

How it starts

The opening of the file, as written. The whole thing — 284 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Librarian — Guild Agent

You are the Guild's Librarian. The guild builds things and then forgets why. Your job is the "why".

You are not a technical writer producing prose for its own sake. You produce rows in a graph: typed documents, linked to the work they explain, so that six months from now "why is it like this" is a SELECT and not an archaeology session.

The Warehouse — Where the Library Lives

The library is doc + knowledge_edge + doc_revision, not .guild/docs/*.md. Load the guild:warehouse skill before your first query — it carries the seven rules (hex transport, PRAGMA foreign_keys, RETURNING discipline, and the rest) that apply to every statement below — and copy the canonical forms from its references/queries.md §1.

export PATH="$HOME/.turso:$PATH"
DB=.guild/guild.db          # cloud boards: see the skill's Connect section

One addition specific to you: an edge has no foreign key. knowledge_edge endpoints are polymorphic, so the engine cannot check them. Write every edge as INSERT … SELECT … FROM <target table> WHERE id = … — the FROM clause is the check, and zero rows back means the target was not there. This is not optional and it is the single easiest thing to get wrong.

Set your name once so the triggers attribute the events to you:

printf "UPDATE guild_state SET value = 'librarian' WHERE key = 'actor';\n" \
  | tursodb -q -m list "$DB"

Your Workflow

1. Read the ticket and its requirement

T=TASK-NNN
printf "SELECT json_object('id',id,'req',requirement_id,'title',title,'objective',objective)
   FROM task WHERE id='$T';\n" | tursodb -q -m list "$DB"
printf "SELECT json_object('ts',ts,'agent',agent,'entry',entry)
   FROM work_log WHERE task_id='$T' ORDER BY id;\n" | tursodb -q -m list "$DB"

Log a start entry before substantive work so an interrupted run is resumable — the same form every other member uses.

2. Read the SOURCES. You do not invent anything

Read the full file on GitHub · 284 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 25d ago Changed · -9 lines 07402538860c
  2. 1mo ago Changed b1e1a6c73a5d
  3. 1mo ago First seen · 293 lines · 148 tokens per session scan A c8f9fd1f1238

Subscribe to this mod's changes

librarian is an agent published in the GitHub repository HirogaKatageri/hirokata (6 stars, last pushed 9d ago), licensed MIT. It adds 148 tokens to every session and 3,435 once invoked, about $0.0006 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-04.

Related

Other agents, from other repositories

quarto-critic

Adversarial QA agent that compares Quarto HTML against Beamer PDF benchmark. Produces harsh, actionable criticism. Does NOT edit files — read-only analysis only.

brycewang-stanford/Auto-Empirical-Research-Skills · 38 tokens

openwriter-enrichment-minion

Refresh stale OpenWriter loglines through exclusive canonical snapshot claims.

travsteward/openwriter · 19 tokens

report-generator

Use this agent when building the intelligence report synthesis layer — fusing multi-source findings into structured analyst reports, implementing confidence scoring, generating PDF/JSON exports, and designing the report data models. Examples: Context: Building the final output layer of the OSINT pipeline. user: "Build…

daemon-blockint-tech/Grond · 195 tokens

chronology-builder

Isolated worker that reads case documents iteratively and extracts sourced timeline events (date, neutral fact, mandatory document+locus provenance, undisputed/alleged/contested status, party attribution). Deduplicates and cross-references across documents and languages. Emits events.json for the legal-chronology…

fedec65/bettercallclaude · 103 tokens

flow-documenter

Use this agent when you need to generate comprehensive, natural language documentation for a Power Automate flow from its JSON definition. This agent should be invoked when:\n\n- A user provides a flow.json file and requests documentation\n- A new flow has been created and needs to be documented\n- An existing flow…

MacroMan5/AutomationHelper_plugins · 368 tokens

ops-documentacao

Especialista em documentação interna estruturada (Notion, Confluence, GitBook, wikis) para PMEs aplicando framework Diátaxis (Procida), BPMN, ITIL v4, ISO 9001, RACI. Use proativamente quando o usuário (a) escrever SOP / procedimento operacional padrão com estrutura completa (id, owner, escopo, ferramentas, fluxo…

asv-digital/agents-funcionarios · 0 tokens