Back to articles
I Built a Flight Recorder for AI Agents — Now I Can Replay Every Decision They Made
How-ToTools

I Built a Flight Recorder for AI Agents — Now I Can Replay Every Decision They Made

via Dev.toLakshmi Sravya Vedantham

90% of AI agents fail in production. When they do, you get... nothing. No trace, no replay, no step-by-step view of what went wrong. Debugging an agent is like debugging a black box. I built llm-lens to fix this. What is llm-lens? A single Rust binary that sits between your code and any LLM API, records every call, and lets you replay sessions step-by-step in your terminal. Your code / agent framework | http://localhost:4001 | ┌─────────┐ │ llm-lens │ ← records everything, forwards unchanged └────┬────┘ | LLM API (OpenAI, Anthropic, etc.) Zero code changes. Swap one environment variable: export OPENAI_BASE_URL = http://localhost:4001/v1 Every LLM call now gets recorded. Your code works exactly the same. Quick Start git clone https://github.com/LakshmiSravyaVedantham/llm-lens.git cd llm-lens cargo build --release cp config.example.toml config.toml ./target/release/llm-lens start That is it. Every LLM call through port 4001 is now recorded. The Killer Feature: Session Replay Run llm-lens

Continue reading on Dev.to

Opens in a new tab

Read Full Article
2 views

Related Articles