distill

distill is a skill for Claude Code, Codex from Yuno15-bb/c-brain. It costs 70 tokens per session (430 once invoked), scanned A, original, Apache-2.0.

A note-taking workflow for saving important lessons, decisions, and constraints in a searchable knowledge store called C Brain. It files each note in a relevant category and links related notes.

In plain words
What is it for?
Use it when a problem has been solved, a decision needs its reasoning recorded, or the user asks to remember or distill something.
Why use it?
It preserves reasoning that would otherwise disappear when a session ends, especially facts that are not obvious from the code.

Skill for Claude CodeCodex

Part of the c-brain plugin — 3 skills, 8 agents, 5 hooks shipped together

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/yuno15-bb/c-brain/distill
Any agent
npx skills add Yuno15-bb/c-brain --skill distill
Clone the repo
git clone --depth 1 https://github.com/Yuno15-bb/c-brain

Made for: Claude Code, Codex.

Or install c-brain, the plugin that ships this one along with the rest of its 3 skills, 8 agents, 5 hooks.

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 distill

README.md
[![agentmods](https://agentmods.dev/badge/skills/yuno15-bb/c-brain/distill.svg)](https://agentmods.dev/skills/yuno15-bb/c-brain/distill)
Your own site
<a href="https://agentmods.dev/skills/yuno15-bb/c-brain/distill"><img src="https://agentmods.dev/badge/skills/yuno15-bb/c-brain/distill.svg" alt="Measured on agentmods" height="20"></a>
Per session 70 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 430 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.1 $0.00070 $0.00430
Opus 5 $0.00035 $0.00215
Sonnet 5 $0.00014 $0.00086
Haiku 4.5 $0.00007 $0.00043

Measured 5d ago against content hash 2893910c9f2c, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

distill 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 5d 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.

skills/distill/SKILL.md · 51 lines

What it actually says

Distill into a note

A session ends and its reasoning goes with it unless something is written down. This writes it down, in the shape the trunk expects.

What deserves a note

Only what a future reader could not re-derive cheaply:

  • a defect and how it was found, not just the fix;
  • a decision, its alternatives, and why they lost;
  • a constraint that is not visible in the code.

Not: what the repository already records, what only matters to this conversation, or a summary of work anyone could read from the diff.

Shape

One fact per file, in ~/.c-brain/trunk/<zone>/<slug>.md where zone is lessons (cross-project), projects/<name>, meta (ways of working) or life.

---
name: <short-kebab-case-slug>
description: <one line — this is what recall ranks on, so make it say the fact>
metadata:
  type: reference
---

<the fact, stated so it is useful without this conversation>

Why: <what makes it non-obvious>

How to apply: <the reflex it should produce next time>

Link related notes with [[their-slug]]. Link generously — a link to a note that does not exist yet marks something worth writing, not an error.

Then

  • Add one line to MEMORY.md: - [Title](path.md) — hook.
  • Check first whether a note already covers it and update that one instead. Two notes on one subject is how a trunk starts lying.
  • Convert relative dates to absolute ones. "Last Tuesday" rots.
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. 5d ago First seen · 51 lines · 70 tokens per session scan A 2893910c9f2c

Subscribe to this mod's changes

distill is a skill published in the GitHub repository Yuno15-bb/c-brain (2 stars, last pushed 10d ago), licensed Apache-2.0. It adds 70 tokens to every session and 430 once invoked, about $0.0003 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

kip-cognitive-nexus

Persistent graph-based memory for AI agents via KIP (Knowledge Interaction Protocol). Provides retrieval-first memory operations (KQL), durable writes (KML), schema discovery (META), and memory hygiene patterns. Use whenever the agent needs to consult or update persistent memory, especially for: remembering user…

ldclabs/KIP · 90 tokens

memesh

Use MeMesh to remember, recall, and manage AI knowledge across sessions, and to exchange task-focused messages with local agents. Triggers when the user asks to remember something, recall past decisions, forget outdated info, learn from mistakes, analyze work patterns, contact another agent, or handle a memeshmessage…

PCIRCLE-AI/memesh · 136 tokens

memesh-review

Review and optimize the MeMesh memory database. Analyzes health score, finds stale/conflicting/redundant memories, shows work patterns, and suggests cleanup actions. Use when asked to "review memories", "check memory health", "clean up knowledge", or "what's in my memory".

PCIRCLE-AI/memesh · 64 tokens

daily-briefing

Proactive daily briefing that fires on a recurring schedule, pulls recent memory and workspace context, composes a structured summary (action items, progress, radar, next steps), and delivers it to all active channels. Enable with a time like "set up my daily briefing at 9am". Disable, reschedule, or check status at…

vellum-ai/vellum-assistant · 75 tokens

ux-ui-analyze-single-page

Analyze exactly one captured UI page (from uxuimap screenshots + request JSON) and immediately write/update uxuimap/pages/{page}.md in neutral descriptive language. Use when asked to analyze screenshots, rewrite corresponding analysis immediately, or avoid memory/context saturation.

raphaelmansuy/edgequake · 58 tokens

mem9

Persistent cloud memory plugin for OpenClaw. This document routes setup, troubleshooting, and uninstall flows and defines config boundaries.

mem9-ai/mem9 · 27 tokens