know-code-teach

A teaching workflow that explains architecture, design choices, and trade-offs before and during coding. It is intended for developers who want to understand changes rather than receive unexplained edits.

In plain words
What is it for?
It prepares plain-language implementation explanations, identifies the parts of a codebase that will change, discusses trade-offs, and continues with short explanations while coding.
Why use it?
It makes non-trivial work easier to review by clarifying the intended change, affected code areas, risks, and alternatives before files are modified.

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/chtnnh/know-code/know-code-teach
Any agent
npx skills add chtnnh/know-code --skill know-code-teach
Clone the repo
git clone --depth 1 https://github.com/chtnnh/know-code

Made for: Claude Code, Codex.

Per session 77 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 835 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.00077 $0.00835
Opus 5 $0.00039 $0.00417
Sonnet 5 $0.00015 $0.00167
Haiku 4.5 $0.00008 $0.00084

Measured yesterday against content hash 9dbdc7b1f9e6, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

know-code-teach 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.

skills/know-code-teach/SKILL.md · 76 lines

How it starts

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

know-code-teach

Teach the human what is changing and why — before you edit files, then keep teaching in small increments while you code. This skill never writes a know-code gate receipt. Verification is know-code.

When to run (required)

Run this skill before you create or modify project files for any non-trivial task:

  • New features, refactors, bug fixes that touch more than a one-liner
  • Session start on an unfamiliar codebase / area
  • After a know-code gate deny (before know-code quiz)
  • After a quiz failure (re-teach weak spots)
  • User asks “what are you doing?”, “why this approach?”, or “catch me up”

Skip only if the human explicitly says so (“skip teach”, “just do it”, “I know this”).

Playbook

Read references/explain-playbook.md and follow it. Defaults:

  1. Intent — one sentence: problem + proposed outcome
  2. Touch map — which areas of the codebase will change (paths/modules)
  3. Approach — chosen design in plain language
  4. Trade-offs — 1–3 alternatives and why not
  5. Risks — what could go wrong; what you will verify
  6. Checkpoint — ask if the human wants a different approach before editing

While coding, keep explanations incremental: after meaningful chunks, narrate what landed and what is next. No lectures. No wall of text.

Pairing with know-code

Skill Role
know-code-teach Build understanding before/during work
know-code Verify understanding before commit/push/PR

Required order: range begin → teach → implement and stage the final diff → human seals know-code taughtquestions → quiz → ask → agent grade-proposal.json → human grade --reviewpassknow-code commitrange seal / push.

Re-seal know-code taught when the diff hash changes (know-code hash).

After teaching, implementation, and staging (or an explicit human skip), the human seals the final artifact (passphrase; agents cannot forge):

know-code taught
# or, only if the human explicitly skipped:
know-code taught --skip

Read the full file on GitHub · 76 lines

Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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 First seen · 76 lines · 77 tokens per session scan A 9dbdc7b1f9e6

Subscribe to this mod's changes

know-code-teach is a skill published in the GitHub repository chtnnh/know-code (3 stars, last pushed yesterday), licensed MIT. It adds 77 tokens to every session and 835 once invoked, about $0.0004 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-31.

Related

Other skills, from other repositories

create-skill

Guides users through creating effective Agent Skills for Cursor. Use when the user wants to create, write, or author a new skill, or asks about skill structure, best practices, or SKILL.md format.

xstongxue/best-skills · 46 tokens

ppt-design

使用 HTML 设计与生成高质量演讲幻灯片(PPT/Deck)。当用户希望生成、设计、修改幻灯片、deck、slides、presentation、汇报、提案、pitch、课件时触发。主干:1280×720px 可编辑 HTML 幻灯片 + 唯一 editable HTML→EditableSlideScene→OOXML 管线 + 数据/信息可视化意识 + 5 种设计哲学 + 反 AI slop + 单页自包含 slide-XX.html。不生图;缺图用可编辑原语或占位并标注建议补图。.

GCWing/BitFun · 139 tokens

hns-lsel-curator

Local Self-Evolution Loop (LSEL) curator — the CLUSTER + drain engine for the GOOS-local PROPOSE→APPLY seam closure (SPEC-LSEL-LOCAL-EVOLUTION-001). Companion-offset drain of .moai/lessons-inbox.jsonl with a drain-side severity filter that drops the 65% Bash-timeout/sandbox noise, eventkey clustering with a frequency…

modu-ai/moai-adk · 135 tokens

skill-creator

Create new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an existing skill, run evals to test a skill, benchmark skill performance with variance analysis, or optimize a skill's description for better triggering accuracy.

CherryHQ/cherry-studio · 64 tokens

skill-creator

Create, refine, and benchmark agent skills. Use when building a new skill, updating an existing one, running evals, checking trigger quality, or improving a skill description.

feiskyer/claude-code-settings · 39 tokens

memstack-development-mentor

Use when the user says 'teach me', 'explain as you go', 'mentor mode', 'walk me through', 'help me learn', 'explain why', 'learning mode', or wants real-time plain language narration of decisions and tradeoffs while building. Do NOT use for code review or debugging.

cwinvestments/memstack · 69 tokens