Reference
Command reference
Commands and flags for opening, listing, searching, filtering, slicing, splitting, exporting, and inspecting transcripts.
Root
agentscript --help
agentscript --version
Open
agentscript open [path] [flags]
agentscript open --path <path> [flags]
agentscript open --latest 1 [flags]
Common flags:
--profile full|compact|messages|handoff|debug|commands|tools
--hide-thinking
--show-thinking
--hide-tools
--show-tools
--hide-tool-results
--show-tool-results
--hide-commands
--show-commands
--messages-only
--kind user,assistant,command
--hide-kind thinking,tool_result
--tools Bash,Edit
--hide-tool Bash
--timestamps
--turns
--max-lines 40
--expand 120
--expand all
--format text|md|html|json
--md-style compact|llm-context|audit
--out <file>
Slice
agentscript slice <path> 0:100
agentscript slice <path> 100:
agentscript slice <path> :50
Equivalent open flags:
agentscript open transcript.jsonl --slice 0:100
agentscript open transcript.jsonl --from 0 --to 100
agentscript open transcript.jsonl --last 80
agentscript open transcript.jsonl --around 100 --before 25 --after 50
Turn slicing:
agentscript open transcript.jsonl --turns --turn-slice 2:4
Search
agentscript search "publish-pr"
agentscript search "r2 cors" --provider claude --latest 20
agentscript search push rejected --all --near 20
agentscript search "git (push|pull)" --regex --tool Bash
agentscript search permission --search-kind command_result
Search flags:
--regex
--case-sensitive
--all
--near <blocks>
--search-kind <kinds>
--tool <names>
Commands
agentscript commands transcript.jsonl
agentscript commands transcript.jsonl --failed
agentscript commands transcript.jsonl --with-output
agentscript commands transcript.jsonl --grep "go test"
Files and changes
agentscript files transcript.jsonl
agentscript changes transcript.jsonl
agentscript files transcript.jsonl --format json
Activity
agentscript activity transcript.jsonl
agentscript git transcript.jsonl
agentscript pr transcript.jsonl
These commands summarize branches, commits, PR URLs, pushes, validation commands, and failures.
Compactions
agentscript compactions transcript.jsonl
agentscript compactions transcript.jsonl --format json
The command auto-detects Claude Code and Codex transcripts. JSON output includes ordered compaction boundaries, provider-native window or preserved-message metadata, raw line references, nearest usage snapshots, and normalized pre/post token fields. Claude postTokens is explicitly payload-only, while first_full_usage_after reports the next complete assistant usage snapshot.
Export
agentscript export transcript.jsonl --format html --out transcript.html
agentscript export transcript.jsonl --format md --md-style llm-context --slice 0:100 --out context.md
agentscript export transcript.jsonl --format json --out normalized.json
Split
agentscript split transcript.jsonl --at 100 --out-dir parts --format md
agentscript split transcript.jsonl --every 80 --out-dir parts --format html
Config
agentscript config show
agentscript config path
agentscript config init