Quickstart

From zero to a routed prompt.

smol.router is dependency-free at runtime. Train the included smoke-test dataset, map your three tiers, and route from Python or the command line.

Install

terminal
git clone https://github.com/Abdulmumin1/smol.router
cd smol.router
python3 -m venv .venv
source .venv/bin/activate
python3 -m pip install -e .

Train a smoke-test model

The seed data proves the pipeline, not production quality. Its hand-written examples should still be replaced with prompts benchmarked against your actual models.

terminal
smol-router train data/seed.jsonl --output model.json
smol-router inspect --model model.json

Configure your tiers

Generate a starter file, then replace each placeholder with a model understood by your provider client.

terminal
smol-router init --output router.json
router.json
{
  "models": {
    "low": "provider/tiny",
    "medium": "provider/standard",
    "high": "provider/frontier"
  }
}

Route

terminal
smol-router route --model model.json --config router.json \
  "Review this lock-free queue for linearizability"

Omit the prompt to read from stdin. Use --minimum-tier and --maximum-tier for request-specific safety bounds.

Next: Use the benchmark pipeline before making claims about cost savings or correctness.