STML 2026 — LLM Agents

Special Topics in Machine Learning: LLM Agents · Graduate course · 15 weeks

Week by week

Select a week below to open its HTML chapter, lab, homework, and presentation papers. Every week’s topic and papers are listed from the start; the materials for a week are released in the week it is taught.

Wk Topic Lecture Lab
1 Course intro · What is an agent? agent = control flow decided by model output; components; autonomy first API calls · prompting fundamentals
2 Prompting & reasoning chain-of-thought · self-consistency · test-time compute CoT & exemplars, measured on a math evalset
3 Tool use function calling · tool schemas · the capability boundary · code execution functions into tools (Ng M3)
4 The agent loop (ReAct) reasoning–action interaction · worked prompt · controlled comparison · loop execution the loop built by hand
5 Reflection & evaluation review and revision · evalsets · code/LLM judging · error analysis draft–review–revise · general evaluation (Ng M2+M4)
6 Multi-agent systems specialization · role inputs and outputs · communication patterns multi-agent pipeline (Ng M5)
7 Planning & search decomposition · plan–execute–replan · ReWOO · ToT research-agent workflow (Ng final project)
8 Midterm exam written, W1–7 —
9 Retrieval augmentation (RAG) embeddings · pipeline · agentic RAG retriever for the final project
10 Context engineering · Memory Lost in the Middle · select/order/compress · MemGPT · Mem0 memory · graph integration
11 Reasoning models & RL o1/R1 · STaR · RLVR · GRPO thinking-budget measurement
12 Inference economics · Benchmarks cost–accuracy trade · routing · Pareto · pass^k routing + cost logging · eval harness
13 Safety & security · Retrospective indirect prompt injection · defense layers guardrails · red team
14 Final presentations team demos + eval scorecard defense —
15 Final exam written, whole semester —

Ordering principle: concept dependency — every week is understandable using only what came before it. Materials appear on each week’s page as the semester progresses.

The course in one sentence

You will learn how LLM agents work by building one, week by week, and by reading the papers that invented each part. The final deliverable is a research-assistant agent that searches and synthesizes answers over this course’s own paper corpus.

Weekly rhythm (3 hours)

Block Time
Theory lecture 30–40 min
Paper presentations ×2 50 min
Break 10 min
Lab (Colab notebook) 80 min
Wrap-up · next-week preview 10 min

Labs run in Google Colab with your own API key — no local installation. Week 4 uses the OpenAI SDK to make the agent loop visible; other early labs use aisuite, and the later labs use LangChain and LangGraph. Use the Open in Colab links where provided, or download the .ipynb and use File → Upload notebook in Colab. The early agent labs adapt Andrew Ng’s Agentic AI (DeepLearning.AI), and the later sequence follows LangChain Academy and official RAG tutorials. Follow each week’s instructions for in-class work and homework.

Before the first class

  1. Read the API Setup Guide and issue your own API key. The Week 1 lab needs it in class.
  2. Bring a laptop that can open Google Colab in a browser.