claude-code-ultimate-guide/examples/memory/icm-session-starter.md
Florian BRUNIAUX f5d78e1004 release: v3.37.0 — MCP vs CLI landing page + guide section
- New guide section: guide/ecosystem/mcp-vs-cli.md (4 decision dimensions,
  15-row guidance table, token cost analysis, practitioner quotes)
- New landing page: cc.bruniaux.com/ecosystem/mcp-vs-cli/ (4 decision cards,
  collapsible guidance table, zero JS, WCAG-compliant badges)
- ICM v0.5.0 setup guide corrections + icm-session-starter.md template
- 3 resource evaluations: mcp2cli, MCPorter, CircleCI MCP vs CLI blog
- WP10 v1.2.0 DAF/finance feedback corrections (FR+EN)
- Recap cards EN translations (57 cards) + FR version bump 3.32.1 → 3.36.0
- Whitepapers v2.2: 7 WPs synced with guide v3.27.6 → v3.36.0 delta
- check-landing-sync.sh: section 7 for MCP vs CLI sync tracking
- docs/for-cto.md: whitepapers links updated to florian.bruniaux.com/guides

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-17 15:55:44 +01:00

2.4 KiB

ICM Session Starter

Paste this at the beginning of any Claude Code session to activate ICM context. Requires ICM installed and configured: brew tap rtk-ai/tap && brew install icm then icm init --mode mcp && icm init --mode hook && icm init --mode skill


Context — ICM (Infinite Context Memory) active in this session

ICM is installed and configured on this machine. Use it to store and retrieve persistent memory across sessions, bypassing context window limits.

Available MCP tools

The icm MCP server is running. You have access to 22 icm_* tools for storing, recalling, and managing persistent memory.

Direct CLI (via Bash if needed):

# Store a memory
icm store --topic "<project-slug>" --content "<fact>" --importance high|medium|low|critical

# Recall by semantic query
icm recall "<natural language query>"

# Inspect
icm stats          # count, topics, avg weight
icm topics         # list all topics
icm list           # list recent memories

# Manage
icm forget <id>    # delete by ID
icm decay          # apply temporal decay
icm prune          # remove low-weight entries

Important (v0.5.0 syntax):

  • --importance is an enum: critical / high / medium / low — not a float
  • No memory subcommand — use icm store, icm recall directly
  • Permanent knowledge graph: icm memoir (separate layer, no decay)

Slash commands

  • /recall <query> — search ICM memory
  • /remember <content> — store a memory in ICM

How memories work

Two layers:

  • Memories (episodic): timestamped entries with temporal decay based on importance. critical importance never decays. low fades over time.
  • Memoir (semantic): permanent knowledge graph with typed relations (depends_on, contradicts, superseded_by, part_of, and 5 others).

Search is hybrid: BM25 full-text (30%) + vector similarity (70%).

A PostToolUse hook runs automatically — every N tool calls, ICM extracts context and stores it without any explicit action from you.

Suggested usage in this session

# At session start — recall relevant context
icm recall "<current feature or topic>"

# When making a key decision
icm store --topic "<project>" --content "<decision and rationale>" --importance high

# For permanent architectural facts
icm memoir add-concept -m "<project>" -n "<concept>"

DB location

~/Library/Application Support/dev.icm.icm/memories.db