Stanford Opens Its AI Agent Course to the Public: First Hand-Write RAG and the Agent Loop, Then Discuss DSPy
The CS329Z course homepage, lecture videos, and repositories for two assignments are all public. The course starts with low-level components such as RAG, tool calling, and the Agent loop, then moves on to DSPy, evaluation, safety, multi-agent systems, and coding agents.
Stanford's CS329Z: Engineering AI Agents is now online, and the course homepage, lecture videos, and assignment repositories are all accessible. The course page shows that this course is for Fall 2026 and is taught by Diyi Yang, Michael Ryan, and John Yang.


The course positioning is stated clearly: moving from monolithic language models to compound AI systems. The system contains LLMs, retrievers, tools, and optimizers, with multiple components interacting. The course covers the range from simple LLM pipelines to compound AI systems and then to autonomous agents. Students need to learn how to choose problems, decompose problems, select components, collect and organize data, build evaluations, and weigh design tradeoffs in real systems.



One detail in the schedule is worth noting: Week 2 covers RAG first, Week 3 covers tool calling and function calling, and only in the second half of Week 3 does it move into DSPy and LangGraph. Students must first implement RAG, tool use, and the Agent loop from scratch, then learn how frameworks abstract these patterns. RAG is retrieval-augmented generation; the Agent loop is the loop in which the model calls tools, observes results, and continues acting; DSPy makes prompts and pipelines declarative and then optimizes them. The course places frameworks after hand-written components, an order that is closer to engineering practice than many tutorials.
Evaluation is also not relegated to the end as an appendix. Week 7 covers evaluation fundamentals and benchmark design, Week 8 covers LLM-as-Judge and evaluation infrastructure, and Week 9 covers safety. The course page puts failure modes, data quality, evaluation, and guardrails into the main line. Week 5 is specifically about why multi-agent systems fail. For people building AI applications, this material is more useful than building yet another demo.
Several lectures in the public materials can be watched directly: Lecture 1 is fundamentals and landscape, video; Lecture 3 covers RAG, video; Lecture 4 covers tool calling, video; Lecture 5 covers frameworks and orchestration, video. Guest sessions include Terminal-Bench, Andrew Ng's fireside chat, the SWE-bench team, and coding agents and proactive agents. Andrew Ng's session is here, the SWE-bench session is here, the safety lecture is here, and the coding agents lecture is here. The Terminal-Bench project page is at tbench.ai.
The assignments are not paper exercises. Both HW1 and HW2 have repositories: assignment1-harness, assignment2-harness. The course also has a quarter-long project, with clear deadlines for the proposal, midpoint demo, paper video, final demo, and report. The course page notes that the schedule is tentative and may change.
For readers with a development background, you can follow along with the videos and assignment repositories, focusing on how the course separates RAG, tool calling, evaluation, and safety. For readers without a technical background, the course structure itself is informative: an Agent system is not just a model; it also has retrieval, tools, memory, evaluation, and permission boundaries.
Course homepage: cs329z.stanford.edu


The course sponsors are Google, Laude Institute, and Thinking Machines Lab.
发布时间: 2026-12-05 18:26