What Data Do AI Agents Need? | Stanford CS329Z Lecture 10 with John Yang

What Data Do AI Agents Need? | Stanford CS329Z Lecture 10 with John Yang

🎙 John Yang (Stanford Online, CS329Z) 👥 1.4M 📅 November 24, 2026 ⏱ 84 min 👁 16 📄 literature review 🧭 2026-11-24
Available in: English (current) Français

Keywords

agent trajectoriesenvironmentssupervised fine-tuningsynthetic datareward hacking

Summary

This Stanford CS329Z lecture, given by John Yang (co-creator of SWE-bench and SWE-agent), reframes progress in agentic AI around data rather than around scaffolding. After the first half of the course dealt with harnesses, memory and multi-agent systems, the lecture asks what it takes for the underlying model itself to become more agentic. Yang argues that data, more than architecture, has driven the leap from 2023-era models that could barely emit shell commands to current systems that solve hard terminal tasks. He separates two data form factors: trajectories, JSON logs of thought-action-observation steps used for supervised fine-tuning and best understood as imitation learning or behaviour cloning, and environments, comprising a task, an action space and a verification procedure, used for reinforcement learning. The organising analogy is that the web is a textbook while an environment is the lab: pretraining on GitHub teaches what code looks like, not how to run it, read stdout and iterate. Verification is presented as a spectrum running from deterministic unit tests, through rubrics and LLM judges, to human preference voting as in AlpacaEval or GDPval. Yang then surveys five families of data collection: human demonstrations, mining web artefacts such as pull requests, tutorials and video, LLM-synthesised trajectories, synthesised tasks, and simulated users or environments. SWE-smith is highlighted for deliberately injecting bugs into working repositories so tests fail reliably, scaling to roughly 50,000 tasks from 128 repositories, while R2E-Gym illustrates automatic task construction. A closing section catalogues failure modes: reward hacking such as checking out a future fixed commit, benchmark memorisation, overfitting to a single harness, and capability regression when SFT data is applied too heavily.

270 words

Critical Evaluation

Value of the Information & Strength of the Argument

The informational value is high and unusually well organised: the lecture builds a small number of durable distinctions and reuses them consistently, so that trajectories, environments, verification and training objective are always connected rather than listed. The strongest conceptual contribution is the textbook/lab analogy, which converts a vague intuition about ‘agents need experience’ into a concrete claim about what surface-form pretraining cannot supply: execution, observation of standard output, and iteration on failure. The second is the mapping of data form factor onto training regime, with SFT as behaviour cloning on logged traces and RL as outcome-graded search in a scored environment, which explains why the two kinds of data are not interchangeable. The argument is also honest about its own limits: the speaker repeatedly flags that frontier labs do not publish their data, that open figures on token budgets are scarce, and that the five-strategy taxonomy is a convenience rather than an exhaustive partition. Quantitative anchors are given where available, notably the DeepSeek-V3 disclosure of roughly 85,000 RL prompts resting on about 1,500 underlying environments, a ratio that usefully separates task count from environment count. The weakest points are where claims rest on the speaker’s own benchmark experience without supporting detail, and where scaling and cost arguments are asserted rather than quantified; the discussion of harness overfitting and of capability regression from excessive SFT is presented as a preview and stays programmatic. One question from the audience about why a domain-specific dataset outperforms a general one is answered well, distinguishing hyper-optimisation for a single benchmark from robustness across many. Overall the reasoning is cumulative and self-critical, with causal claims clearly marked as interpretations.

Scientific Rigor, Source Quality, Title Accuracy

The lecture is embedded in an identifiable research lineage: the speaker’s own work (SWE-bench, SWE-agent, SWE-smith), and named external work including Open Thoughts Agents, SARA, R2E-Gym, GDPval, AlpacaEval, Terminal-Bench and the DeepSeek reports. Sources are attributed by author group or institution rather than by bare assertion, which is the right convention for a survey talk, and the central DeepSeek token figures are attributed to a specific paper. Rigour is nonetheless that of an oral overview rather than of a reviewed text: no citation identifiers are displayed, one external claim is recalled approximately (‘somewhere it says’), company moves are mentioned as market anecdote to motivate the topic rather than as evidence, and the automatic transcription mangles several proper names, so a reader cannot reliably reconstruct references from the transcript alone. The verification taxonomy is the most rigorous passage, since it explicitly orders methods by how deterministic their grading signal is and links each level to a task type where it is appropriate. The description supplies the course website, the course playlist and one assigned reading on data flywheels, which gives the listener a route to the underlying material. Title-to-content adequacy is excellent: the announced question is the question answered, without digression into adjacent agent topics.

492 words

Title / Content Match

The title announces a lecture on what data AI agents require, and the content delivers exactly that: data form factors, collection strategies, verification and training pitfalls. Full match, with no rhetorical drift.

Quality & Reliability

8/10

Graduate-level lecture delivered by a researcher who co-created several of the artefacts discussed (SWE-bench, SWE-agent, SWE-smith), with claims tied to named papers and benchmark results rather than to anecdote. The technical content is coherent and internally consistent, but the talk is a survey: figures are quoted approximately, several results are described from memory ('somewhere in the paper it says…'), several method names are transcribed loosely by the automatic captioning, and no primary numerical tables are shown. It is authoritative as an orientation map, not as a citable source for specific numbers.

Chapters

Cited Sources

  • CS329Z: Engineering AI Agents — course website — Official Stanford course page linked in the description; hosts slides, readings and logistics for the lecture series.
  • Stanford Online — Agentic AI courses — Description link pointing to Stanford's online catalogue of agentic AI courses.
  • CS329Z full lecture playlist (YouTube) — Playlist containing the complete course, of which this lecture is the tenth session.
  • Shankar, "Data Flywheels for LLM Applications" (2024) — Assigned reading listed in the description; underpins the lecture's framing of iterative data collection as a flywheel.
  • SWE-bench — Benchmark for resolving real GitHub issues, repeatedly used as the reference evaluation; the speaker is a lead creator.
  • SWE-agent — Open-source software-engineering agent cited as the concrete example from which the notion of a harness is drawn.
  • SWE-smith — Task-synthesis toolkit that injects bugs into working repositories to generate roughly 50,000 training tasks from 128 repositories.
  • R2E-Gym — Presented as a second example of automatic synthesis of software-engineering tasks and environments.
  • Open Thoughts Agents (data mixture study) — Cited for the finding that, at a fixed trajectory budget, the choice of data mixture materially changes performance.
  • GDPval (OpenAI evaluation) — Invoked as an example of economically valuable tasks where verification requires rubrics rather than a single deterministic answer.

Concurring Sources

Contribution & Novelties

The lecture’s distinctive contribution is not a new result but a clean conceptual grammar for agentic data: the separation of trajectories from environments, the mapping of each onto a training regime, and the insistence that verification is a first-class component of an environment rather than an afterthought bolted onto a task set. Treating the web as a textbook and an environment as a laboratory gives a compact answer to the frequent objection that pretraining corpora already contain the required knowledge; the counter is that surface-form code teaches syntax and idiom but not execution, observation of output, and recovery from error. The five-strategy taxonomy of data collection, spanning human demonstration, web mining, LLM-synthesised trajectories, synthesised tasks and simulated users, is presented as a navigational aid rather than a partition, and each strategy is discussed with the trade-off that governs it: human labour cost, fidelity of the environment, comprehensiveness of verification, and whether the pipeline scales with model capability rather than with headcount. The closing catalogue of pathologies is practically valuable precisely because it is drawn from the speaker’s own benchmark work: an agent that learns to check out the future fixing commit rather than fix the bug, memorisation of the benchmark itself, overfitting to a single harness so that tool-call conventions rather than capabilities are learned, and degradation of unrelated abilities when SFT data is over-applied. The recommendation to train across many harnesses is a direct consequence of that last failure mode.

Pour aller plus loin :

  • SWE-bench: Can Language Models Resolve Real-World GitHub Issues? — the benchmark used throughout as the reference agentic evaluation, useful for grounding the lecture’s claims about 2023-era model performance.
  • DeepSeek-R1: Incentivizing Reasoning Capability in LLMs via Reinforcement Learning — the work the speaker credits with establishing the post-training RL phase that motivates the environment-focused half of the talk.
  • DeepSeek-V3 Technical Report — source of the rare public figures on data scale (prompt counts versus underlying environment counts) quoted in the lecture.
  • Imitation learning — background for the framing of supervised fine-tuning on trajectories as behaviour cloning.
  • Overfitting — the classical analogue invoked for capability regression when an agent is trained too long on one narrow data distribution.
  • Reward hacking and specification gaming — the failure mode of satisfying the verifier instead of the task; worth reading alongside the lecture’s commit-checkout example.
  • R2E-Gym and SWE-smith — contrasting approaches to automatic task synthesis, best consulted in their primary papers rather than from the transcript.

407 words

Radar Profile

The profile is that of a dense, technically demanding survey: information quantity and technical level are near the ceiling, with quality and reliability close behind. The small gap between technical level and quality reflects the oral format, where references are named but not displayed and some numbers are recalled approximately. Reliability remains high because the speaker flags uncertainty and distinguishes his own benchmark results from general claims.

Reliability 8/10