asciinema
$ asciinema Official Med Riskasciinema captures terminal sessions into compact, time-stamped NDJSON .cast files instead of heavy video. Agents can record scripted commands with asciinema rec -c, strip ANSI sequences into plain text via asciinema convert -f txt, and concatenate casts with asciinema cat.
brew install asciinema Recording non-interactive -c sessions and extracting plain transcripts via asciinema convert -f txt are local shell workflows.
Agent-Readiness Checklist
Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.
FCRS-1.0 6-Dimension Breakdown
.cast files are native NDJSON and convert -f txt produces clean text, but rec without -c spawns an interactive shell and play requires a TTY.
.castoutput is native NDJSON;convert -f txtstrips escape codesrecwithout filename prompts to upload;playis interactive
Default asciinema rec without a path prompts to upload sessions to asciinema.org, risking accidental leakage of terminal secrets.
uploadand interactivereccan send terminal captures to remote servers
Available via Homebrew, Cargo, and Linux distros, though native Windows is unsupported (POSIX PTYs required).
- macOS and Linux support only; requires POSIX PTY
Tiny text-based .cast artifacts replace multi-megabyte screen recordings and convert cleanly to text, raw streams, or v2/v3 formats.
- Supports
rec,convert,cat,play, andstream
Official asciinema CLI (asciinema/asciinema), rewritten in Rust in v3 under GPL-3.0-or-later.
- Official
asciinema/asciinemaGitHub repository
Clean docs.asciinema.org manual and built-in --help, though v2 (Python) vs v3 (Rust) subcommand differences exist across older Linux distros.
- Official CLI docs at docs.asciinema.org/manual/cli/usage
Security, Auth & Guardrails
Stores optional asciinema.org install-ID/auth in ~/.config/asciinema/config.toml (only needed for asciinema upload / auth).
Free GPL-3.0-or-later open-source Rust CLI (asciinema v3+).
# asciinema Agent Rules - Always pass an explicit local `<filename>.cast` and `-c "<command>"` on `asciinema rec` so it neither spawns an interactive shell nor prompts to upload. - Never run `asciinema upload` or `asciinema stream` without explicit user consent, as terminal output may contain secrets.
Agent-Ready Command Recipes
Safe Read-Only Queries
asciinema convert -f txt demo.cast -
Strips ANSI escape codes and timing metadata, emitting readable transcript text to stdout.
Controlled Writes & Previews
asciinema rec --overwrite -c "ls -la" demo.cast
Captures the exact output and timing of ls -la into demo.cast without prompting or uploading.
Strengths for Agents
- + Native NDJSON
.castformat andasciinema convert -f txtmake terminal recordings trivially inspectable. - +
asciinema rec -c "..." out.castautomates command capture cleanly.
Caveats & Pitfalls
- ! No Windows support (requires POSIX PTY); older Linux distros still ship v2 where
catbehaves differently from v3. - ! Running
asciinema recwithout a filename or-claunches an interactive shell and prompts for upload.