lessons-ledger

lessons-ledger is a skill for Claude Code, Codex from benjaminard/fable-skills. It costs 76 tokens per session (629 once invoked), scanned A, original, MIT.

A set of rules for recording useful lessons from earlier agent sessions in a persistent workspace.

In plain words
What is it for?
Use it after corrections, surprising failures, or confirmed approaches that should be remembered.
Why use it?
It helps future sessions avoid repeating confirmed mistakes or overlooking important environment-specific facts.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it after corrections, surprising failures, or confirmed approaches that should be…

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/benjaminard/fable-skills/lessons-ledger
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.

Any agent
npx skills add benjaminard/fable-skills --skill lessons-ledger
Clone the repo
git clone --depth 1 https://github.com/benjaminard/fable-skills

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 lessons-ledger

README.md
[![agentmods](https://agentmods.dev/badge/skills/benjaminard/fable-skills/lessons-ledger.svg)](https://agentmods.dev/skills/benjaminard/fable-skills/lessons-ledger)
Your own site
<a href="https://agentmods.dev/skills/benjaminard/fable-skills/lessons-ledger"><img src="https://agentmods.dev/badge/skills/benjaminard/fable-skills/lessons-ledger.svg" alt="Measured on agentmods" height="20"></a>
Per session 76 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 629 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.00076 $0.00629
Opus 5 $0.00038 $0.00315
Sonnet 5 $0.00015 $0.00126
Haiku 4.5 $0.00008 $0.00063

Measured 7d ago against content hash a8d1793a9133, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

lessons-ledger 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 7d 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/lessons-ledger/SKILL.md · 31 lines

How it starts

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

Lessons Ledger

An agent that cannot remember its corrections repeats them. Keep a ledger of lessons in the workspace (a lessons/ directory or the project's designated memory location) and treat it as part of the codebase: referenced, updated, and pruned.

Writing a lesson

  1. One lesson per file, summary on top. Each file holds exactly one fact or rule, with a one-line summary as its first line so a future scan of the directory reads like an index.
  2. Record corrections and confirmations alike. A lesson is either "this failed and here is why" or "this approach was confirmed to work and here is why it mattered." Both prevent re-derivation. Include the why: a rule without its reason gets misapplied.
  3. The bar for saving: would a future session, starting cold, do the wrong thing without this note? If yes, save it. If the repo, the docs, or the chat history already record it, do not duplicate it; the ledger is for what is written down nowhere else.
  4. Convert relative time to absolute. "Last week" is meaningless in three months. Dates, versions, and exact identifiers.

Maintaining the ledger

  1. Update instead of duplicating. Before writing a new lesson, check whether an existing one covers the territory. Extend or correct that file rather than adding a near-copy beside it.
  2. Delete wrong lessons. When a recorded lesson turns out to be false or obsolete, remove it in the same session you discover this. A stale ledger is worse than no ledger, because it is trusted.
  3. Verify before applying. A lesson describes what was true when written. If it names a file, flag, or API, confirm that thing still exists before recommending or acting on it.

Using the ledger

  1. Read before similar work. At the start of a task, scan the summaries for anything touching the same system, tool, or failure class. Thirty seconds of reading routinely saves the hour the original lesson cost.
  2. Bootstrap from history. When first setting up a ledger on an existing project, review past sessions or commit history for recurring corrections and themes, and seed the ledger with them, so it starts useful instead of empty.

Read the full file on GitHub · 31 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. 7d ago First seen · 31 lines · 76 tokens per session scan A a8d1793a9133

Subscribe to this mod's changes

lessons-ledger is a skill published in the GitHub repository benjaminard/fable-skills (30 stars, last pushed 2mo ago), licensed MIT. It adds 76 tokens to every session and 629 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-30.

Related

Other skills, from other repositories

retrospective

Audit whether prior learnings actually fired, then convert this run's recurrences into installed mechanisms. Refuses to emit a finding without an install path and a firing test. Triggers: retrospective, reflect, what did we learn, patterns, synthesis, post-mortem, why does this keep happening.

ariaxhan/kernel-claude · 65 tokens

context-mgmt

Context engineering and token management. Compaction strategies, progressive disclosure, structured note-taking via AgentDB. Triggers: tokens, compaction, memory, handoff, summarize, context window.

ariaxhan/kernel-claude · 42 tokens

the-remembrall

Mine the repo's own session transcripts for places the human corrected the agent, cluster them, and derive which instruction is missing, wrong, or being ignored — the evidence-first inverse of every other pass, which read text and reason about it. Use for "what do I keep having to tell it", "why does it ignore that…

Totes-MickGOATs/opus-pocus · 162 tokens

the-room-of-requirement

Author a first memory file for a repo that has none — derived from the repo's actual build/test commands, its real conventions, and its correction history, never invented. The one generative pass in this book: it proposes a file, you approve it, exactly like any other fix-table row. Use for "this repo has no…

Totes-MickGOATs/opus-pocus · 169 tokens

obliviate-fossilium

Put memory files (CLAUDE.md, AGENTS.md) on a diet — find fossils (migration-relative phrasing, "this used to say X" narratives, dated retractions living in the hot path), typed facts that drift (hand-written counts, sizes, versions), and history that belongs in an archive. The 5-family reads the whole file every…

Totes-MickGOATs/opus-pocus · 163 tokens

accio-rulebook

Migrate path-bound instruction blocks out of the root memory file into scoped .claude/rules/ files with paths frontmatter, so rules load when Claude reads matching files instead of taxing every session. Use for "my CLAUDE.md has rules only relevant to one folder", "set up .claude/rules", "scope my rules to paths", or…

Totes-MickGOATs/opus-pocus · 155 tokens