.png&w=828&q=75)
This Hybrid Token-Efficient Routing Agent solves the 8 fixed Track 1 tasks (factual QA, math, sentiment, summarization, NER, code debug, logical reasoning, code generation) while using the fewest possible Fireworks tokens. Architecture (accuracy first, tokens second): 1. Zero-cost regex classifier routes every task into one of the 8 categories. 2. Free deterministic solvers run first (math: average-speed + percent + pure arithmetic; sentiment lexicon; NER capitalized spans; missing-colon syntax fix; classic transitive syllogism logic). These produce verified answers with zero Fireworks tokens. 3. Local Ollama (qwen2.5:1.5b-instruct, baked into the image) runs self-consistency (n=2, CONF_THRESHOLD=0.75). High agreement + sandbox validation accepts the local answer for free. 4. Only when free + local paths fail confidence does the agent make exactly one Fireworks call (enforced by contextvars). reasoning_effort=none prevents MiniMax CoT token waste. max_tokens are category-tuned (5 for sentiment, 40 for math, 80-90 for factual/summary). Gemma is preferred when present in ALLOWED_MODELS for the sub-prize. Hard guarantees: - ≤1 Fireworks HTTP request per task - Model IDs only from harness-injected ALLOWED_MODELS - Output is always valid [{task_id, answer}, ...] JSON - Exit 0, linux/amd64, no secrets baked in - Free paths are independently verified; code is sandboxed and never executes remote output On the sample batch the agent typically uses only 1–2 Fireworks calls (summary is the only forced remote path; math, sentiment, NER, code-debug, and logic are free). Image ~6.1 GB with baked local model. Wall-clock well under the 10-minute limit on CPU. The design deliberately raises the confidence bar (0.75) and escalates on any doubt so the accuracy gate is protected before token ranking begins. This is the optimal hybrid strategy for Track 1.
13 Jul 2026