agentleFS
ro-agro-ag/ai/skills/memento/SKILL.md

memento

Skill0 starsChanged 3 months agoMITView on GitHub

Use when the user corrects a repeated behavior ("again?", "I told you", "stop doing that"), when an approach fails repeatedly before a fix is found, when a quality gate is skipped (coverage, complexity, lint), when discovering a project-specific workaround — and at task start, to load past lessons before choosing an approach.

5 other projects use a version of this.

Adopted by

Most recently taken up by

  • Other versions5 projects use a version of this.

    Word for word · 0

    None found.

    Edited · 0

    None found.

    Wrote their own version · 5

    1. howells/skills★ 5same name
    2. catcatcatstudio/cat-skills★ 3same name
    3. waterdrop26651/Memento-skill★ 3same name
    4. ruslanlap/memento★ 1same name
    5. Lego1997/memento★ 0same name

    How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.

  • In this repository3 other files it gives its agents.

The file

We split this skill into the rules it gives an agent

3 rules. 0 are common, 1 is distinctive, and 2 are very specific to this project.

  • 0

    Common

    Most of the 4 edited versions we read keep these.

  • 1

    Distinctive

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Run before choosing tools or approach.

    line 28
  2. Very specific:

    Run memento list first — recurrence means reusing the same slug.

    line 34
  3. Very specific:

    If ~/.agents/memento/memento.py does not exist, read BOOTSTRAP.md next to this file and copy its code block verbatim to that path.

    line 72

“Common” is measured: kept by at least 6 in 10 of the 4 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Memento

Cross-agent mistake ledger: log repeated mistakes, count recurrence and cost, promote repeat offenders into enforced rules. Any tool that reads markdown can use it.

The CLI owns all bookkeeping. Never hand-edit ledger entries, never count occurrences yourself.

python3 ~/.agents/memento/memento.py <cmd>

Stdlib-only — plain python3, never uv run. (Exception: inside ~/dev/ai, uv run memento is the same script.)

Ledgers: global ~/.agents/memento/MEMENTO.md, project <git root>/MEMENTO.md.

Protocol: CONSULT → LOG → PROMOTE

1. CONSULT (task start)

memento check

Run before choosing tools or approach. ENFORCED entries are law. WATCHING entries are strong defaults — deviating without cause is how the mistake repeats.

2. LOG (on trigger)

Triggers: the user corrects you (especially "again", "I told you") · an approach fails repeatedly before a fix works (log the fix — that is the valuable part) · a quality gate is skipped or ignored · you discover the way that actually works in this project.

Run memento list first — recurrence means reusing the same slug. Then:

memento hit <slug> [--rule "..."] [--fix "..."] [--kind habit|trick|gate|project-way] [--scope global|project] [--cost MIN]
  • New slug requires --rule: one enforceable sentence.
  • --fix: the exact command/env var/edit that worked. "Fixed the SSL issue" is useless next month.
  • --scope: applies in other repos → global; only here → project.
  • --cost: minutes lost this occurrence (feeds the memento top pain ranking).
  • The CLI warns about similar existing slugs and prints a PROMOTE alert at 3 hits or ≥30 min in one hit.

3. PROMOTE (enforcement)

On a PROMOTE alert, or when the user says "always" / "never":

memento promote <slug>

Writes the rule bullet into a dedicated ## Memento-enforced section (other sections untouched): global scope → AGENTS.md + CLAUDE.md in the rules dir (env MEMENTO_AI_DIR, else rules_dir in ~/.agents/memento/config.json); project scope → the project's AGENTS.md (created if missing) + CLAUDE.md if present. The ledger keeps history and the detailed fix; the enforcement doc gets only the rule.

Obsolete rule (tool fixed, project dead, user says so): memento retire <slug> — removes the bullet, keeps ledger history, drops it from check. A later hit revives it to watching.

Common mistakes

MistakeFix
Lesson only stated in the chat replyChat dies with the session. memento hit or it didn't happen.
Hand-editing MEMENTO.md / counting yourselfThe CLI owns bookkeeping. Judgment (rule, fix, scope) is yours; arithmetic is not.
Logging straight into AGENTS.md/CLAUDE.mdThose are enforcement docs, not history. hit first; promote when earned.
New slug per occurrencememento list first; recurrence = same slug. Duplicates break rate tracking.
Vague fix ("fixed certs")Record the exact command/env var/edit that worked.
Skipping memento check at task startThat is precisely how mistakes repeat.
Promoting on first occurrenceOne-offs pollute enforcement docs. Thresholds exist; user "always/never" overrides them.

Bootstrap

If ~/.agents/memento/memento.py does not exist, read BOOTSTRAP.md next to this file and copy its code block verbatim to that path. Never open BOOTSTRAP.md otherwise — it is only the embedded script source.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.