Show HN: GoModel – an open-source AI gateway in Go
TL;DR Highlight
A Go gateway that unifies many LLM providers behind OpenAI- and Anthropic-compatible APIs.
Who Should Read
Backend developers using multiple LLM providers who want caching, cost tracking, and failover in one place.
Core Mechanics
- A LiteLLM alternative in Go
- It is an open-source (MIT) AI gateway, a proxy that relays LLM calls, written in Go.
- It accepts both OpenAI-compatible (/v1) and Anthropic-compatible (/v1/messages) requests.
- Official SDKs work unchanged
- For the OpenAI SDK, set the base URL to http://localhost:8080/v1.
- For the Anthropic SDK, use http://localhost:8080 and the SDK appends /v1/messages.
- Cost-saving features are built in
- It supports exact and semantic response caching.
- It also offers per-request cost estimates, budgets per user, team or key, and rate limits.
- Failover and routing
- It reroutes to backup providers with retries and circuit breakers (which stop calls after repeated failures).
- It pins a session to one provider and key so provider prompt caches stay warm.
- Virtual model aliases support round-robin or cost-based load balancing.
- Observability and control
- It provides Prometheus metrics, OpenTelemetry traces, audit logs, and live request streaming.
- It also has guardrails, plugins, and an MCP gateway endpoint.
- Prompt compression and smart routing are paid
- Both are in the commercial GoModel Pro.
- OIDC SSO is also Pro-only.
Community Reactions
- Questions about benchmarks
- One commenter saw no significant advantage over mature routers like Bifrost and asked whether benchmarks exist.
- Several others asked how it compares to Bifrost.
- Tracking upstream API changes is the main worry
- Commenters with similar proxies said input/output structures change with each model release.
- One said Go makes it harder because providers have fewer Go SDKs.
- Go supply-chain argument
- One commenter argued a compiled binary limits supply chain attack impact compared with runtime-dependent tools like LiteLLM.
- Limits of a unified API
- One commenter found that even with unified libraries, temperature, reasoning effort, and tool choice still needed provider-specific handling.
- Another asked how cache keys work when prompts contain timestamps or session IDs.
How to Apply
- Run the gateway locally and point your SDK at it
- Start GoModel with the install script or docker run and set OPENAI_API_KEY.
- Change your OpenAI SDK base URL to http://localhost:8080/v1 and make a call.
- Check the dashboard at http://localhost:8080/admin/dashboard for requests and costs.
- Turn on caching and budgets first
- Pick one endpoint with many repeated prompts and enable response caching.
- Set a per-key budget limit to cap runaway spend.
- Set up a backup provider for failover
- Group a primary and a backup provider behind one virtual model name.
- Use a wrong primary key on purpose to confirm traffic falls back to the backup.
- Benchmark against your current LiteLLM setup
- Replay the same request set and measure latency and memory.
- Check the README's self-reproducible benchmark separately.
Try It
# Paste into a terminal (macOS/Linux, OpenAI key required)
curl -fsSL https://gomodel.enterpilot.io/install.sh | sh
export OPENAI_API_KEY="{{your-openai-key}}"
gomodel &
sleep 2
curl http://localhost:8080/v1/responses \
-H "Content-Type: application/json" \
-d '{"model": "gpt-5-chat-latest", "input": "Hello!"}'
# Dashboard: http://localhost:8080/admin/dashboardTerminology
Related Papers
A Beginner's Guide to Local AI with Inkling, Qwen, and Unsloth
Install Unsloth Desktop, load a quantized Qwen model, and share a private ChatGPT-like AI on your home LAN.
Muru – AI-assisted Rust server for Python apps by mod_WSGI's creator
mod_wsgi's creator is building Muru, an AI-assisted Rust ASGI/WSGI server, documenting it in public
87% of the Anthropic power will come from gas and 11% from coal in 2028
Analysis of Anthropic's contracted data centers: 87% gas, 11% coal power in 2028
Anthropic’s Nasdaq debut
Anthropic listed on Nasdaq and closed its first day below its opening price.
OpenAI still has a WebRTC Problem
WebRTC drops late audio, hurting voice AI; MoQ retransmits and buffers instead
Gemini 4 Neon
Gemini 4 Neon cuts cost per task 32% versus Carbon, at $3 input and $15 output per million tokens
AI is killing All About Berlin
After Google AI Overviews, a Berlin guide site lost 70-75% of its traffic.
Not Everything Needs an LLM
PostHog used small decision models to skip 98.7% of expensive LLM calls