Live-capture proxy (experimental)
Analytics for harnesses that don't persist per-turn usage on disk — capture it live off the wire.
quickai proxy # transparent reverse-proxy on :8787
# point the agent's base_url at it, e.g. Codex ~/.codex/config.toml:
# [model_providers.quickai] base_url = "http://localhost:8787/v1"
quickai index --source proxy # ingest captured usage
quickai report
How it works
The proxy forwards every request to the real provider untouched — your API key passes straight through and is never stored. It tees the response, extracts usage, and appends one native JSONL line per turn (~/.quickai/proxy/). The source=proxy adapter ingests it over the same pipeline as the file adapters.
Reliability invariant: usage extraction is best-effort after your bytes are forwarded — a parse error can never break the agent.
- OpenAI Chat + Responses APIs, streaming (SSE) and non-streaming
- nets cached tokens out of input, captures reasoning tokens
- new
source=proxyinindex/export
⚠️ Experimental — read this
- Codex e2e not yet verified end-to-end (verified against a simulated OpenAI upstream). Real-Codex confirmation pending.
- OpenAI prices are list-ballpark (flagged in code) — token counts are exact, cost is approximate until confirmed.
- The proxy sits in the agent's critical path; autostart (launchd) is a follow-up. Run it yourself for now.
- Principle: proxy is a fallback only for harnesses without their own logs — Claude/OpenCode keep using the zero-config file adapters.
Also
File adapters (Claude, OpenCode from 0.3.0) unchanged.