Convert Codex session files to HTML transcripts
Project description
codex-transcripts
Convert Codex session rollouts (JSONL) into clean, mobile-friendly HTML transcripts with pagination.
Installation
Install this tool using uv:
uv tool install codex-transcripts
Or run it without installing:
uvx codex-transcripts --help
Usage
This tool converts Codex session files into browseable multi-page HTML transcripts.
There are two commands available:
local(default) - select from local Codex sessions stored in~/.codex/sessionsjson- convert a specific JSONL session file
The quickest way to view a recent local session:
codex-transcripts
This shows an interactive picker to select a session, generates HTML, and opens it in your default browser.
Output options
All commands support these options:
-o, --output DIRECTORY- output directory (default: writes to temp dir and opens browser)-a, --output-auto- auto-name output subdirectory based on session filename--repo OWNER/NAME- GitHub repo for commit links (auto-detected from session metadata or git output if not specified)--open- open the generatedindex.htmlin your default browser (default if no-ospecified)--gist- upload the generated HTML files to a GitHub Gist and output a preview URL--json- include the original session file in the output directory
The generated output includes:
index.html- an index page with a timeline of prompts and commitspage-001.html,page-002.html, etc. - paginated transcript pages
Local sessions
Local Codex sessions are stored as JSONL files under ~/.codex/sessions/YYYY/MM/DD/. Run with no arguments to select from recent sessions:
codex-transcripts
# or explicitly:
codex-transcripts local
Use --limit to control how many sessions are shown (default: 10):
codex-transcripts local --limit 20
JSONL files
Convert a specific session file directly:
codex-transcripts json ~/.codex/sessions/2025/12/25/rollout-2025-12-25T12-34-56-<uuid>.jsonl -o output-directory/
codex-transcripts json session.jsonl --open
Auto-naming output directories
Use -a/--output-auto to automatically create a subdirectory named after the session:
# Creates ./rollout-.../ subdirectory
codex-transcripts json session.jsonl -a
# Creates ./transcripts/rollout-.../ subdirectory
codex-transcripts json session.jsonl -o ./transcripts -a
Publishing to GitHub Gist
Use the --gist option to automatically upload your transcript to a GitHub Gist and get a shareable preview URL:
codex-transcripts --gist
codex-transcripts json session.jsonl --gist
This will output something like:
Gist: https://gist.github.com/username/abc123def456
Preview: https://gistpreview.github.io/?abc123def456/index.html
Files: /var/folders/.../session-id
The preview URL uses gistpreview.github.io to render your HTML gist. The tool automatically injects JavaScript to fix relative links when served through gistpreview.
Combine with -o to keep a local copy:
codex-transcripts json session.jsonl -o ./my-transcript --gist
Requirements: The --gist option requires the GitHub CLI (gh) to be installed and authenticated (gh auth login).
Including the source file
Use the --json option to include the original session file in the output directory:
codex-transcripts json session.jsonl -o ./my-transcript --json
This will output:
JSONL: ./my-transcript/rollout-....jsonl (245.3 KB)
This is useful for archiving the source data alongside the HTML output.
Development
To contribute to this tool, first checkout the code. You can run the tests using uv run:
cd codex-transcripts
uv run pytest
And run your local development copy of the tool like this:
uv run codex-transcripts --help
Credits
This project is inspired by and based on Simon Willison's claude-code-transcripts. See Simon Willison for the original author.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file codex_transcripts-0.1.1.tar.gz.
File metadata
- Download URL: codex_transcripts-0.1.1.tar.gz
- Upload date:
- Size: 16.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6e2b4b977b696b0eada47c4b81a7312196f302dae543e82ee82161fa367f9e55
|
|
| MD5 |
d37746bdecab147ebd63c05da649ec4a
|
|
| BLAKE2b-256 |
2bb9e7ef87eead0ec99c8da04e698a5990d4610f93d2bd492db2f4b35498490d
|
Provenance
The following attestation bundles were made for codex_transcripts-0.1.1.tar.gz:
Publisher:
publish.yml on timvw/codex-transcripts
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
codex_transcripts-0.1.1.tar.gz -
Subject digest:
6e2b4b977b696b0eada47c4b81a7312196f302dae543e82ee82161fa367f9e55 - Sigstore transparency entry: 779786837
- Sigstore integration time:
-
Permalink:
timvw/codex-transcripts@8ddfeff6f69a90d10c89751ee6d6e9fac7d635ed -
Branch / Tag:
refs/tags/v0.1.1 - Owner: https://github.com/timvw
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@8ddfeff6f69a90d10c89751ee6d6e9fac7d635ed -
Trigger Event:
release
-
Statement type:
File details
Details for the file codex_transcripts-0.1.1-py3-none-any.whl.
File metadata
- Download URL: codex_transcripts-0.1.1-py3-none-any.whl
- Upload date:
- Size: 18.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
19930f287683540774b48d018182a14301faf92c311ac13a8762a9259f3dfa89
|
|
| MD5 |
e4ce69ca643353cf35b9d20800e5eeb8
|
|
| BLAKE2b-256 |
3c81e8dd00012e6c781f05b9a67e0314aab163b928ca2fda795d386d95a5e65a
|
Provenance
The following attestation bundles were made for codex_transcripts-0.1.1-py3-none-any.whl:
Publisher:
publish.yml on timvw/codex-transcripts
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
codex_transcripts-0.1.1-py3-none-any.whl -
Subject digest:
19930f287683540774b48d018182a14301faf92c311ac13a8762a9259f3dfa89 - Sigstore transparency entry: 779786839
- Sigstore integration time:
-
Permalink:
timvw/codex-transcripts@8ddfeff6f69a90d10c89751ee6d6e9fac7d635ed -
Branch / Tag:
refs/tags/v0.1.1 - Owner: https://github.com/timvw
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@8ddfeff6f69a90d10c89751ee6d6e9fac7d635ed -
Trigger Event:
release
-
Statement type: