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.
npx agentmods add skills/topprismdata/cultivating-ml-agent/agent-session-memory-protocolnpx skills add topprismdata/cultivating-ml-agent --skill agent-session-memory-protocolgit clone --depth 1 https://github.com/topprismdata/cultivating-ml-agentWrote 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/skills/topprismdata/cultivating-ml-agent/agent-session-memory-protocol)<a href="https://agentmods.dev/skills/topprismdata/cultivating-ml-agent/agent-session-memory-protocol"><img src="https://agentmods.dev/badge/skills/topprismdata/cultivating-ml-agent/agent-session-memory-protocol.svg" alt="Measured on agentmods" 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.00130 | $0.01822 |
| Opus 5 | $0.00065 | $0.00911 |
| Sonnet 5 | $0.00026 | $0.00364 |
| Haiku 4.5 | $0.00013 | $0.00182 |
Grade A, and why
agent-session-memory-protocol 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 6d 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 — 182 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Agent Session Memory Protocol
Problem
Long-running Kaggle experiments span hours to days. Between sessions:
- Agent forgets what was tried and why
- Submissions and their OOF/LB pairs get lost
- Dead ends get repeated
- Handoff to a new session loses critical context
The 4-File Session Memory Structure
Create a session directory per experiment session:
~/.claude/projects/<project>/sessions/
└── <YYYYMMDD_HHMMSS>/
├── session_state.md # Goal, subtask, status, plan, blockers, next actions
├── timeline.md # Append-only log of actions, commands, results
├── experiments.md # Structured table of all submissions/attempts
└── handoff.md # Concise resume instructions for next session
File 1: session_state.md
# Session State
- Session: 20260708_140000
- Project: pokemon-tcg-ai-battle
- Started: 2026-07-08 14:00
- Updated: 2026-07-08 18:30
## Goal
Optimize PTCG agent to reach top 200 on the leaderboard.
## Current Subtask
Waiting for Nithin A/B convergence after 07-06 re-submit (μ₀=600 reset).
## Status
- Nithin A: LB 869 (converging from 600, +17/day)
- Nithin B: LB 772 (converging from 600, +2.5/day)
- Latest-2 = Nithin A + Nithin B (both in final-2 slots)
## Plan
1. WAIT — do not re-submit (resets convergence)
2. Check LB daily until ~Jul 20 (expected ~950/910)
3. Aug 10-14: submit 2 copies of best agent (high-roll)
## Blockers
- GPU quota exhausted (30h/week) — blocks Biohub, Industrial T1, ARC-AGI-3
## Next Actions
- [ ] Jul 13: Check PTCG LB (expected Nithin A ~920)
- [ ] Jul 20: Check PTCG LB (expected Nithin A ~950)
- [ ] Aug 10: Begin high-roll duplicate submissions
File 2: timeline.md
# Timeline (append-only)
## 2026-07-08 14:00 — Session Start
- Recalled AutoMem: 109 memories, PTCG status, ROGII Pipeline A
## 14:15 — PTCG Check
- Nithin A: 869.2 (+17 from yesterday)
- Nithin B: 772.3 (+2.5)
- Decision: WAIT, no re-submit
## 14:30 — ROGII Pipeline A
- Pushed rogii-pipea-only kernel (Pipeline B trimmed)
- Kernel COMPLETE, submission.csv written (14152 rows)
- Manual Submit to Competition required
## 15:00 — ROGII Score
- LB: 19545.46 (TERRIBLE — predicted values include -27561 outliers)
- Root cause: Pipeline A predictions have negative TVT values for some rows
- Old v7 (13.82) still better than Pipeline A on LB
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.
- 6d ago First seen · 182 lines · 130 tokens per session scan A 35ca27ccd3ee
agent-session-memory-protocol is a skill published in the GitHub repository topprismdata/cultivating-ml-agent (5 stars, last pushed 9d ago), licensed MIT. It adds 130 tokens to every session and 1,822 once invoked, about $0.0006 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-31.
Other skills, from other repositories
Context Doctor
Identify and repair degradation in system prompt, external memory, and skills preventing you from following instructions or remembering information as well as you should.
memanto-companion
Inspect and manage the cross-session engineering memory that Memanto maintains for your Claude Code skills. Use when the user asks what Memanto remembers, wants to see their engineering profile, manually recall context for a skill, or store a decision. The automatic lifecycle hooks handle capture/injection on their…
system-monitor
Monitor system health: CPU, memory, disk, processes, and network. Alert on thresholds via any channel.
mnemon
Persistent memory CLI for LLM agents. Store facts, recall past knowledge, link related memories, manage lifecycle.
init
Install or update OwnMem in the current repository. Use when the user asks to set up OwnMem, add local project memory for coding agents, or refresh an existing OwnMem installation after a version bump.
prolong
Recover and use durable coding-session history from PRO-LONG's local append-only log. Use on long-running coding tasks, after context compaction or session resume, when reconstructing prior decisions or tool results, or before repeating work that may already have been attempted.