weave-os/router
Model router for agentic systems. Routes every prompt to the right model in <50ms. Cut costs 40-70% with just an endpoint change.
What it solves
It eliminates the need to manually choose a specific AI model for every task. Instead of relying on a single provider or a "vibes-based" prompt to decide which model to use, it provides a single endpoint that automatically routes each request to the most appropriate model based on the specific action being performed.
How it works
The router acts as a drop-in proxy for major AI APIs (Anthropic, OpenAI, Gemini, and OpenAI-compatible endpoints like OpenRouter). It uses a tiny on-box embedder and a cluster scorer derived from Avengers-Pro to analyze each upstream API request and select the best model from the user's enabled providers. It supports streaming, tools, and vision, and keeps provider keys encrypted on the user's local machine.
Who it’s for
It is designed for developers using AI-powered coding tools (such as Claude Code, Codex, Cursor, opencode, or pi) or those building their own applications who want to optimize model selection automatically without changing their core integration logic.
Highlights
- Multi-Provider Support: Compatible with Anthropic, OpenAI, Gemini, and various OSS models (DeepSeek, Llama, Mistral, etc.) via OpenRouter.
- Action-Based Routing: Routes requests per action rather than per turn for higher precision.
- Drop-in Integration: Can be used as a local proxy (
localhost:8080) or via a hosted version. - Privacy-First: Uses a "Bring Your Own Key" (BYOK) model where keys are stored locally and encrypted at rest.
- Built-in Observability: Provides OTLP traces compatible with the Weave dashboard, Honeycomb, Datadog, and Grafana.
Related
- Project
- Project
- Project
- Project