Borrowing it
Nothing to install: this file belongs to Chachamaru127/codex-harness. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/Chachamaru127/codex-harness/main/.codex/skills/session-memory/SKILL.mdgit clone --depth 1 https://github.com/Chachamaru127/codex-harnessWrote 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/chachamaru127/codex-harness/session-memory)<a href="https://agentmods.dev/skills/chachamaru127/codex-harness/session-memory"><img src="https://agentmods.dev/badge/skills/chachamaru127/codex-harness/session-memory/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/chachamaru127/codex-harness/session-memory"><img src="https://agentmods.dev/badge/skills/chachamaru127/codex-harness/session-memory.svg" alt="Reviewed on agentmods" width="80" 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.00052 | $0.02405 |
| Opus 5.5 | $0.00021 | $0.00962 |
| Sonnet 5.5 | $0.00010 | $0.00481 |
| Haiku 4.5 | $0.00005 | $0.00241 |
Grade B, and why
session-memory scanned grade B with 1 finding 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 1mo 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.
Reads agent configuration directoriesmediumAgent snooping
.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.
tail -50 .claude/state/agent-trace.jsonl | jq -r '.files[].path' | sort -u How it starts
The opening of the file, as written. The whole thing — 269 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Session Memory Skill
セッション間の学習と記憶を管理するスキル。 過去の作業内容、決定事項、学んだパターンを記録・参照します。
トリガーフレーズ
このスキルは以下のフレーズで自動起動します:
- 「前回何をした?」「前回の続きから」
- 「履歴を見せて」「過去の作業」
- 「このプロジェクトについて教えて」
- "what did we do last time?", "continue from before"
概要
このスキルは .claude/memory/ に作業履歴を保存し、
セッション間での知識の継続を実現します。
あわせて、重要な情報は「どこに残すべきか」を明確にします(詳細: docs/MEMORY_POLICY.md)。
メモリ構造
.claude/
├── memory/
│ ├── session-log.md # セッションごとのログ
│ ├── decisions.md # 重要な決定事項
│ ├── patterns.md # 学んだパターン
│ └── context.json # プロジェクトコンテキスト
└── state/
└── agent-trace.jsonl # Agent Trace(ツール実行履歴)
推奨運用(SSOT/ローカル分離)
- SSOT(共有推奨):
decisions.md/patterns.md- 「決定(Why)」と「再利用できる解法(How)」を集約する
- 各エントリは タイトル + タグ(例:
#decision #db)を付け、先頭に Index を置く
- ローカル推奨:
session-log.md/context.json/.claude/state/- ノイズ/肥大化しやすいため、基本は Git 管理しない(必要なら個別に判断)
自動記録される情報
session-log.md
各セッション記録には ${CLAUDE_SESSION_ID} 環境変数を活用してセッションIDを付与します。
これにより、セッション間のトレーサビリティが向上します。
## セッション: 2024-01-15 14:30 (session: abc123def)
### 実行したタスク
- [x] ユーザー認証機能の実装
- [x] ログインページの作成
### 生成したファイル
- src/lib/auth.ts
- src/app/login/page.tsx
### 重要な決定
- 認証方式: Supabase Auth を採用
### 次回への引き継ぎ
- ログアウト機能が未実装
- パスワードリセットも必要
Note:
${CLAUDE_SESSION_ID}は Claude Code が自動設定する環境変数です。 セッションごとに一意のIDが割り当てられ、ログの追跡や問題調査に役立ちます。
decisions.md
## 技術選定
| 日付 | 決定事項 | 理由 |
|------|---------|------|
| 2024-01-15 | Supabase Auth | 無料枠あり、セットアップ簡単 |
| 2024-01-14 | Next.js App Router | 最新のベストプラクティス |
## アーキテクチャ
- コンポーネント: `src/components/`
- ユーティリティ: `src/lib/`
- 型定義: `src/types/`
patterns.md
## このプロジェクトのパターン
### コンポーネント命名
- PascalCase
- 例: `UserProfile.tsx`, `LoginForm.tsx`
### API エンドポイント
- `/api/v1/` プレフィックス
- RESTful 設計
### エラーハンドリング
- try-catch で囲む
- エラーメッセージは日本語
context.json
{
"project_name": "my-blog",
"created_at": "2024-01-14",
"stack": {
"frontend": "next.js",
"backend": "next-api",
"database": "supabase",
"styling": "tailwind"
},
"current_phase": "フェーズ2: コア機能",
"last_session": "2024-01-15T14:30:00Z"
}
What ships with it
1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
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.
- 1mo ago First seen · 269 lines · 52 tokens per session scan B 5f5d0a1615dd
session-memory is a skill published in the GitHub repository Chachamaru127/codex-harness (2 stars, last pushed 8mo ago), licensed MIT. It adds 52 tokens to every session and 2,405 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it B with 1 finding (reads agent configuration directories). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
knowledge-ingest
Ingest documents, articles, conversations, or supplied text into Knowledge with retained originals, sourced claims, entity updates, timelines, and cross-links; also learn durable lessons from a set of conversations, transcripts, or past sessions (/learn), including the Learn from conversations and Learn from Memory…
forget
Remove a personal fact, preference, relationship detail, topic, or prior event from Muse's active memory and stop existing copies or automations from bringing it back. Use for explicit requests such as 'forget that', 'don't remember this about me', or 'remove that from your memory'. Do not use when 'forget it' merely…
mem0-oss-to-platform
Plan, then execute, a migration of a project from the mem0 open-source / self-hosted SDK (local Memory class) to the mem0 Platform / hosted SDK (MemoryClient). TRIGGER when: the developer wants to move, switch, or migrate mem0 off OSS/self-hosted to the hosted API, e.g. "migrate my mem0 setup to the platform", "switch…
Cortex
LifeOS memory, prior-session recall, and learning capture. USE WHEN capture this learning, document this learning, what did we learn recently, recent learnings, cortex, knowledge, knowledge base, search knowledge, what do we know about, archive, harvest, knowledge status, develop note, add to knowledge, add a people…
memory
Use when the user asks to remember, recall, forget, update, search, or inspect durable OpenSquilla memory, including profile facts in USER.md and long-term notes in MEMORY.md or memory//.md.
ha-data-stores
Map of Hope Agent's local data stores and safe read-only query workflow. Use when the user asks where Hope Agent stores data, wants to inspect sessions/messages/memory/logs/background jobs/knowledge indexes/settings, asks the model to query local app data, or debugging requires checking persisted state. Trigger…