AI Cloud Architect

Build efficient agents with knowledge distillation on Amazon SageMaker AI

AWSHow-to by Giuseppe Zappia, Ankita Agarwal, Amin Dashti and Michael OguikeAWS Artificial Intelligence Blog

Agentic assistants built on frontier models run a multi-step tool loop, and paying frontier prices on every step is hard to sustain at production scale. This post shows how to use sequence-level knowledge distillation (SeqKD) to transfer a frontier teacher’s agentic behavior into a small, lower-cost student on Amazon SageMaker AI.

Read the original (opens the source's page in a new tab)

AI: Summary

What it is

A step-by-step pipeline distills a frontier teacher's shopping-agent trajectories into a 4B Qwen3.5 student via SeqKD, filtered by a task scorer, trained serverlessly on SageMaker AI and served as a LoRA adapter.

Who it is for

Teams running multi-step agents on a frontier model who want lower per-task cost by moving to a small hosted model.

Key points

  • Only trajectories that solve the ShoppingBench task are kept (rejection sampling); the post reports the 4B student at 0.541 average ASR versus 0.511 for the sampled teacher on the held-out split.
  • Keeping the teacher's reasoning with tool calls adds about 13 points ASR versus tool calls alone (0.415 without reasoning).
  • IFEval drops about 6 to 8 points, which the post calls the expected cost of specialization.
  • The post gives no per-task cost or latency figures; it says the reader must measure on their own workload.