AI Instructor Live Labs Included

Building Claude Agents

Turn Claude from a one-shot chat model into an autonomous agent. Build tool-calling loops from scratch, add multi-step orchestration with retries, produce safe structured JSON, and evaluate agent behavior on real tasks. Hands-on in a Python VS Code lab with the Claude API proxy handling auth.

Intermediate
13h 15m
10 Lessons
CLD-AI-103

About This Course

Learn how to turn Claude from a one-shot chat model into an autonomous agent that reasons about tools, calls them, reads their outputs, and continues toward a goal across many steps. You'll build tool-calling loops from scratch using the Anthropic Messages API tool_use protocol, add multi-step orchestration, wire in production-quality error handling and retries, produce structured JSON outputs safely, and evaluate agent behavior on real tasks. Uses the Anthropic Python SDK inside a PythonAI-container VS Code lab with the Claude API proxy handling authentication for you.

Course Curriculum

10 Lessons
01
AI Lesson
AI Lesson

What is a Claude agent? Tool use fundamentals

1h 0m

By the end of this lesson you will know what separates a Claude agent from a Claude chatbot (an agent is a LOOP over the tool_use protocol; a chatbot is a single API call), how the tool_use / tool_result message shape works on the Anthropic Messages API, and why the stop_reason field is the key signal for when to loop vs when to stop. Builds the mental model you will use to build a working tool-calling agent in the next hands-on lesson.

02
Lab Exercise
Lab Exercise

Your first Claude tool-calling agent - Lab Exercises

1h 30m 2 Exercises

By the end of this hands-on lab you will have implemented the tool_use loop from scratch in Python against Orion Analytics' fake 4-customer database, verified Claude reasons about when to call the tool, executes it, reads the result, and produces a correct final decision (e.g., NOT recommending a refund for a suspended account), and tested it against 4 real-world scenarios covering different account states. Uses the same PythonAI container + Claude API proxy stack as the CLD-AI-102 labs.

03
AI Lesson
AI Lesson

Multi-step tool orchestration in Claude agents

1h 0m

By the end of this lesson you will know how Claude agents chain multiple tool calls together (where the second call's input depends on the first's output), how Claude can emit multiple tool_use blocks in a single response for parallel execution, and how to structure your tool schemas so Claude reliably decomposes a complex task into the right sequence. Building on L1's single-tool loop, multi-step orchestration is what turns a toy agent into one that can actually accomplish multi-step production tasks.

04
Lab Exercise
Lab Exercise

Building a multi-step tool-orchestration agent - Lab Exercises

1h 40m 3 Exercises

By the end of this hands-on lab you will have extended your L2 tool-calling agent to FOUR tools (get_customer_status, search_recent_tickets, apply_refund, escalate_to_human), watched Claude chain 2-4 tool calls per scenario based on the customer situation, parallelized independent tool calls with ThreadPoolExecutor to cut latency, and measured the iteration count + tool_call pattern across 5 realistic scenarios. Uses the same PythonAI + Claude proxy stack.

05
AI Lesson
AI Lesson

Error handling and retries in Claude agent loops

1h 0m

By the end of this lesson you will know why tool errors must NEVER be re-raised inside the agent loop (they must always be returned as tool_result blocks so Claude can reason about them), how to classify errors as transient vs permanent, how to add exponential-backoff retries only for transient failures, and how to add a max-tool-calls circuit breaker to prevent runaway loops. Turns your L4 agent from a toy into something that can survive real production tool failures.

06
Lab Exercise
Lab Exercise

Robust agent with error handling - Lab Exercises

1h 30m 2 Exercises

By the end of this hands-on lab you will have added three defenses to L4's multi-tool agent: safe_execute (wraps tool exceptions into tool_result blocks), execute_with_retry (exponential backoff on transient errors only), and dual circuit breakers (max_iterations + max_tool_calls). You will run 4 stress scenarios (40 percent flaky, 70 percent flaky, one permanent-failure tool, clean baseline) and watch the agent survive real failure modes without crashing.

07
AI Lesson
AI Lesson

Structured JSON output via tool_use

1h 0m

By the end of this lesson you will know how to use the Claude tool_use protocol as a mechanism for forcing schema-validated JSON output (no parsing, no regex, no XML), how to write strict JSON schemas that constrain Claude's output shape exactly, and why this pattern is the go-to for extraction, classification with structured metadata, and any pipeline where downstream code needs guaranteed schema compliance. Same tool_use API you learned in L1, applied to a different problem: not calling functions, but shaping outputs.

08
Lab Exercise
Lab Exercise

Structured JSON extraction pipeline - Lab Exercises

1h 20m 2 Exercises

By the end of this hands-on lab you will have built a structured extraction pipeline over 15 Orion tickets using the tool_use forced-schema pattern, verified every returned record is warehouse-ready (all required fields, valid enums, well-formed entities), and demonstrated the failure mode when the schema is loosened (LOOSE schema produces ~0-33 percent valid records vs STRICT schema at ~100 percent).

09
AI Lesson
AI Lesson

Evaluation strategies for Claude agents

1h 0m

By the end of this lesson you will know why manual QA does not scale for agent development, how to build a systematic evaluation framework with a test bank plus a scoring layer, when to use deterministic rules vs the LLM-as-judge pattern, and how to structure per-scenario expected-behavior assertions so regressions get caught in CI instead of production. Turns your agent from a demo into something you can actually ship, monitor, and improve.

10
Lab Exercise
Lab Exercise

Full customer-support agent capstone - Lab Exercises

2h 15m 3 Exercises

Capstone for CLD-AI-103. Combine every technique from L1-L9 into a production customer-support agent for Orion Analytics: 4-tool orchestration with safe_execute + retries + circuit breakers, a structured JSON action record via tool_use schema, and a full eval harness scoring 15 cases (happy path, edge, adversarial) with deterministic rules AND LLM-as-judge. Ship the pass-rate as your CLD-AI-103 deliverable.

This course includes:

  • 24/7 AI Instructor Support
  • Live Lab Environments
  • 5 Hands-on Lessons
Skill Level Intermediate
Total Duration 13h 15m