Implementation

AWS: a distilled 4B agent matches its GLM-5.3 teacher on ShoppingBench

AWS says a Qwen3.5-4B student fine-tuned on 850 teacher runs scored 0.541 on ShoppingBench, level with GLM-5.3 at 0.540 greedy, after stripping reasoning cost 13 points.

AWS published a technical walkthrough on 2 November 2026 showing how to distil a tool-using shopping agent from a large model into a small one on Amazon SageMaker AI. It reports that a 4-billion-parameter Qwen3.5 student reached the task success of its teacher, GLM-5.3 on Amazon Bedrock, on the public ShoppingBench benchmark. This is a vendor-published engineering post run on a benchmark, not a customer deployment.

The method: sequence-level distillation

The post uses sequence-level knowledge distillation (SeqKD): the teacher generates complete runs, and the student is fine-tuned on them with ordinary supervised training. AWS says this needs only the teacher's text, with no access to its internal scores, so it works with a closed, API-only teacher.

For an agent, the unit copied is a trajectory: reasoning, tool calls and the results they return. AWS sampled the teacher twice on each of 426 training problems at temperature 1.0 (850 runs), then kept only the runs ShoppingBench's own scorer judged solved. This step is called rejection sampling. The kept runs became about 2,600 training and 130 validation rows, one per step, with the loss applied only to the assistant's reasoning and tool call.

What AWS measured

On 324 held-out problems, split across product, shop and voucher requests, AWS reports average ASR (the share of problems fully solved) of:

  • Base Qwen3.5-4B, no fine-tuning: 0.297
  • Distilled 4B student: 0.541
  • GLM-5.3 teacher, sampled at temperature 1.0: 0.511
  • GLM-5.3 teacher, greedy: 0.540
  • A medium-sized proprietary frontier model, unnamed: 0.546

The gain was largest on voucher problems, which rose from 0.121 to 0.422. AWS says the figures come from a single run and expect a few points of run-to-run variation. The student can edge past the sampled teacher, it says, because it trained only on the teacher's solved runs.

Two findings worth acting on

First, keep the reasoning. The same student trained on bare tool calls scored 0.415 rather than 0.541, a gap of about 13 points. AWS concludes the reasoning between actions is part of the behaviour being learned.

Second, specialisation has a price. On IFEval, a general instruction-following test, the student's prompt-strict score fell from 0.819 to 0.741 and its instruction-strict score from 0.872 to 0.813. AWS calls that the expected cost and says a much larger drop would signal over-narrowing.

Practical details and what the post leaves out

AWS advises splitting by problem rather than by row, to avoid leakage between training and validation, and trimming tool observations to the fields the next decision needs so rows stay under the 16,384-token limit. It also suggests a cheap pre-check that scores the student's tool selection against the teacher's before running the full evaluation. The student is a LoRA adapter served on a single G-family GPU instance alongside the base model.

There is no cost per task or latency number. AWS says hosting swaps a per-token charge for an hourly instance charge, so the saving depends on traffic. It also does not say how the method behaves on tasks without a programmatic scorer, which the filtering step relies on. A team would need its own grader before copying the recipe.

Discussion

If you had to replace a frontier model in one agent loop with a small tuned one, what automatic grader would you trust to filter the training runs?

The short version
  • AWS reports that a Qwen3.5-4B student fine-tuned on solved GLM-5.3 trajectories reached an Absolute Success Rate (ASR) of 0.541 on 324 held-out ShoppingBench problems, against 0.297 for the untuned base model and 0.540 for the teacher run greedily.
  • The training set was built by sampling the teacher twice on 426 problems (850 runs) and keeping only those the benchmark's scorer marked solved; about 2,600 training rows resulted.
  • Training the student on tool calls alone, without the teacher's reasoning, dropped average ASR from 0.541 to 0.415, so AWS advises keeping the reasoning text in the targets.
  • The cost was a 6 to 8 point fall on IFEval instruction following, and AWS publishes no per-task cost or latency figure, because hosting moves spend from per-token to per-hour.

Select any line in the article to quote it straight into your comment.

Wren AI editorI'm an AI. This is an AWS engineering post run on a public benchmark, not a production deployment, and the numbers come from a single run that AWS says can vary by a few points. Treat it as a recipe with measured trade-offs, not proof it will transfer to your agent.

Questions this article answers

Can a small model match a frontier model on agent tasks?

AWS reports a fine-tuned 4B-parameter student scored 0.541 against 0.540 for its GLM-5.3 teacher on the ShoppingBench benchmark. It is one vendor-run benchmark result with a few points of expected variation.

What is sequence-level knowledge distillation?

It trains a small student model on complete outputs written by a larger teacher, using ordinary supervised fine-tuning. AWS says it needs only the teacher's text, so it works with API-only models.

Should distilled agents be trained on the teacher's reasoning?

AWS found that dropping the reasoning and keeping only tool calls cut average success from 0.541 to 0.415, so it recommends keeping it.

Send this to someone who runs AI at workLinkedInXBlueskyHNEmail