README file from
GithubCodex Session Archive
Codex Session Archive exports local Codex session JSONL files into Markdown notes inside your Obsidian vault.
It is built for Codex Desktop / Codex CLI local logs:
~/.codex/archived_sessions/rollout-*.jsonl- optionally
~/.codex/sessions/YYYY/MM/DD/rollout-*.jsonl ~/.codex/session_index.jsonlfor thread titles and update times
Features
- Exports archived Codex sessions to Markdown.
- Groups notes by the session workdir/project name.
- Adds Obsidian frontmatter with session id, project, cwd, source JSONL path, and tags.
- Extracts
data:image/...;base64,...images into amedia/folder next to the Markdown file. - Writes image links as
so Obsidian handles spaces in paths. - Skips already-exported sessions by
codex_session_idunless overwrite is enabled.
Commands
Codex Session Archive: Export archived sessionsCodex Session Archive: Rebuild archived sessions
Settings
- Codex home: defaults to
~/.codex. - Output folder: defaults to
Archive/Codex Sessionsand is relative to the current vault. - Include active sessions: also scan
~/.codex/sessions. - Overwrite existing exports: rewrite previously exported notes.
- Include tool details: include full tool call arguments and outputs.
- Include system messages: include system/developer/environment messages.
- Classic role headings: export with explicit role headings instead of the copy-as-Markdown style.
Desktop only
This plugin is desktop-only because it reads files outside the vault from the local Codex data directory.
Filesystem access
The plugin uses Node.js filesystem access to read Codex logs from the configured Codex home directory. Output paths are constrained to the current vault.
Manual install
-
Build the plugin:
npm install npm run build -
Copy
manifest.json,main.js, andstyles.cssinto:<your-vault>/.obsidian/plugins/codex-session-archive/ -
Reload Obsidian and enable the plugin.