Skip to content

validator: per arena scoring rules, envelope budgets and footprint, burned empty pools, router and harness limits, and the context compression grader - #153

Merged
BANADDA merged 2 commits into
mainfrom
arena-rules
Oct 19, 2026
Merged

BANADDA merged 2 commits into
mainfrom
arena-rules

Conversation

@BANADDA

@BANADDA BANADDA commented Oct 19, 2026

Copy link
Copy Markdown
Member

Part of #152.

Per arena scoring. score.Rules.from_definition reads the definition's scoring block (written by mta define from each arena.yaml). With no block, every value is today's constant, so sql_gen_s1 scores exactly as before. ctx_compress_s1 gets:

  • z 1.96;
  • twin factor 1 − min(1, max(0, gap − 0.02) / 0.10);
  • linear efficiency e_x = min(1, max(0, (ref − x)/ref)) with the same weights;
  • the per item envelope pass P (at most 1% of answered items over the TTFT or TPOT budget, plus the memory cap);
  • the edge bonus B (0 here, the arena sets applies: false);
  • no cap at 1.

Envelope budgets.

  • Parameter bounds and the memory cap come from budgets.
  • vLLM's max_model_len is the arena's max input plus max output instead of the miner config's 8,192.
  • Memory is the model footprint (safetensors bytes plus the KV cache at that length), replacing nvidia-smi device usage, which read about 90% of the card for every model because vLLM reserves it.
  • The contract's hardware classes are now the groups mt-1, mt-2 and mt-3, and mt submit manifest defaults to mt-3.

Empty pools. With empty_pools: burn, an empty pool's share goes to the subnet owner hotkey, read from the chain. If the hotkey cannot be read, the validator logs an error and falls back to redistribution. To verify on testnet 576 before the first epoch: does the chain recycle weight set on the owner's uid?

Router.

  • Limits come from definition.limits.router. The contract ceiling is now 1.5B, and a router above 100M parameters runs on the sandbox GPU, with vLLM held to 75% of the card.
  • router: brier_auroc scores each source as 0.5·max(0, 1 − Brier/Brier_base) + 0.5·max(0, 2·AUROC − 1), then the usual 0.7 mean plus 0.3 min.
  • The latency gate is the arena's.

Harness.

  • max_model_calls refuses a further model call for an item with 429.
  • added_wall_p95_ms zeroes the harness score when its added time (call latency minus model time) at p95 goes over the limit.
  • faults: model applies the fault plan to the first model call of a faulted item, for arenas with no tools.

Context compression grader (grader: context_compression):

  • Format gate on the five field schema.
  • Compression gate counted with the arena's tokenizer.
  • Key fact recall and hallucinated identifiers by normalised matching.
  • Continuation from a pinned probe agent (vLLM on the last GPU in --gpus, temperature 0) that answers the item's probes from the summary alone.
  • Pass at 0.80.

Every pool now grades through EpochContext.grade, so the grader sees the task and the judge.

Local tests (not committed) cover: default rules reproduce today's score, the compression rules on fixed inputs, burn to the owner, the grader on good, invented and malformed answers, and AUROC. The existing suite passes. ruff (newest) is clean; mypy shows only the Windows only resource findings already on main.

Not in this PR: the GGUF and CPU measurement path for mt-1 and mt-2, mt envelope check, lower group (edge) tests, and AWQ and GPTQ dequantisation for provenance.

🤖 Generated with Claude Code

…urned empty pools, router and harness limits, and the context compression grader
@BANADDA
BANADDA merged commit 9690f0a into main Oct 19, 2026
6 checks passed
@BANADDA
BANADDA deleted the arena-rules branch October 19, 2026 21:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant