When your autonomous OpenAI Codex agent modifies 15 files, executes shell commands, runs test suites, and closes the terminal—where does that reasoning go? Here is why saving and searching Codex rollout transcripts is essential for modern engineers.
The Core Problem: Terminal buffers are ephemeral. If your Mac hibernates, your terminal hangs, or a subtle regression emerges in staging 4 days later, git diff reveals what lines changed—but zero context on why Codex made that architectural choice.
Unlike basic autocomplete tools, the OpenAI Codex CLI persists full execution rollout logs to disk in real-time:
~/.codex/sessions/YYYY/MM/DD/rollout-*.jsonl
~/.codex/memories.sqlite
Each JSONL rollout line records the agent's internal thoughts, bash commands, file diff patches, subagent delegations, and prompt cache token savings.
On Wednesday, you tasked OpenAI Codex with refactoring a Go/PostgreSQL distributed worker service to process batch data exports concurrently with worker pools. The agent ran go test ./..., unit tests passed with 100% green checkmarks, and you merged the PR.
At Friday 4:15 PM under peak production load, the worker pool randomly deadlocks. PostgreSQL connection pool exhaustion spikes to 100%, and incoming API requests time out with HTTP 504.
Your git diff shows:
- func ProcessBatch(ctx context.Context, jobs []Job) error {
- for _, job := range jobs { processJob(ctx, job) }
- return nil
- }
+ func ProcessBatch(ctx context.Context, jobs []Job) error {
+ sem := make(chan struct{}, runtime.NumCPU()*2)
+ // Goroutine pool spawned without DB pool bounds...
+ }
The Git commit says "Implement concurrent worker pool with semaphore", but cannot tell you why Codex picked NumCPU()*2 without bounding the database pool.
You search your Codex rollout transcripts in L2Cache’s Session Inspector:
[Agent Thought: codex-rollout-2026-09-28T14-22-09Z]
"Analyzing ProcessBatch bottleneck. Database connection pool size is default
(unspecified in local docker-compose). Creating goroutine semaphore scaled
to runtime.NumCPU()*2. Testing with 10 mock jobs..."
[Tool Execution: go test ./worker -run TestProcessBatch -v]
"PASS: TestProcessBatch (0.04s) [Using in-memory mock store]"
The Revelation: Codex assumed production DB pools were infinite because local tests used an in-memory mock store! You clamp the semaphore to the configured SQL connection pool max, ship the patch in 10 minutes, and save your weekend.
You are 40 minutes into an extensive Kubernetes Helm chart overhaul and Terraform infrastructure refactoring across 9 iterative turns. Suddenly, your laptop battery dies, an accidental Ctrl+C fires, or the terminal window crashes.
Your codebase is left in a half-migrated state, and the active conversational context is wiped clean.
With L2Cache for Mac or the free web viewer:
⌥ + Space to open L2Cache’s AI Session Inspector.codex resume <session-uuid>
Zero lost time. Zero forgotten constraints.
Three weeks ago, you crafted a masterclass prompt containing strict AST transformation rules and TypeScript type guards that allowed Codex to refactor an Express.js API to Fastify in under 15 minutes. Today, you must perform the exact same migration on a second microservice.
You know the prompt worked like magic, but cannot remember the exact 500-word prompt or the specific lint exclusions.
Search for Fastify AST migration in L2Cache. In <1ms, the exact prompt, file arguments, and Codex execution timeline appear with full syntax highlighting. You copy the template, swap the endpoint names, and execute the migration in minutes.
rollout-*.jsonl and transcript.jsonl files. Zero server uploads. View full-text turns, tool execution diffs, and prompt cache token analytics.
L2Cache automatically tracks OpenAI Codex & Claude Code sessions offline with Touch ID security and sub-millisecond search.