AGENT SKILL

compiler

Compile and search Claude Code conversation logs with algorithmic summarisation and BM25-ranked recall.

License 许可
MIT
最近更新
2026-09-14
Stars
★ 0
Forks
0

01 前言 Front Matter

name
compiler
description
Compile and search Claude Code conversation logs with algorithmic summarisation and BM25-ranked recall.

03 SKILL.md 正文

Workflow

After /compact — recover context

A structured summary is automatically injected into context after every compaction (SessionStart hook). No manual step needed.

To refresh it manually:

mm compile --brief path/to/current-session.jsonl

/mm:recall — search current session with ranking

mm search path/to/current-session.jsonl --query "keyword"

For regex patterns:

mm search path/to/current-session.jsonl --query "hook|inject"

/mm:searchchat — search across sessions

cd ~/.claude/projects/<project> && mm search "*.jsonl" --query "keyword"

For broader search into subagents:

cd ~/.claude/projects/<project> && mm search "**/*.jsonl" --query "keyword"

/mm:readchat — read a specific session

mm compile path/to/session.jsonl

For a quick overview instead of full transcript:

mm compile --brief path/to/session.jsonl

Commands

Command Description
mm compile <paths> Full transcript with line numbers
mm compile --brief <paths> Structured summary — goals, files, commits, preferences + brief transcript
mm compile --keep N <paths> Summary + last N user turns kept verbatim
mm search <paths> --query "..." BM25-ranked search with line snippets
mm search <paths> --query "." --page N Paginate all results
mm search <paths> --query "..." --json JSON output with scores and match counts

Rules

  • Forward slashes only in bash commands — even on Windows.
  • Do NOT use grep on JSONL files. Always use mm search.
  • After /compact, a structured summary is automatically injected into context (SessionStart hook). Run mm compile --brief manually only to refresh it.
  • For regex patterns, use standard syntax: hook|inject, fail.*build, auth.*token.

04 同仓库更多 Skills