Tips for running the AI Agents 101 lab notebook (vLLM + PydanticAI + MCP)

Just finished the AI Agents 101 hands-on lab (build_airbnb_agent_mcp.ipynb) and wanted to share a few tips that saved me time, in case they help others going through the course.

1. Pick a small model for the lab’s local endpoint
The lab asks you to start a vLLM server in a Jupyter terminal before running the notebook. The GPUs available on the notebooks environment are more than enough, but a smaller Qwen model from the local HF cache (e.g. Qwen/Qwen3-0.6B) starts in under a minute and is plenty for exercising the ReAct flow:

vllm serve Qwen/Qwen3-0.6B --port 8000 --max-model-len 4096 --served-model-name Qwen3-30B-A3B

Note the --served-model-name trick: the notebook’s agent is configured for a specific model name, and aliasing lets you run whatever checkpoint you actually have cached without editing the notebook cells.

2. Tool calling needs two extra vLLM flags
Once the agent gets tools/MCP servers attached (Step 4-5 of the lab), plain vllm serve fails with:

"auto" tool choice requires --enable-auto-tool-choice and --tool-call-parser to be set

Fix:

--enable-auto-tool-choice --tool-call-parser hermes

Qwen family models work well with the hermes parser.

3. Install PydanticAI exactly as the notebook pins it
pydantic-ai-slim[mcp]==1.65.0 installs cleanly in the environment; older versions floating around in blog posts have a different MCP import path (pydantic_ai.mcp is the current one).

4. Session stability
The notebook pods can recycle mid-lab, so it’s worth running the cells top-to-bottom early and re-launching quickly if the workspace 502s - your .ipynb file survives on the storage side.

Happy to answer questions if anyone hits other issues while working through this course. It’s a nice, compact intro to ReAct agents with fully open-source inference.

1 Like

Follow-up to my earlier tips thread: I finished the Module 3 quiz for AI Agents 101 and wanted to share how I prepared, since the questions test conceptual understanding rather than syntax recall.

What helped:

1. Know what each layer of the stack actually does

  • PydanticAI = agent framework that wraps the LLM, manages the ReAct loop, and routes tool calls
  • vLLM / SGLang = open-source inference engines that serve the model locally (they do NOT convert LLMs into agents by themselves)
  • MCP = a standard interface between LLMs and external tools/APIs - one MCP server can expose multiple tools to an agent

2. Reason about what an agent can and cannot do
A recurring pattern in the quiz: “agent has tool X, prompt asks about Y - what happens?” The correct mental model is that the agent can only use the tools it was given. A calculator agent asked about weather will simply tell you it cannot answer rather than hallucinating a forecast. Same for the reverse: with an MCP weather server connected, the agent CAN answer weather questions with real data.

3. Understand the ReAct loop
The loop is: reason about the problem → pick and call a tool → observe the result → repeat until the goal is met. It is not fine-tuning, not retrieval from a static database, and not one-shot code generation.

If you are combining this course with the hands-on lab on notebooks.amd.com (MI300X pods), my earlier tips on vLLM flags still apply: --enable-auto-tool-choice --tool-call-parser hermes is required once tools are attached, otherwise PydanticAI gets 400 errors on tool calls.

Next stop for me: the ROCm certification labs on Radeon GPUs. Happy to compare notes if anyone else is working through it.