← TinyGPT · docs · devlog · roadmap · speedup
source: docs/prds/multi-turn-agentic-eval.md · view on GitHub ↗

Multi-turn / agentic tool-calling eval

Why (the blind spot)

Everything we’ve measured is single-turn. Our headline (Qwen3-4B-2507 bf16 = 88.7, frontier 98) says nothing about holding a conversation — observing a tool result and acting on it across turns, tracking state. The literature is blunt about the gap:

Modelsingle-turnmulti-turn
Command-R7B69%5%
Llama-3.1-8B61%9.6%
xLAM-2-8b-fc (purpose-tuned)~69%

So our 88.7 likely overstates these models as agents by a wide margin — and we have zero measurement of the real number. This is the prerequisite capability for everything next: a Jarvis-style assistant (Pace) and self-improving game NPCs are both multi-turn agents. See docs/learn/small-model-tool-calling-playbook.md §4.

Goal

A Mac-local, stateful multi-turn tool-calling eval that, for a given model:

  1. runs a multi-turn task where the model’s calls execute against a backend and results feed back across turns,
  2. scores end-to-end task completion (final backend state matches gold) — not just per-call AST,
  3. is frontier-gated (per our eval philosophy: a sound eval → a frontier model aces it; if not, fix the eval before trusting Mac-model numbers),
  4. reports the single→multi-turn drop for our best 4B vs frontier.

Data + matching

Design / scaffolding

scripts/bfcl_multiturn_eval.py (skeleton in this PR):

  1. Load example → instantiate involved_classes with initial_config.
  2. For each turn: render transcript (system tools + prior turns + tool results) → model emits call(s) → execute against the backend instances → append results → next turn.
  3. After the last turn: compare final state / executed path to gold → pass/fail.
  4. Backends: local (MLX) + frontier (claude -p), reusing bfcl_ast_eval.py’s call parser.

The hard part is faithfully executing calls against BFCL’s backend classes (import or vendor them from the gorilla repo). Skeleton marks these as TODO(executor).

Acceptance criteria

Risks / notes

Next after this

If small models cliff hard (expected), the lever is multi-turn RL in an open-ended environment — which is the sister PR (game-as-RL-environment PoC).