Hacker

Justin Lee

@justin06lee

Joined Nov 2026Student, Software Engineer at University of California, Santa Cruz, C & TechUnited States

Elsewhere

Projects

  • flagged-router

    Flagsmith Experimentation HackathonNov 2026

    flagged-router is an OpenAI-compatible proxy that A/B tests a cheaper LLM against your current one on live traffic. It's for any team shipping AI features that wants to know whether switching models is safe, measured on real users instead of offline evals. How it works: (1) your app points its OpenAI client at the router; (2) a Flagsmith multivariate flag (model_route), evaluated locally in-process, sticky-assigns each hashed user to control or candidate, and a boolean flag (candidate_enabled) is a kill switch that moves everyone back to control with no deploy; (3) the router calls that arm's model and measures cost, time to first token, latency, errors and thumbs-up; (4) it sends exposures and metric events to Flagsmith Experimentation. The experiment: "the cheaper model cuts cost per request by 30%+ without hurting thumbs-up, errors or time to first token". Traffic came from 400 simulated users through the real router to two mock models, so it's not a production result. Flagsmith showed cost -82.6% and latency -45% with >99% chance to win, but the guardrails didn't hold (thumbs-up not proven as good, errors per request up), so the call is: don't ship yet. I also built `bun run results`, which pulls every metric from the Flagsmith API and gives a ship / don't-ship call with non-inferiority checks on the guardrails. Who made this: built by the maker of caveira.app, an AI agent for authorized security research. caveira swaps models often, and this is the pattern for doing it safely. The experiment here ran on simulated traffic.