The loop agents example snippet did not have imports, which could break the code when copied directly and executed.
Co-authored-by: Lavi Nigam <98014943+lavinigam-gcp@users.noreply.github.com>
* fix: Added SSL CERT setting and code snippets
fix: Added SSL CERT setting and code snippets
* fix: update the model name to -exp
fix: update the model name to -exp
* fix: changed model names on the troubleshooting tips
fix: changed model names on the troubleshooting tips
* fix(tutorial): Correct say_hello tool logic, update LLM models, and ensure async session creation
This commit addresses several issues and updates within the ADK agent team tutorial (adk_tutorial.ipynb) and its corresponding documentation (agent-team.md).
Notebook Updates (adk-tutorial.ipynb):
- Ensured all `SessionService.create_session` calls are `await`ed for proper asynchronous operation throughout the notebook.
- Updated Anthropic model to `claude-sonnet-4-20250514` and OpenAI model to `gpt-4.1`, with commented alternatives for flexibility.
- Added LiteLLM documentation links for model references.
- Resolved the 'Hello None' issue in Step 3 by modifying the `say_hello` tool to correctly handle optional name arguments and prevent the `Default value is not supported` warning with Gemini models.
- Tested and confirmed notebook compatibility with `google-adk==1.0.0`.
Page Update (agent-team.md):
- Synchronized `agent-team.md` with all notebook changes to ensure documentation accuracy and reflect the latest updates.
* fix(tutorial): Refine CLI/Web UI agent team tutorial and update content
This commit introduces several fixes and improvements to the Python file-based version of the ADK agent team tutorial, aligning it for use with `adk web`, `adk run`, and `adk api_server`.
Key changes to the `adk-tutorial` Python files:
- Validated and ensured all tutorial steps are compatible with `google-adk==1.0.0`.
- Synchronized Python file content with the latest changes from the main Colab notebook version.
- Corrected `step2_anthropic.py`: agent name, description, and instruction strings now accurately reflect Anthropic context (previously used GPT-related strings).
- Updated model identifiers: `anthropic/claude-sonnet-4-20250514` in `step2_anthropic.py` and `openai/gpt-4.1` in `step2_gpt4.py`.
- Performed general cleanup and refactoring in `step3_agent_team.py`.
- Added example queries directly within the agent Python files for Steps 1, 2, 3, 5, and 6 to facilitate easier testing by users.
- Removed `step4_state_personalization.py` as its demonstration of session state manipulation (especially direct InMemorySessionService updates) is better suited for an interactive notebook environment.
README.md Updates:
- Added a note explaining the removal of Step 4 and directing users to the interactive notebook version for that specific content.
- Included references to the newly added sample queries in the agent Python files, guiding users on how to test the agent's functionalities.
Correct `adk run` and `adk api_server` commands by removing script-specific references. Adjust documentation link titles and URLs to point to updated sections for clarity and accuracy.
Co-authored-by: Kristopher Overholt <koverholt@gmail.com>
* feat: Add shop agent notebook
This is a supplemental notebook sample for upcoming video created with Sita.
* fix: add mermaid code for the diagram
add mermaid code for the diagram
---------
Co-authored-by: Sita Lakshmi Sangameswaran <sitalakshmi@google.com>
* feat: Improve workflow agent examples (Loop, Parallel, Sequence)
This commit enhances the examples for LoopAgent, ParallelAgent, and SequenceAgent to provide clearer usage patterns, demonstrate key features, and improve developer experience.
Agent-Specific Fixes & Enhancements:
LoopAgent:
Adds an example demonstrating CheckCondition usage, showing both max_iterations and custom condition-based termination.
Fixesgoogle/adk-docs#67, google/adk-docs#148, google/adk-python#315
ParallelAgent:
Adds an example showing how to merge outputs from parallel branches using a subsequent SequentialAgent and agent states.
Demonstrates state/output control after parallel execution.
Fixesgoogle/adk-docs#142
SequenceAgent:
Clarifies the example to show explicit use of agent states within instructions for passing outputs between sequential steps.
Fixesgoogle/adk-docs#150
General Example Improvements (Applied across all three):
Updated examples to use InMemoryRunner.
Adopted new, clearer instruction prompt templates.
Included runner.run_async calls in standalone .py files to demonstrate programmatic execution outside adk web.
Enhanced InMemoryRunner print output for better visibility of individual agent outputs during execution.
Added commented-out asyncio.run() calls in .py files for environments requiring explicit async loop management.
Included multiple example queries in .py files for testing.
Added "Part of agent.py -->" comment for easy copy-pasting into agent.py for use with adk web.
Added copyright and license headers for each file.
* fix: instructions for LoopAgent is cleaned up and removed backticks. Changed the init to include initial state in the ---8<
* feat(LoopAgent): add exit_loop tool for controlled exit
Introduces the `exit_loop` tool, enabling the agent to programmatically trigger an exit from its processing loop based on internal logic or tool usage.
fix(LoopAgent): correct state f-string formatting
Resolves runtime errors caused by incorrect f-string formatting when state variables were used within the agent's execution flow.
chore: Temporarily comment out session/runner setup
Comments out initialization code related to session, runner, and agent interaction for debugging/refactoring purposes. This section should be revisited.
* fix: tutorial section overhaul and bug fixes
- Tutorial section is moved out of getting started and is a seperate section
- Fixed a sentence in getting-started page that still showed “google search”
- Given we will have more tutorials as part of docs, now we have sub-sections with the tutorial name
- For weather agent team - fixed issues pointed out in #118#135
- It now includes code for asynio in the notebook
- It also now has .py file to run it through adk web
- Step 2 is now optional and not connected to other steps. So user can follow other steps if they choose to
- There is disclaimer at the top - for different method to run the code
- The text on the page is now synced with notebook
- Collab and social link are updated with new changes in folder.
* added a redirect in the redirect_maps
* adding license headers in the code for tutorial for .py files
Changed the agent's description from second-person (you) to third-person (this agent).
I also fixed a couple of grammatical errors in the agent's instructions.
* fix: update gemini 2.0 flash to latest model id for Live API
* fix: use -flash for most pages instead of the live api model
* fix: wording andformatting
* fix: resolve merge conflict