mirror of
https://github.com/alirezarezvani/claude-skills.git
synced 2026-10-08 03:07:51 +00:00
Turns DESIGN.md from a spec into a working plugin. Five stdlib scripts, three
hooks, agent, command, three references, plugin manifests.
The gates are the design:
L1 -> L2 >= 3 distinct sessions spanning >= 2 distinct calendar days
(`stated` = 2 sessions, day rule still applies; `verified` = 1
observation and is the only day-exempt path)
L2 -> L3 >= 2 distinct projects, >= 30 days, uncontested
Two gates refuse rather than guess. `redacted: true` blocks promotion on any
volume of evidence -- a durability-independent barrier, since a secret restated
across five sessions passes every recurrence gate; the flag firing means the
text was altered, a lexical filter finding one secret is not proof it found all
of them, and L2/L3 are committed to git. An open contradiction freezes both
claims, found by reverse join because the newer atom carries no flag.
All three hooks fail open: a broken memory system costs memory, never a session.
SessionEnd stages promotions to .memory/staged/ and never touches a CLAUDE.md;
only an explicit human adopt does, after backing both files up.
Verified, not asserted:
- all three pinned atom ids from DESIGN.md reproduce exactly
- both blocking gates demonstrated on sample input, named in the output
- end-to-end: two transcripts across two calendar days -> merged L1 atom ->
staged L2 promotion with the path prefix stripped
- reverse join blocks the unflagged newer atom
- cross-tier L2/L3 collision marked at injection time
- recall p50 29ms / p95 31ms / max 35ms spawn-to-exit, scoring itself 2-3ms
over 500 atoms -- interpreter cold start is the entire cost
- validate_examples.py 69 checks 0 failures; SKILL.md 6/6 PASS
- derive_counters --check, check_plugin_json --all, check_paths all clean
DESIGN.md 10.1's "+6" tool estimate corrected to +8 -- the delivered surface is
5 scripts + 3 hooks. README.md's deviations list is authoritative for that and
five other divergences from the pre-implementation spec.
Concept from TencentCloud/TencentDB-Agent-Memory (MIT). No upstream code.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01EM5xmJ7AmTMg31rq68BCym
15 lines
1.6 KiB
JSON
15 lines
1.6 KiB
JSON
{
|
|
"name": "agent-memory",
|
|
"description": "A four-tier memory ladder for Claude Code where promotion is earned by recurrence, not asserted by confidence. L0 raw transcripts are never injected; L1 candidate atoms are gitignored and recalled on lexical relevance per prompt; L2 project context loads once per session; L3 stable persona is always loaded. Promotion from L1 to L2 requires at least three distinct sessions spanning at least two distinct calendar days (a stated claim needs two sessions, still spread across days; a deterministically verified claim is the only single-observation path), and L2 to L3 requires two distinct projects and thirty days. Two gates refuse rather than guess: a claim whose text was altered by the seventeen-pattern redaction pass never promotes on evidence alone, and a claim with an open contradiction freezes until a human resolves it, found by reverse join because the newer atom carries no flag. Three hooks run the loop unattended and every one fails open. Nothing reaches a committed CLAUDE.md without an explicit human adopt that backs both files up first. Ships five stdlib scripts, three hooks, a cs-memory-curator agent, a /cs:memory command, a JSON schema, a sixty-nine-check example validator, and a design document with its open decisions ranked by what they gate.",
|
|
"version": "2.11.2",
|
|
"author": {
|
|
"name": "Alireza Rezvani",
|
|
"url": "https://alirezarezvani.com"
|
|
},
|
|
"homepage": "https://github.com/alirezarezvani/claude-skills/tree/main/engineering/agent-memory",
|
|
"repository": "https://github.com/alirezarezvani/claude-skills",
|
|
"license": "MIT",
|
|
"skills": [
|
|
"./skills/agent-memory"
|
|
]
|
|
}
|