Reading history
agit log — turn by turn
agit log # current session's branch
agit log exp # another branch
agit log alice/photo@exp # someone else's
One line per turn commit: turn number, short SHA, message (the prompt’s first
72 chars). Milestones stand out. Use -v/--context to see events inside a
turn.
agit show — one point, readable
agit show exp#12 # turn 12 rendered as a conversation
agit show exp#12.3 # just event 3 of turn 12 (a tool call, a file write…)
agit show exp:path # a file as of that point
agit diff — what changed between two points
agit diff exp#10 exp#14
Shows new turns between the two, plus shared-file changes (memory/, skills/).
agit view — what the session actually sees
agit view exp # VIEW composition, event by event
agit view exp --json # for tooling
The VIEW is what gets materialized when a session resumes. Marker and summary envelopes (from merges) are part of it. If you want to know “what will the agent see when it wakes up”, this is the answer.
Reference syntax, all of it
| Shape | Meaning |
|---|---|
exp, agit-91c7faef | branch head / commit SHA |
exp#12 · exp#-1 | turn 12 · latest turn |
exp#12.3 | event 3 inside turn 12 |
exp#4..#9 | turns 4 through 9 |
owner/repo@exp | any published line |
exp:path | file content at that point |
@ | your current session |
@exp | your session, arbitrated onto branch exp |
You can mix: alice/photo@exp#12.3 is a legal address.
agit search
agit search "rate limit retry" # has anyone done this?
agit search "表3" --repo alice/photo
Searches the corpus you can read (public agents + your privates). The primary entry point is MCP — an agent asks mid-run without leaving its runtime.
agit export
agit export exp --format markdown -o out.md
agit export exp#4..#9 --format jsonl
Formats: jsonl (raw envelopes), ir, markdown, claude-code, codex.
--view-only exports only what the session sees; --redact masks secrets on
the way out.