Learned model router
Martian routes each prompt to the model it predicts will do best for the price, behind a hosted API. OpenSmartRoute makes the same kind of decision with your own outcomes and your own policy, across every capability you operate, with a trace per request - and the package is Apache-2.0 with zero dependencies, so the router is yours.
“The same idea, on your infrastructure, for every capability.”
Our reading of public documentation; corrections welcome through the support page.
| Capability | OpenSmartRoute | Martian |
|---|---|---|
| Routes to LLMs | Yes | Yes |
| Routes to agents, skills, tools, workflows and humans | Yes | No |
| Hard policy before scoring (region, data boundary, PII, tenant, cost) | Yes | No |
| Per-request trace with ranked candidates and rejections | Yes | No |
| Learns from your outcomes (per target, per tenant)A router trained by the vendor; per-customer learning is not the product | Yes | Partial |
| Multi-step plans (persona -> skill -> model) | Yes | No |
| Self-hosted, air-gapped, zero runtime dependencies | Yes | No |
| Prompt-injection and steering-gadget defences on the router | Yes | No |
| Output guard on responses (PII, secrets, injection: flag, redact or block) | Yes | No |
| Savings ledger, bill analysis and routing auditEvery request records baseline and routed cost; upload last month's provider export to see what routing would have saved before you switch | Yes | No |
| OpenAI-compatible proxy (chat, embeddings, Responses, moderations, audio, images)An OpenAI-shaped chat endpoint that routes among public models | Yes | Partial |
| Anthropic Messages API (/v1/messages) | Yes | No |
| Virtual keys: per-key budgets, rate limits, allowed targets, scopes and expiry | Yes | No |
| Per-target rate limits, budgets and circuit breakers | Yes | No |
| Python and TypeScript SDKsWorks through the OpenAI client pointed at the vendor's endpoint | Yes | Partial |
| MCP server for IDEs and agents | Yes | No |
| Browser extension and desktop app for the people on the teamPrice, personal-data and writing checks on the device before a prompt is sent, on ChatGPT, Claude, Gemini and in any desktop app | Yes | No |
| Provider marketplace with creditsModels by the token: every catalogue model on offer per provider with the price you pay, one key, a prepaid credits wallet and provider preferences (order, only, ignore, max_price) | Yes | No |
| Request/response observability UI for every callDecision trace, tokens, cost and outcome per request; prompt and answer stored when the workspace turns on request logging (redacted or full) | Yes | No |
Register the hosted router as a single LLM target with its data boundary declared public: OpenSmartRoute sends it the requests that may leave your boundary and keeps everything else on-prem, in an agent or with a person.
- id: hosted-model-router
kind: llm
description: Hosted learned router over public models
capabilities: { domains: [general, coding], max_complexity: 1.0 }
constraints: { data_boundary: public, pii_allowed: false }
cost: { usd_per_1k_tokens: 0.006 }Run the Routing Audit on a week of anonymised logs: savings versus your current mix, policy violations your routing allowed, and where agents or humans would have been the better answer.
Other comparisons: OpenRouter, LiteLLM, Portkey, Cloudflare AI Gateway, Kong AI Gateway, Helicone, Not Diamond, Unify, Building it yourself.