Verification-Driven Token-Efficient Routing Agent

Created by team Momentum on July 06, 2026
Hybrid Token-Efficient Routing AgentVideo Captioning

veriroute is one container that detects its task from the input schema and runs the right agent — both built on the same harness philosophy: deterministic routing, code-verified answers, escalate only proven failures. Track 1 — token-efficient router. A local Qwen2.5-1.5B answers sentiment/NER/summarization behind format verifiers, math via program-of-thought (the model writes solve(), a sandbox executes it), codegen via generated self-tests. Only verified failures and factual recall escalate to the best non-thinking model in ALLOWED_MODELS. Guardrails: stub-first atomic output, ALLOWED_MODELS asserted before any network I/O, hard token budget, prompt-prefix prewarming to fit 2-vCPU windows. Measured on a grader-class VM: 4/8 practice tasks answered free, 2,305 tokens total. Track 2 — all-local captioner. ffmpeg frames -> SmolVLM2-500M describes with a cross-frame consistency check -> Gemma 3 4B writes all four caption styles in one few-shot call. Few-shot beat two LoRA fine-tunes (Fireworks SFT llama-8b and our own GPU LoRA) in a blind judged bake-off — we measured, then chose. All 12 example captions ship in genuine distinct styles at 259s/3 clips on worst-case hardware. 100 tests including SIGKILL-resilience; submission journal with prediction-vs-leaderboard tracking in the repo. R&D (dataset distillation, LoRA training runs, bake-off harness): github.com/bogdan-lmk/gemmacap.

Category tags: