kn-doc

kn-doc is a skill for Claude Code, Codex from knowns-dev/knowns. It costs 20 tokens per session (1,098 once invoked), scanned A, original, MIT.

An on-call code reviewer focused on application failures in production. It examines source code for resilience problems such as missing timeouts, unsafe retries, swallowed errors, and unbounded queues.

In plain words
What is it for?
Use it to audit changed application code, its callers, and related tests for timeout, retry, idempotency, error-handling, and queue-safety risks.
Why use it?
It helps find code-level failures that could wake up the person carrying the pager. The review stays focused on application source rather than infrastructure or deployment configuration.

Skill for Claude CodeCodex

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 skills/knowns-dev/knowns/kn-doc
Any agent
npx skills add knowns-dev/knowns --skill kn-doc
Clone the repo
git clone --depth 1 https://github.com/knowns-dev/knowns

Made for: Claude Code, Codex.

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 kn-doc

README.md
[![agentmods](https://agentmods.dev/badge/skills/knowns-dev/knowns/kn-doc.svg)](https://agentmods.dev/skills/knowns-dev/knowns/kn-doc)
Your own site
<a href="https://agentmods.dev/skills/knowns-dev/knowns/kn-doc"><img src="https://agentmods.dev/badge/skills/knowns-dev/knowns/kn-doc.svg" alt="Measured on agentmods" height="20"></a>
Per session 20 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,098 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.00020 $0.01098
Opus 5 $0.00010 $0.00549
Sonnet 5 $0.00004 $0.00220
Haiku 4.5 $0.00002 $0.00110

Measured 3d ago against content hash cca96328dbe6, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

kn-doc 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 3d 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.

internal/instructions/skills/kn-doc/SKILL.md · 160 lines

How it starts

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

Working with Documentation

Announce: "Using kn-doc to work with documentation."

Core principle: SEARCH BEFORE CREATING - avoid duplicates.

Inputs

  • Doc path, topic, folder, or task/spec reference
  • Whether this is a create, update, or search request

Preflight

  • Search before creating
  • Prefer section edits for targeted changes
  • Preserve doc structure and metadata unless the user asked for a restructure
  • Validate refs after doc changes

Quick Reference

// List docs
mcp_knowns_docs({ "action": "list" })

// View doc (smart mode)
mcp_knowns_docs({ "action": "get", "path": "<path>", "smart": true })

// Search docs
mcp_knowns_search({ "action": "search", "query": "<query>", "type": "doc" })

// Create doc (MUST include description)
mcp_knowns_docs({ "action": "create", "title": "<title>",
  "description": "<brief description of what this doc covers>",
  "tags": ["tag1", "tag2"],
  "folder": "folder"
})

// Update content
mcp_knowns_docs({ "action": "update", "path": "<path>",
  "content": "content"
})

// Update metadata (title, description, tags)
mcp_knowns_docs({ "action": "update", "path": "<path>",
  "title": "New Title",
  "description": "Updated description",
  "tags": ["new", "tags"]
})

// Update section only
mcp_knowns_docs({ "action": "update", "path": "<path>",
  "section": "2",
  "content": "## 2. New Content\n\n..."
})

Creating Documents

  1. Search first (avoid duplicates)
  2. Choose location:
Type Folder
Core (root)
Guide guides
Pattern patterns
API api
  1. Create with title + description + tags
  2. Add content
  3. Validate after creating

CRITICAL: Always include description - validate will fail without it!

Updating Documents

Section edit is most efficient:

mcp_knowns_docs({ "action": "update", "path": "<path>",
  "section": "3",
  "content": "## 3. New Content\n\n..."
})

Validate After Changes

CRITICAL: After creating/updating docs, validate:

Read the full file on GitHub · 160 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. 3d ago First seen · 160 lines · 20 tokens per session scan A cca96328dbe6

Subscribe to this mod's changes

kn-doc is a skill published in the GitHub repository knowns-dev/knowns (241 stars, last pushed 7d ago), licensed MIT. It adds 20 tokens to every session and 1,098 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.

Related

Other skills, from other repositories

agent-session-monitor

Real-time agent conversation monitoring - monitors Higress access logs, aggregates conversations by session, tracks token usage. Supports web interface for viewing complete conversation history and costs. Use when users ask about current session token consumption, conversation history, or cost statistics.

higress-group/higress · 53 tokens

spec-kitty-charter-doctrine

Run charter interview, generation, context, and sync workflows for project governance in Spec Kitty 3.x. Access doctrine artifacts programmatically via DoctrineService. Resolve agent profiles. Load action-scoped governance context iteratively, not all at once. Triggers: "interview for charter", "generate charter"…

Priivacy-ai/spec-kitty · 135 tokens

flow-next-tracker-sync

Project a flow-next spec to a tracker issue (Linear, GitHub, GitLab, Jira) and reconcile two-way. Use when asked to sync to a tracker. NOT plan-sync.

gmickel/flow-next · 44 tokens

flow-next-export-context

Export RepoPrompt context to a markdown file for review with an external LLM (ChatGPT, Claude web, etc.). Use when you want Carmack-level review but prefer an external model. Triggers on "export context", "export for external review", "export plan for ChatGPT", "export impl review context", "review with an external…

gmickel/flow-next · 81 tokens

spk-team-auth

Handle Spec Kitty team authentication, hosted credentials, account selection, and auth-related recovery.

Priivacy-ai/spec-kitty · 22 tokens

submit-github-pr

Use when publishing an existing TensorRT-Model-Connect change as a GitHub pull request. Verifies authenticated repository access, branch and diff scope, validation evidence, commit identity, reviewer-facing text, exact pushed head, and the created draft PR without merging it.

NVIDIA/TensorRT-Model-Connect · 58 tokens