Autonomous LLM routing agent. Self-learning, cost-aware, auditable.
Project description
X25 — Autonomous LLM Routing Agent
X25 routes every LLM call to the cheapest model that meets your quality bar. It learns per-organization using Thompson Sampling, audits every decision in a tamper-evident hash chain, and fine-tunes a custom model on your call history at Stage 4.
from x25 import X25
agent = X25(api_key="sk-x25-...", gateway_url="http://localhost:8000")
result = agent.complete(
"Summarize this paper abstract...",
hint="summary"
)
print(result.text) # the answer
print(result.model_used) # which model X25 picked
print(result.cost_saved_usd) # how much cheaper vs frontier
Install
pip install x25-sdk
What it does
- Routes each call to the cheapest tier (SLM / Mid / Frontier) likely to pass quality
- Learns per org using Thompson Sampling — converges in 50-200 calls
- Judges quality automatically using LLM-as-judge scoring
- Escalates automatically if quality fails — no manual fallback logic
- Audits every decision in a cryptographic hash chain
- Fine-tunes a custom SLM on your call history at Stage 4 (500+ calls)
Stages
| Stage | Calls | What happens |
|---|---|---|
| 1: Explore | 0-49 | Tries all tiers, learns your task mix |
| 2: Exploit | 50-199 | Converges to cheapest reliable tier |
| 3: Feedback | 200-499 | Asks for labelled examples |
| 4: Fine-tune | 500+ | Trains custom LoRA, enters routing pool |
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file x25_sdk-0.1.0-py3-none-any.whl.
File metadata
- Download URL: x25_sdk-0.1.0-py3-none-any.whl
- Upload date:
- Size: 4.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
872185761b9410eee1291628a37ca3cf1c8e503911321b51bba8cf1a65072011
|
|
| MD5 |
413525e83fb3546c15603a400c5c7379
|
|
| BLAKE2b-256 |
8c311346b26130eb3d0759e6e06e4673b0e2c8db4c4aae02ae49606688411960
|