lessons

lessons is a command for Claude Code from sifxprime/kodelyth-ecc. It costs 38 tokens per session (840 once invoked), scanned A, original, MIT.

A cross-platform command for loading and maintaining project lessons stored in a tasks/lessons.md file.

In plain words
What is it for?
Use it to view active lessons, save corrections from a session, add a rule manually, or clear selected lessons.
Why use it?
It makes project-specific corrections and working rules available in future sessions, reducing repeated mistakes and reminders.

Command for Claude Code

Written for Claude Code: $ARGUMENTS substitution. Also seen: mentions Claude Code; mentions Codex; mentions OpenCode.

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 commands/sifxprime/kodelyth-ecc/lessons
Clone the repo
git clone --depth 1 https://github.com/sifxprime/kodelyth-ecc

Made for: Claude Code.

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

README.md
[![agentmods](https://agentmods.dev/badge/commands/sifxprime/kodelyth-ecc/lessons.svg)](https://agentmods.dev/commands/sifxprime/kodelyth-ecc/lessons)
Your own site
<a href="https://agentmods.dev/commands/sifxprime/kodelyth-ecc/lessons"><img src="https://agentmods.dev/badge/commands/sifxprime/kodelyth-ecc/lessons.svg" alt="Measured on agentmods" height="20"></a>
Per session 38 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 840 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.00038 $0.00840
Opus 5 $0.00019 $0.00420
Sonnet 5 $0.00008 $0.00168
Haiku 4.5 $0.00004 $0.00084

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

Security

Grade A, and why

lessons 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 2d 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.

commands/lessons.md · 93 lines

How it starts

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

/lessons — Project Self-Improvement

Cross-platform command for the Compound Learning System. Works everywhere, with or without hooks.

Usage

/lessons              → load and show all lessons for this session
/lessons save         → extract corrections from this session and write to tasks/lessons.md
/lessons add "<rule>" → add a manual rule immediately
/lessons clear        → show lessons and ask which to remove

What This Command Does

/lessons (no args) — Load lessons

  1. Check if tasks/lessons.md exists in the project root
  2. Read all lesson rules (lines starting with -)
  3. Inject them as PROJECT LESSONS — HARD RULES for this session
  4. Print a summary of how many rules are active
  5. Apply them immediately — do not wait for another message

If tasks/lessons.md does not exist yet, say:

"No lessons file found. Corrections you give me this session will build it. Run /lessons save at the end of the session to write them."

/lessons save — Capture session corrections

Scan the current conversation for user corrections:

  • Phrases matching: "no don't", "use X instead", "stop doing Y", "wrong approach", "we always", "we never", "I told you", "that's not how we", "use X not Y"
  • Extract each as a plain-language rule
  • Show the extracted rules to the user before writing
  • Ask: "Write these N rules to tasks/lessons.md?"
  • On confirmation: create tasks/ if needed, append rules with today's date

/lessons add "<rule>" — Add a manual rule

Immediately append the rule to tasks/lessons.md:

## 2026-05-06
- <rule>

Confirm: "Rule added. It will be active from the next session (or reload with /lessons)."

/lessons clear — Review and prune

Show all current rules numbered. Ask: "Which numbers to remove? (e.g. 1,3,5 or 'all')" Remove selected lines and rewrite the file.

Format of tasks/lessons.md

# Claude Lessons

Project: **project-name**

Auto-generated by Kodelyth ECC. Edit freely — add, remove, reword. These are YOUR rules.

---

## 2026-05-06

- use pnpm not npm
- never add try/catch without logging the error first
- we use Zod for validation, not Yup

## 2026-05-10

- component files go in src/components, not src/app
- always use early returns, never deeply nested if blocks

Read the full file on GitHub · 93 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. 2d ago First seen · 93 lines · 38 tokens per session scan A 0885172aa6d6

Subscribe to this mod's changes

lessons is a command published in the GitHub repository sifxprime/kodelyth-ecc (11 stars, last pushed 3d ago), licensed MIT. It adds 38 tokens to every session and 840 once invoked, about $0.0002 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-09-03.