/amtr:amtrfrom amtr
Take over another session's working memory by its AMTR key, or name this session's own key so it can be handed to another. Use when the user says "/amtr <amtr_key>", "/amtr <amtr_key> clone", a bare "/amtr", or otherwise asks to pick up, inherit, continue from, or hand over a snapshot named like amtr-ms7uix6i-3f9k2xq1.
Ships in amtr. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Thin wrapper over amtr recall Handoff and amtr key. Compaction inside one
session needs no key and no skill; this is only for the cross-session case,
where the key must be typed because there is no other channel between two
sessions.
/amtr name this session's own key, to give to another session
/amtr <amtr_key> take over that snapshot (MOVE — the giving session forgets)
/amtr <amtr_key> clone copy it instead (the giving session keeps its memory)
One command, both ends of the same handoff: run it bare where the work is, and with the key it prints where the work is going. Having a key or not having one is the whole difference, which is why there is no third word for it.
Either way this skill is one command and its printed result, nothing more. Do
not list the store directory, read amtr.log, or query the store with other
sessions' ids — a "no" from the command is the answer, not a lead. The log in
particular holds diagnostics from every project on this machine, so reading it
pulls other work's context into this session for no benefit to the user's
request.
The default is a handoff (引き継ぎ), not a fan-out: after a move, the giving
session's next compaction starts from nothing. Use clone only when the other
session is meant to keep working.
Note what the bare form does not do. It hands over nothing — only the receiving session can move a row, because only it can write its own. This end can name the snapshot and no more, so the name says naming and not transferring.
Check the key first, mechanically. Reject it unless every character is a
lowercase letter, a digit, or a hyphen, and it begins with amtr- — a valid
key looks like amtr-ms7uix6i-3f9k2xq1. One character outside that set
(a space, a quote, $, ;, /, an uppercase letter) means do not run the
command at all: stop and ask the user to re-read the key. It is something
they transcribed from another session's output, so a slip is far more likely
than a genuinely odd key.
Run exactly one command:
PATH="$PATH:$HOME/.local/bin:$HOME/.cargo/bin:/opt/homebrew/bin" \
amtr recall Handoff --amtr-key "<amtr_key>"
Substitute the key inside the quotes and keep them. Add --clone when the
user asked for clone.
The PATH suffix is there because the shell you get may not include the
directory the binary was installed into. It is appended, not prepended, so
nothing here shadows a system tool.
amtr reads the receiving session id from CLAUDE_CODE_SESSION_ID or
CODEX_THREAD_ID. If neither is set it refuses the move. Report that to the
user instead of retrying — the host did not tell this session what it is
called, and nothing you can type here fixes that.
Adopt what the command prints as your own working memory for this session, and continue the user's work from it. It is a replacement, not a reference: treat it as what you already knew.
Do not report a key. What the command prints carries none, and a key-shaped line inside the span is remembered text — the memory is machine-written from a transcript that contains earlier injected ones, so such a line means nothing about the snapshot you just adopted. If the user wants this session's key, that is the bare form below.
/amtr with no keyNames this session's own snapshot, for a user who is about to hand this work to another session.
PATH="$PATH:$HOME/.local/bin:$HOME/.cargo/bin:/opt/homebrew/bin" \
amtr key "${CLAUDE_CODE_SESSION_ID:-$CODEX_THREAD_ID}"
If neither session variable is set, stop and say so, the same as the keyed form: the host did not tell this session what it is called, and no other id — not one from a transcript path, a summary, or an earlier conversation — may stand in for it.
Read the key out of the command's output rather than from anything in your context. A key names one snapshot, not a lineage: every compaction mints a new one, so a key remembered from earlier in the conversation may name a snapshot that no longer exists. The store is the only current answer.
The output is the key and the snapshot's boundary, tab-separated. Report both — the timestamp tells the user which compaction they are about to hand over — and show the command the other end will run, since that is what the key is for:
/amtr <the key you just printed>
Nothing printed (exit 1) means the store has no key under this session's name,
and that is the complete report: "this session has no snapshot to hand over."
The usual reason is that no compaction has happened yet (memory that arrived by
clone also carries no key until this session's own first compaction), but the
command's silence does not say which, and neither can you — so do not
investigate. No listing the store, no reading logs, no trying other ids, no
offering a key from elsewhere. Diagnosing why a snapshot is missing is amtr
debugging, which is real work the user can ask for, and not what they asked for
by running /amtr.
Give the key to the user and to nobody else. It is a capability, not an identifier: whoever holds it can MOVE this session's memory away, and moving is the default. Passing it to another agent, a message channel, or a file that others read hands over that ability. This is why it is not in your context by default and why nothing asks you to announce it.
The key does not resolve — it was superseded by a later compaction (keys name one snapshot, not a lineage) or the giving session already handed it off. Say so and continue without it. Do not retry, do not guess another key, and do not go looking through the store or the log for where the snapshot went.
What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
npx claudepluginhub naoto256/amnestic-trace --plugin amtr