Wrapper for Codex CLI that sends OpenTelemetry traces to Laminar.
bun installSet your Laminar API key:
export LMNR_PROJECT_API_KEY="your-api-key"bun run index.ts [codex args...]To use local compaction instead of remote:
bun run index.ts --disable remote_compactionWith debug logging:
CODEX_LMNR_DEBUG=1 bun run index.ts- Each turn (user message -> assistant response)
- Tool calls as child spans
- Token usage and costs
/compactoperations (local and remote)
| Variable | Description |
|---|---|
LMNR_PROJECT_API_KEY |
Laminar API key (required) |
CODEX_BIN |
Path to codex binary (default: codex) |
CODEX_LMNR_DEBUG |
Enable debug logging to log/codex-lmnr.log |