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.
git clone --depth 1 https://github.com/komluk/scaffoldingWrote 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.
[](https://agentmods.dev/commands/komluk/scaffolding/learn)<a href="https://agentmods.dev/commands/komluk/scaffolding/learn"><img src="https://agentmods.dev/badge/commands/komluk/scaffolding/learn/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.
<a href="https://agentmods.dev/commands/komluk/scaffolding/learn"><img src="https://agentmods.dev/badge/commands/komluk/scaffolding/learn.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00000 | $0.01331 |
| Opus 5.5 | $0.00000 | $0.00532 |
| Sonnet 5.5 | $0.00000 | $0.00266 |
| Haiku 4.5 | $0.00000 | $0.00133 |
Grade A, and why
learn 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 1mo 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.
How it starts
The opening of the file, as written. The whole thing — 149 lines — stays where its author put it; the contents beside it link to each section on GitHub.
/learn Command
Distill a finished conversation into classified knowledge candidates and propose (never auto-apply) memory writes or a new-skill hand-off. Closes the loop between a completed agent chain and the persistent memory system.
Usage
/learn [conversation_id]
conversation_id is optional — when omitted, the active conversation is used. It
MUST be a UUID (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx).
What It Does
- Resolves the
conversation_id - Locates
context.md, the design## Decisionssection, and drains any low-confidence candidates queued in.scaffolding/.ingest-queue - Exits cleanly if there is nothing to distill
- Distills the conversation into knowledge candidates
- Classifies each candidate: memory entry vs new-skill proposal
- Dry-run proposes the changes; applies only on explicit confirmation
Apply the distill skill (Conversation-Scoped Distillation + Skill Promotion
Criterion) and the agent-memory skill (Learning Loop) throughout.
Steps
Follow these steps exactly.
1. Resolve the conversation_id
CONV_ID="$1"
if [ -z "$CONV_ID" ]; then
# Default: most recently modified conversation directory.
CONV_ID=$(ls -1dt .scaffolding/conversations/*/ 2>/dev/null | head -1 | xargs -r basename)
fi
UUID_RE='^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$'
if ! echo "$CONV_ID" | grep -qE "$UUID_RE"; then
echo "ABORT: '$CONV_ID' is not a valid conversation UUID."
exit 1
fi
echo "Conversation: $CONV_ID"
2. Locate the input files
CONV_DIR=".scaffolding/conversations/$CONV_ID"
CONTEXT_FILE="$CONV_DIR/agent-memory/context.md"
DESIGN_FILE="$CONV_DIR/specs/design.md"
if [ ! -f "$CONTEXT_FILE" ]; then
echo "Nothing to distill: $CONTEXT_FILE does not exist."
echo "The /learn command exits cleanly — no conversation memory to process."
exit 0
fi
echo "Found context: $CONTEXT_FILE"
if [ -f "$DESIGN_FILE" ]; then
echo "Found design: $DESIGN_FILE"
else
echo "No design.md — distilling from context.md only."
fi
# Drain low-confidence candidates queued by the memory-ingest Stop hook.
INGEST_QUEUE=".scaffolding/.ingest-queue"
if [ -s "$INGEST_QUEUE" ]; then
echo "Found ingest queue: $INGEST_QUEUE ($(wc -l < "$INGEST_QUEUE") lines)"
fi
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.
- 1mo ago First seen · 149 lines · 0 tokens per session scan A 24c9253d0f6c
learn is a command published in the GitHub repository komluk/scaffolding (15 stars, last pushed 2d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,331 tokens. 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.
Other commands, from other repositories
set-context
Set the client context so all subsequent analyses are automatically tailored — store client name, industry, size, geography, and key facts.
resume
Resume a programme from its durable ledger.
brain-init
Opt-in bulk mode: documents every undocumented source file as a linked note in turnstile/code/ after an explicit size/staleness warning. The default is lazy -- code notes are written for ticket-touched files when the ticket passes review.
pickup
Where was I? Restores work state from the board and vault -- the in-progress ticket, its implementation state, blockers, and the relevant notes -- ending with the next command to run. (Claude Code's built-in /resume restores a past conversation; this restores the work itself.).
remember
Files a note you dictate into the knowledge vault. You author the content; the curator only files, tags, and links it. Works in both capture modes.
obsidian-graph
Opens the project's turnstile/ folder in Obsidian and points you at Graph View to browse the brain as a linked graph.