Train your own tool-calling router in ~35 lines with 180K open decisions

MaziyarPanahi · x · 2026-09-30

Maziyar Panahi shows how to train a tool gate in 35 lines: ModernBERT-base + Hugging Face TRL's RewardTrainer on 77K agentnextactiontype decisions (tool call vs text answer, 53/47 balanced).

He also released 180,000 typed, labeled Jev-format tool-calling decisions — whether to call a tool, which one, and whether args are complete — built on NVIDIA's open agent data with clean splits, so a tiny model can route instead of your LLM. Switch the filter to toolselection to train tool choice.

Related event: 180K-Example Tool-Calling Dataset Open-Sourced for Small Model Routers(3 posts)→

Original post →

More from coding & agent

coding & agent channel →