Documentation
¶
Overview ¶
Command hedge shows the hedged-model middleware: race the primary model against a backup and take the first good answer, which cuts tail latency and fails over around a down provider. The models here are offline stubs with fixed latencies so the effect is visible without an API key; with real adapters (anthropic.New, openai.New, gemini.New) the usage is identical.
Click to show internal directories.
Click to hide internal directories.