A Python project for learning and experimenting with Google's Agent Development Kit (ADK) using Claude API as the LLM provider.
- Python 3.10+ support
- Poetry for dependency management
- Google ADK integration
- Claude API (Anthropic) as the LLM provider
- Example agents demonstrating basic and advanced features
- Tool integration examples
- Python 3.10 or higher
- Poetry package manager
- Anthropic API key (Claude API)
- Clone the repository:
git clone <your-repository-url>
cd google-adk-learning-playground- Install dependencies using Poetry:
poetry install- Set up your environment variables:
cp .env.example .env- Edit
.envand add your Anthropic API key:
ANTHROPIC_API_KEY=your_api_key_here
You can get your API key from Anthropic Console.
The simple agent demonstrates basic conversation capabilities:
poetry run python google_adk_playground/simple_agent.pyThis example shows:
- How to initialize an agent with Claude API
- Basic conversation flow
- Context maintenance across messages
The tool agent demonstrates how to use custom tools:
poetry run python google_adk_playground/tool_agent.pyThis example shows:
- How to define custom tools
- Tool registration with the agent
- Agent using tools to answer queries
- Available tools:
get_current_time: Returns the current date and timecalculate_sum: Calculates the sum of two numbers
google-adk-learning-playground/
├── google_adk_playground/
│ ├── __init__.py
│ ├── simple_agent.py # Basic agent example
│ └── tool_agent.py # Agent with custom tools
├── pyproject.toml # Poetry configuration
├── .env.example # Environment variables template
├── README.md # This file
└── CLAUDE.md # Project context for Claude Code
Google Agent Development Kit (ADK) is a framework for building AI agents. Key features include:
- LLM Integration: Support for various LLM providers (we're using Claude)
- Tool System: Easy integration of custom tools and functions
- Agent Orchestration: Built-in support for multi-agent systems
- State Management: Persistent conversation context
- Extensibility: Plugin system for custom behaviors
This project uses Claude API (from Anthropic) as the LLM provider. The default model is claude-sonnet-4-20250514, which offers:
- Strong reasoning capabilities
- Fast response times
- Good balance of quality and cost
- Extended context window
You can change the model in the agent configuration by modifying the model parameter in the agent creation.
- Create a new Python file in the
google_adk_playground/directory - Import necessary modules from
google.adkandanthropic - Follow the pattern from existing examples
- Update this README with usage instructions
All commands should be run using Poetry to ensure the correct virtual environment:
poetry run python <script_name.py>poetry add <package-name>This is a learning playground project. Feel free to use and modify as needed.
This is a personal learning project, but suggestions and improvements are welcome!
If you encounter authentication errors:
- Ensure your
.envfile exists and contains a valid API key - Check that the API key is correctly formatted
- Verify the key is active in your Anthropic console
If you encounter dependency conflicts:
poetry updateEnsure you're using Python 3.10 or higher:
python --versionIf needed, use pyenv or similar tools to manage Python versions.