Registry-driven LLM routing: build classifier prompts from agent descriptions, validate decisions, and dispatch.
Project description
agent-registry-router
Registry-driven LLM routing: build classifier prompts from agent descriptions, validate decisions, and dispatch to other agents.
Install (uv)
From PyPI:
uv pip install agent-registry-router
From a checkout of this repo (dev/editable):
uv venv
source .venv/bin/activate
uv pip install -e .
Core usage
from agent_registry_router.core import (
AgentRegistration,
AgentRegistry,
RouteDecision,
build_classifier_system_prompt,
validate_route_decision,
)
registry = AgentRegistry()
registry.register(AgentRegistration(name="general", description="General help."))
registry.register(AgentRegistration(name="special", description="Special help."))
prompt = build_classifier_system_prompt(
registry,
preamble="You are a query classifier that routes user messages to the appropriate agent.",
default_agent="general",
)
decision = RouteDecision(agent="special", confidence=0.9, reasoning="Clear match.")
validated = validate_route_decision(decision, registry=registry, default_agent="general")
Adapters
- PydanticAI dispatcher:
src/agent_registry_router/adapters/pydantic_ai/README.md
Tests (uv)
uv pip install -e ".[dev]"
pytest
Example: FastAPI pinned bypass
See examples/fastapi_pinned_bypass/.
License
Apache-2.0 (see LICENSE).
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
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 agent_registry_router-0.1.0.tar.gz.
File metadata
- Download URL: agent_registry_router-0.1.0.tar.gz
- Upload date:
- Size: 13.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6c32b6957ad810ac094a38c230ecb801df2b50cee6a62e90a50005aa27487140
|
|
| MD5 |
88a1e0e26c3eff6d7fbb7f137e3c4e37
|
|
| BLAKE2b-256 |
6443f5a99402cc33f85b851edcdcd976683c61e9154001ad2a660e3e9450d6c2
|
Provenance
The following attestation bundles were made for agent_registry_router-0.1.0.tar.gz:
Publisher:
publish-pypi.yml on agibson22/agent-registry-router
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
agent_registry_router-0.1.0.tar.gz -
Subject digest:
6c32b6957ad810ac094a38c230ecb801df2b50cee6a62e90a50005aa27487140 - Sigstore transparency entry: 798849902
- Sigstore integration time:
-
Permalink:
agibson22/agent-registry-router@47cd63c904fed4d23808417381fedfeb3bfb502c -
Branch / Tag:
refs/tags/v0.1.2 - Owner: https://github.com/agibson22
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-pypi.yml@47cd63c904fed4d23808417381fedfeb3bfb502c -
Trigger Event:
push
-
Statement type:
File details
Details for the file agent_registry_router-0.1.0-py3-none-any.whl.
File metadata
- Download URL: agent_registry_router-0.1.0-py3-none-any.whl
- Upload date:
- Size: 16.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4dccce00e1d09b7c87a8f1fa75ba012c0d3e897d5b8a2a72a6377a1d061cdd70
|
|
| MD5 |
1bc301209f8fefcb1302e0aa073dd8eb
|
|
| BLAKE2b-256 |
93f2749d109defd03544a452740812eb30be36d4427ad8dc2daba6d571a62cbf
|
Provenance
The following attestation bundles were made for agent_registry_router-0.1.0-py3-none-any.whl:
Publisher:
publish-pypi.yml on agibson22/agent-registry-router
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
agent_registry_router-0.1.0-py3-none-any.whl -
Subject digest:
4dccce00e1d09b7c87a8f1fa75ba012c0d3e897d5b8a2a72a6377a1d061cdd70 - Sigstore transparency entry: 798849904
- Sigstore integration time:
-
Permalink:
agibson22/agent-registry-router@47cd63c904fed4d23808417381fedfeb3bfb502c -
Branch / Tag:
refs/tags/v0.1.2 - Owner: https://github.com/agibson22
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-pypi.yml@47cd63c904fed4d23808417381fedfeb3bfb502c -
Trigger Event:
push
-
Statement type: