Skip to content

a3m-router

OpenAI-compatible LLM router across 80+ providers with an optional jev-auto mode that picks the model using calibrated probabilities.

LibrarybetaMIT

Overview

A3M Router is a local OpenAI-compatible proxy that sends each chat request to the cheapest provider it judges capable, across more than 80 providers such as Groq, Mistral, DeepSeek, OpenAI and Anthropic. You point an OpenAI client at localhost and use model="auto".

It has two routing modes. The default auto mode is a heuristic router the README puts at about 0.4 ms overhead. The jev-auto mode uses an ML decision head with calibrated probabilities, about 2 ms warm per the README, and an optional A3M_JEV_URL can point at a remote Jev backend. The decision is essentially "simple question or complex reasoning?", which picks the provider tier. The README makes large cost-saving claims (for example 99.7% cheaper than GPT-4o on simple queries) that are the author's own figures.

What the decision model decides

TypeQuestionAnswers
ChoiceIs this a simple question or complex reasoning, and which provider tier should serve it?(inferred)—

How it works

  1. Client sends an OpenAI-format request with model=auto or jev-auto
  2. Router classifies request difficulty
  3. Request is forwarded to the cheapest capable provider
  4. Response is returned in OpenAI format

Strengths

  • Drop-in OpenAI-compatible endpoint
  • Optional calibrated routing mode alongside a zero-cost heuristic
  • Many providers behind one API

Caveats

  • Cost-saving numbers are the README's own marketing claims
  • How jev-auto relates to TypeSafe's hosted Jev is only partly documented
  • Provider keys still needed for downstream models

Getting started

npm install adaptive-memory-multi-model-router && npx a3m-router serve

At a glance

Type
Library
Status
beta
Language
TypeScript
Runtime
Node local server (also on PyPI)
Has code
yes
License
MIT

Use cases and integrations

How curated lists describe it

Frequently asked questions

What decision is made?

Which provider or model tier should handle each request, based on how hard it looks.

What is jev-auto?

A routing mode using an ML decision head with calibrated probabilities instead of the heuristic router.

How do I use it?

Run the local server and point any OpenAI client at http://localhost:8787/v1 with model=auto.

Related projects

  • Go model-routing gateway for OpenAI and Anthropic clients where Jev picks a model from editable model cards, with CLI and dashboard.

    CLIbetaGo
  • Gateway that distils System One or LLM answers into small fine-tuned classifiers and serves them when confident, falling back otherwise.

    ServiceprototypeRust
  • Local-first routing engine for long-running agent tasks that uses a Jev decider to pick a model group per turn.

    PluginproductionRust, TypeScript
  • Open-source AI gateway for 100+ LLMs that can use Jev to classify requests for complexity routing and to compact tool results.

    ProxyproductionPython
  • Open-source workspace for running and reviewing AI coding agents across devices, with an optional Jev-based automatic model router.

    ProjectproductionTypeScript
  • jev-router★ 593

    Per-turn model routing for Claude Code and Codex: wraps the real CLI and lets Jev send simple turns to fast models and hard ones to strong.

    ProxybetaJavaScript