Preface

About This Book

Who This Book Is For

This book is for developers who want to build applications with Claude. Whether you’re:

  • Just starting out — the Core Capabilities section walks you through fundamental patterns
  • Building production agents — the Managed Agents section covers production-grade patterns
  • Integrating with external tools — the Tool Use and Third-Party sections have you covered

How Chapters Are Organized

Each cookbook follows a consistent structure:

  1. Problem statement — what are we trying to solve?
  2. Approach — the technique or pattern used
  3. Code — fully runnable Python snippets
  4. Results — example outputs and analysis
  5. Extensions — ideas for adapting to your use case

A Note on Code Execution

The notebooks in this book are rendered statically — meaning the code cells display their last-saved output without re-executing. This ensures:

  • ⚡ Fast page loads (no waiting for API calls)
  • 🔒 No accidental charges (some notebooks make real API calls)
  • 📸 Consistent results (outputs don’t change between renders)

To run any notebook yourself:

# Clone the original repo
git clone https://github.com/anthropics/claude-cookbooks.git
cd claude-cookbooks

# Install dependencies
pip install -e .

# Set your API key
export ANTHROPIC_API_KEY="your-key-here"

# Run a notebook
jupyter lab capabilities/classification/guide.ipynb

Credits

All content is © Anthropic, licensed under their repository terms. This book format is a community organizing effort for easier navigation and discovery.