Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -446,7 +446,7 @@ N-tier dispatch with the bundled 3-tier profile, or write your own.
Schema reference: `nadirclaw/tier_config/schema.py`. Sample profiles:
`nadirclaw/tier_config/profiles/`.

### Trained verifier (NadirRouter/cascade-verifier-v1)
### Trained verifier (nadirclaw/cascade-verifier-v1)

The default `n2_default` profile escalates via the rule-based
`HeuristicVerifier` shipped in this repo — no extra dependencies, runs
Expand All @@ -458,7 +458,7 @@ cross-encoder verifier.
This is the frozen DeBERTa-v3-small snapshot used in the
[RouterArena PR #112](https://github.com/RouteWorks/RouterArena/pull/112)
submission (arena_F 0.7358). It is released under MIT as
[`NadirRouter/cascade-verifier-v1`](https://huggingface.co/NadirRouter/cascade-verifier-v1)
[`nadirclaw/cascade-verifier-v1`](https://huggingface.co/nadirclaw/cascade-verifier-v1)
on HuggingFace so the RouterArena number is reproducible end-to-end
with the open-source router.

Expand Down
2 changes: 1 addition & 1 deletion nadirclaw/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
"""NadirClaw — Open-source LLM router."""

__version__ = "0.19.0"
__version__ = "0.19.1"
2 changes: 1 addition & 1 deletion nadirclaw/cascade.py
Original file line number Diff line number Diff line change
Expand Up @@ -473,7 +473,7 @@ def __init__(
# `cascade.verifier` from the profile. "heuristic" (default)
# keeps the zero-dependency rule-based verifier. "trained"
# lazily loads the DeBERTa-v3-small cross-encoder from
# NadirRouter/cascade-verifier-v1 (requires the optional
# nadirclaw/cascade-verifier-v1 (requires the optional
# `nadirclaw[trained]` extras).
if verifier is not None:
self.verifier = verifier
Expand Down
4 changes: 2 additions & 2 deletions nadirclaw/tier_config/profiles/n2_trained.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#
# Same N=2 tier layout as n2_default, but routes verifier decisions
# through the trained DeBERTa-v3-small cross-encoder released as
# NadirRouter/cascade-verifier-v1 on HuggingFace, instead of the
# nadirclaw/cascade-verifier-v1 on HuggingFace, instead of the
# rule-based HeuristicVerifier.
#
# Use this profile to reproduce the RouterArena PR #112 result
Expand Down Expand Up @@ -33,7 +33,7 @@ cascade:
# Use the trained DeBERTa-v3-small cross-encoder instead of the
# rule-based heuristic. Loaded lazily on first cascade call.
verifier: trained
verifier_model: NadirRouter/cascade-verifier-v1
verifier_model: nadirclaw/cascade-verifier-v1

tiers:
# ----- Cheap tier: workhorses for simple/mid prompts. -----
Expand Down
4 changes: 2 additions & 2 deletions nadirclaw/tier_config/schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,13 +66,13 @@ class CascadeConfig(BaseModel):
max_escalations: Optional[int] = Field(default=None, ge=0)
# Which verifier the cascade should use. `heuristic` (default) uses
# the rule-based HeuristicVerifier shipped in this repo. `trained`
# loads NadirRouter/cascade-verifier-v1 from HuggingFace and
# loads nadirclaw/cascade-verifier-v1 from HuggingFace and
# requires the `trained` extras (pip install nadirclaw[trained]).
verifier: str = "heuristic"
# HuggingFace model id or local path for the trained verifier.
# Only consulted when verifier == "trained". Defaults to the
# released v1 snapshot.
verifier_model: str = "NadirRouter/cascade-verifier-v1"
verifier_model: str = "nadirclaw/cascade-verifier-v1"

@model_validator(mode="after")
def _check_mode(self) -> "CascadeConfig":
Expand Down
6 changes: 3 additions & 3 deletions nadirclaw/trained_verifier.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
What's released
---------------
* Frozen INT8 / FP32 weights at the HuggingFace model id
``NadirRouter/cascade-verifier-v1``.
``nadirclaw/cascade-verifier-v1``.
* Tokenizer + config to load via the standard
``transformers.AutoModelForSequenceClassification`` pipeline.

Expand Down Expand Up @@ -58,7 +58,7 @@
# Default HuggingFace model id for the released snapshot. Override with
# the ``NADIRCLAW_TRAINED_VERIFIER_MODEL`` env var or the ``model_id``
# constructor argument if you mirror the weights elsewhere.
DEFAULT_MODEL_ID = "NadirRouter/cascade-verifier-v1"
DEFAULT_MODEL_ID = "nadirclaw/cascade-verifier-v1"

# Default acceptance threshold. Calibrated against the same held-out
# RouterBench test split as the HeuristicVerifier default. The trained
Expand Down Expand Up @@ -103,7 +103,7 @@ class TrainedVerifier:
----------
model_id:
HuggingFace model id or local path. Defaults to
``NadirRouter/cascade-verifier-v1``.
``nadirclaw/cascade-verifier-v1``.
threshold:
Score cutoff for acceptance. Defaults to 0.80 (same as the
heuristic, so cascade behaviour is consistent when you swap).
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ telemetry = [
]
trained = [
# Optional dependency for the TrainedVerifier (DeBERTa-v3-small
# cross-encoder loaded from NadirRouter/cascade-verifier-v1).
# cross-encoder loaded from nadirclaw/cascade-verifier-v1).
# The heuristic verifier remains the default for the cascade,
# so users who do not want the transformer stack pay nothing.
"transformers>=4.40",
Expand Down
4 changes: 2 additions & 2 deletions tests/test_trained_verifier.py
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ def test_trained_verifier_default_model_id():
"""The released v1 snapshot id should be the constructor default."""
from nadirclaw.trained_verifier import DEFAULT_MODEL_ID, TrainedVerifier

assert DEFAULT_MODEL_ID == "NadirRouter/cascade-verifier-v1"
assert DEFAULT_MODEL_ID == "nadirclaw/cascade-verifier-v1"
v = TrainedVerifier(threshold=0.8, device="cpu")
assert v.model_id == DEFAULT_MODEL_ID

Expand Down Expand Up @@ -198,7 +198,7 @@ def test_n2_trained_profile_loads():
assert profile.profile_name == "n2_trained"
assert profile.num_tiers == 2
assert profile.cascade.verifier == "trained"
assert profile.cascade.verifier_model == "NadirRouter/cascade-verifier-v1"
assert profile.cascade.verifier_model == "nadirclaw/cascade-verifier-v1"
assert profile.cascade.acceptance_threshold == 0.80


Expand Down
Loading