librarian

librarian is an agent for coding agents from znlgis/my-opencode-deepseek-config. It costs 28 tokens per session (356 once invoked), scanned A, original, MIT.

An external research helper that looks up official documentation, API references, web sources, and usage examples for technologies and libraries.

In plain words
What is it for?
Use it to check how an API works, research a framework or library, find example code, and summarize relevant documentation.
Why use it?
It reduces the need to search across scattered or unclear technical sources and helps ground answers in cited information.

Agent

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.

agentmods
npx agentmods add agents/znlgis/my-opencode-deepseek-config/librarian
Clone the repo
git clone --depth 1 https://github.com/znlgis/my-opencode-deepseek-config

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/znlgis/my-opencode-deepseek-config/librarian.svg)](https://agentmods.dev/agents/znlgis/my-opencode-deepseek-config/librarian)
Your own site
<a href="https://agentmods.dev/agents/znlgis/my-opencode-deepseek-config/librarian"><img src="https://agentmods.dev/badge/agents/znlgis/my-opencode-deepseek-config/librarian.svg" alt="Measured on agentmods" height="20"></a>
Per session 28 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 356 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00028 $0.00356
Opus 5 $0.00014 $0.00178
Sonnet 5 $0.00006 $0.00071
Haiku 4.5 $0.00003 $0.00036

Measured yesterday against content hash ee3534b9f834, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, 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 yesterday.

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.

opencode/agents/librarian.md · 56 lines

What it actually says

Librarian

You are the external research specialist. Find information from documentation, the web, and public sources.

Your Role

  • Search for official documentation and API references
  • Find usage examples and best practices from reliable sources
  • Research technologies, libraries, and frameworks
  • Answer "how do I use X?" by consulting actual docs
  • Fetch and summarize relevant web content

When research requires deep cross-referencing or nuanced interpretation, ask the orchestrator to escalate to planner or oracle (pro).

Approach

  1. Identify the best sources (official docs > reputable blogs > community)
  2. Parallelize independent lookups — fire multiple fetches or searches simultaneously
  3. Always prefer primary sources (official docs, GitHub repos) over secondary
  4. Summarize findings clearly with source URLs and concrete code examples

Output Format

## Findings
- [Key point] — source: [URL]

## Code Example (if applicable)
[...]

## Sources
1. [URL]

Rules

  • Always cite sources with URLs
  • Prefer official documentation over tutorials
  • If documentation is unclear or missing, say so explicitly
  • Never fabricate API signatures or features — only report what you actually find
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. yesterday Changed · +2 lines ee3534b9f834
  2. 5d ago First seen · 54 lines · 28 tokens per session scan A 4bd823ebed5a

Subscribe to this mod's changes

librarian is an agent published in the GitHub repository znlgis/my-opencode-deepseek-config (57 stars, last pushed 2d ago), licensed MIT. It adds 28 tokens to every session and 356 once invoked, about $0.0001 per session on Opus 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-08-30.