A demo that only runs while someone else's quota lasts is a claim, not evidence. So here is the whole thesis up front: if you cannot replay your LLM run with the network unplugged, you cannot debug it, benchmark it, or hand it to a reviewer.
Free model access makes experimentation cheap. It also makes your experiment fragile, because the run depends on a quota you do not control and an endpoint you did not build. The fix is old and boring: record every call once, replay it forever.
This tutorial builds that recorder from zero β a call spine, a hash-chained cassette, an offline replayer, and a tamper test β with a verification step at each stage. All code below is a complete runnable sketch. I have not benchmarked it on your machine, so treat the verification steps as the actual product and the code as scaffolding.
Step 1 β Collapse every model call into one function
Before you record anything, you need a single choke point.β¦