save-memory

save-memory is a skill for Claude Code from TOKTOKHAN-DEV/agent-company. It costs 59 tokens per session (1,084 once invoked), scanned A, original, MIT.

A session-memory workflow for recording important decisions, preferences, blockers, and next steps so later sessions can continue with the right context.

In plain words
What is it for?
Use it after important decisions, when you learn a user preference, or when work is blocked. It creates or updates short-term and long-term memory notes and can promote stable knowledge to a project wiki.
Why use it?
It prevents useful context from being lost or duplicated between sessions. It also helps separate temporary notes from information that should become lasting project documentation.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter.

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 skills/toktokhan-dev/agent-company/save-memory
Any agent
npx skills add TOKTOKHAN-DEV/agent-company --skill save-memory
Clone the repo
git clone --depth 1 https://github.com/TOKTOKHAN-DEV/agent-company

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 save-memory

README.md
[![agentmods](https://agentmods.dev/badge/skills/toktokhan-dev/agent-company/save-memory.svg)](https://agentmods.dev/skills/toktokhan-dev/agent-company/save-memory)
Your own site
<a href="https://agentmods.dev/skills/toktokhan-dev/agent-company/save-memory"><img src="https://agentmods.dev/badge/skills/toktokhan-dev/agent-company/save-memory.svg" alt="Measured on agentmods" height="20"></a>
Per session 59 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,084 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.00059 $0.01084
Opus 5 $0.00030 $0.00542
Sonnet 5 $0.00012 $0.00217
Haiku 4.5 $0.00006 $0.00108

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

Security

Grade A, and why

save-memory 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.

.claude/skills/save-memory/SKILL.md · 101 lines

What it actually says

/save-memory

세션의 맥락을 다음 세션이 이어받을 수 있는 형태로 남긴다.

1단계 — 무엇을 저장할지 고른다

이번 세션에서 다음에 해당하는 것을 찾으세요.

저장한다 저장하지 않는다
판단의 근거 — 왜 A 대신 B를 골랐나 코드를 읽으면 알 수 있는 것 (구조, 시그니처)
검토했지만 버린 대안 git log 가 이미 기록한 것
사용자의 선호와 제약 이번 세션에서만 의미 있는 임시 상태
막힌 지점과 그 이유 이미 wiki 에 있는 내용
다음 세션이 이어서 해야 할 것 일반적인 기술 지식

저장할 것이 없으면 없다고 말하고 끝내세요. 억지로 만든 메모리는 다음 세션의 노이즈입니다.

2단계 — 기존 메모리와 대조

ls wiki/memory/short-term/ wiki/memory/long-term/

같은 주제의 파일이 있으면 새로 만들지 말고 그 파일을 갱신하세요. 중복 메모리는 서로 어긋나면서 어느 쪽이 맞는지 알 수 없게 만듭니다.

내용이 틀린 것으로 밝혀진 메모리는 삭제하세요. 오래된 메모리보다 틀린 메모리가 위험합니다.

3단계 — 단기 메모리 작성

pnpm memory:new <kebab-case-topic>

스크립트가 템플릿에서 파일을 만들고 경로를 출력합니다. 그 파일을 채우세요.

  • 한 파일에 한 주제. 세션 요약을 뭉뚱그리지 마세요.
  • 상대 날짜 금지. "어제" 대신 2026-07-27.
  • type 을 정확히: decision / observation / preference / blocker / progress
  • 를 반드시 남기세요. 무엇을 했는지는 git 이 압니다.

4단계 — 승격 판단

단기 ──(3회 이상 참조 / 계속 참으로 확인)──▶ 장기 ──(프로젝트 규칙이 됨)──▶ wiki

단기 → 장기

다음 중 하나면 승격합니다.

  • 같은 내용이 세 번 이상 참조되었다
  • 프로젝트가 존재하는 한 계속 참이다
  • 사용자 선호로 확인되었다 (type: preference 는 승격 1순위)
pnpm memory:new <topic> --long

내용을 옮기고, 원본 단기 메모리에 promoted: true 를 설정한 뒤, wiki/memory/index.md 에 한 줄을 추가하세요. 이 갱신을 빠뜨리면 SessionStart 훅이 그 메모리를 로드하지 않습니다.

장기 → wiki

다음 중 하나면 wiki 문서나 ADR 로 승격합니다.

  • 다른 사람이나 에이전트가 따라야 할 규칙이 되었다 → wiki/0N-*.md 갱신
  • 되돌리기 어려운 아키텍처 결정이다 → wiki/decisions/ADR-NNNN-*.md 신규 작성

wiki 로 승격했으면 wiki/06-history.md 에 타임라인 항목을 추가하세요.

5단계 — 정리

30일이 지난 type: progress 메모리 중 완료된 것은 삭제합니다. 해결된 blocker 도 삭제하거나 결과를 담아 decision 으로 바꿉니다.

find wiki/memory/short-term -name '*.md' -mtime +30

삭제 전에 사용자에게 목록을 보여주고 확인받으세요.

6단계 — 보고

무엇을 저장했고 무엇을 승격했는지 한 문단으로 요약합니다. 파일 경로를 포함하세요.

하지 말아야 할 것

  • 메모리 파일에 코드를 복사해 넣지 마세요. 경로와 판단 근거만 남깁니다.
  • wiki/memory/index.md 에 메모리 본문을 쓰지 마세요. 한 줄 링크만입니다.
  • 확신 없는 내용에 confidence: high 를 붙이지 마세요.
  • 사용자 확인 없이 wiki 의 기존 문서를 크게 고치지 마세요. 갱신 제안을 먼저 하세요.
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. 6d ago First seen · 101 lines · 59 tokens per session scan A 1d28e7aadee8

Subscribe to this mod's changes

save-memory is a skill published in the GitHub repository TOKTOKHAN-DEV/agent-company (75 stars, last pushed 9d ago), licensed MIT. It adds 59 tokens to every session and 1,084 once invoked, about $0.0003 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.