I wanted to use Ollama and other providers with Grok Build without
being locked to one API. So I built GrokRoute — a local proxy that
routes requests to 5+ providers with auto-fallback.
How it works
Grok Build → GrokRoute (:8083) → Agnes / Groq / Zhipu / Laguna / Ollama
The proxy is a single Python file implementing the OpenAI
/chat/completions endpoint with SSE streaming. When a request comes in:
- Proxy reads the provider config
- Tries providers in priority order
- If one fails (rate limit, timeout) — next provider takes over in 5s
- Streams the response back to Grok Build
Non-streaming mode goes even faster: fires requests to ALL providers
in parallel, first valid response wins.
Quick start
npm install -g grokroute
grokroute install
grokroute
Then press SPACE — Grok Build launches with multi-provider support.
Key features
- 5+ providers: Ollama, Groq, Agnes, Zhipu, Laguna
- Auto-fallback: sequential with 5s timeout per provider
- Race mode: parallel requests, fastest response wins
- Web admin UI: dark theme, :8083/admin
- Local-only: runs on 127.0.0.1, no telemetry
- MIT license
Why I built this
I was benchmarking different models for coding tasks and got tired of
switching configs manually. The auto-fallback turned out to be the
killer feature — if a provider rate-limits, it just works.
Source: github.com/wxstdo-boop/grokroute
Happy to answer questions!
Top comments (0)