agent-starter-pack 0.2.3__tar.gz → 0.3.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of agent-starter-pack might be problematic. Click here for more details.
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/.cloudbuild/terraform/build_triggers.tf +16 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/Makefile +1 -1
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/PKG-INFO +8 -4
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/README.md +7 -3
- agent_starter_pack-0.3.1/agents/adk_base/README.md +14 -0
- agent_starter_pack-0.3.1/agents/adk_base/app/agent.py +66 -0
- agent_starter_pack-0.3.1/agents/adk_base/notebooks/adk_app_testing.ipynb +305 -0
- agent_starter_pack-0.3.1/agents/adk_base/template/.templateconfig.yaml +21 -0
- agent_starter_pack-0.3.1/agents/adk_base/tests/integration/test_agent.py +58 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/agentic_rag/README.md +1 -0
- agent_starter_pack-0.3.1/agents/agentic_rag/app/agent.py +116 -0
- agent_starter_pack-0.3.1/agents/agentic_rag/app/templates.py +28 -0
- agent_starter_pack-0.3.1/agents/agentic_rag/notebooks/adk_app_testing.ipynb +305 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/agentic_rag/template/.templateconfig.yaml +3 -1
- agent_starter_pack-0.3.1/agents/agentic_rag/tests/integration/test_agent.py +64 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/langgraph_base_react/README.md +1 -1
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/langgraph_base_react/template/.templateconfig.yaml +1 -1
- agent_starter_pack-0.3.1/docs/images/adk_logo.png +0 -0
- agent_starter_pack-0.3.1/docs/images/ags_high_level_architecture.png +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/pyproject.toml +2 -2
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/Makefile +9 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/README.md +1 -1
- agent_starter_pack-0.3.1/src/base_template/app/__init__.py +3 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/app/utils/tracing.py +12 -2
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/app/utils/typing.py +54 -4
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/terraform/dev/variables.tf +4 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/terraform/dev/vars/env.tfvars +0 -3
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/terraform/variables.tf +4 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/terraform/vars/env.tfvars +0 -4
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/pyproject.toml +5 -3
- {agent_starter_pack-0.2.3/src/deployment_targets/agent_engine → agent_starter_pack-0.3.1/src/base_template}/tests/unit/test_dummy.py +2 -1
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/cli/commands/create.py +10 -2
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/cli/commands/setup_cicd.py +3 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/cli/utils/gcp.py +1 -1
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/cli/utils/template.py +32 -25
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/data_ingestion/data_ingestion_pipeline/components/ingest_data.py +2 -1
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/deployment_targets/agent_engine/app/agent_engine_app.py +62 -11
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/deployment_targets/agent_engine/app/utils/gcs.py +1 -1
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/deployment_targets/agent_engine/tests/integration/test_agent_engine_app.py +63 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/deployment_targets/agent_engine/tests/load_test/load_test.py +9 -2
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/deployment_targets/cloud_run/app/server.py +41 -15
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/deployment_targets/cloud_run/tests/integration/test_server_e2e.py +60 -3
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/deployment_targets/cloud_run/tests/load_test/README.md +1 -1
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/deployment_targets/cloud_run/tests/load_test/load_test.py +57 -24
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/package-lock.json +3 -3
- agent_starter_pack-0.3.1/src/frontends/streamlit_adk/frontend/side_bar.py +214 -0
- agent_starter_pack-0.3.1/src/frontends/streamlit_adk/frontend/streamlit_app.py +314 -0
- agent_starter_pack-0.3.1/src/frontends/streamlit_adk/frontend/style/app_markdown.py +37 -0
- agent_starter_pack-0.3.1/src/frontends/streamlit_adk/frontend/utils/chat_utils.py +84 -0
- agent_starter_pack-0.3.1/src/frontends/streamlit_adk/frontend/utils/local_chat_history.py +110 -0
- agent_starter_pack-0.3.1/src/frontends/streamlit_adk/frontend/utils/message_editing.py +61 -0
- agent_starter_pack-0.3.1/src/frontends/streamlit_adk/frontend/utils/multimodal_utils.py +223 -0
- agent_starter_pack-0.3.1/src/frontends/streamlit_adk/frontend/utils/stream_handler.py +311 -0
- agent_starter_pack-0.3.1/src/frontends/streamlit_adk/frontend/utils/title_summary.py +129 -0
- agent_starter_pack-0.2.3/src/resources/locks/uv-agentic_rag-agent_engine.lock → agent_starter_pack-0.3.1/src/resources/locks/uv-adk_base-agent_engine.lock +870 -854
- agent_starter_pack-0.2.3/src/resources/locks/uv-agentic_rag-cloud_run.lock → agent_starter_pack-0.3.1/src/resources/locks/uv-adk_base-cloud_run.lock +1002 -1013
- agent_starter_pack-0.3.1/src/resources/locks/uv-agentic_rag-agent_engine.lock +5525 -0
- agent_starter_pack-0.3.1/src/resources/locks/uv-agentic_rag-cloud_run.lock +6117 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/resources/locks/uv-crewai_coding_crew-agent_engine.lock +712 -606
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/resources/locks/uv-crewai_coding_crew-cloud_run.lock +770 -672
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/resources/locks/uv-langgraph_base_react-agent_engine.lock +602 -529
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/resources/locks/uv-langgraph_base_react-cloud_run.lock +763 -665
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/resources/locks/uv-live_api-cloud_run.lock +760 -662
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/tests/cicd/test_e2e_deployment.py +3 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/tests/integration/test_templated_patterns.py +0 -5
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/uv.lock +1 -1
- agent_starter_pack-0.2.3/agents/agentic_rag/app/agent.py +0 -161
- agent_starter_pack-0.2.3/agents/agentic_rag/app/templates.py +0 -53
- agent_starter_pack-0.2.3/agents/agentic_rag/tests/integration/test_agent.py +0 -57
- agent_starter_pack-0.2.3/agents/langgraph_base_react/notebooks/evaluating_langgraph_agent.ipynb +0 -1561
- agent_starter_pack-0.2.3/docs/images/ags_high_level_architecture.png +0 -0
- agent_starter_pack-0.2.3/src/base_template/tests/unit/test_utils/test_tracing_exporter.py +0 -140
- agent_starter_pack-0.2.3/src/deployment_targets/cloud_run/tests/unit/test_server.py +0 -124
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/.cloudbuild/cd/test_e2e.yaml +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/.cloudbuild/ci/build_use_wheel.yaml +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/.cloudbuild/ci/lint.yaml +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/.cloudbuild/ci/lint_templated_agents.yaml +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/.cloudbuild/ci/test.yaml +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/.cloudbuild/ci/test_templated_agents.yaml +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/.cloudbuild/terraform/apis.tf +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/.cloudbuild/terraform/service_account.tf +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/.cloudbuild/terraform/storage.tf +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/.cloudbuild/terraform/variables.tf +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/.gitignore +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/CODE_OF_CONDUCT.md +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/CONTRIBUTING.md +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/LICENSE +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/agentic_rag/app/retrievers.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/crewai_coding_crew/README.md +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/crewai_coding_crew/app/agent.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/crewai_coding_crew/app/crew/config/agents.yaml +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/crewai_coding_crew/app/crew/config/tasks.yaml +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/crewai_coding_crew/app/crew/crew.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/crewai_coding_crew/notebooks/evaluating_crewai_agent.ipynb +0 -0
- {agent_starter_pack-0.2.3/agents/agentic_rag → agent_starter_pack-0.3.1/agents/crewai_coding_crew}/notebooks/evaluating_langgraph_agent.ipynb +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/crewai_coding_crew/template/.templateconfig.yaml +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/crewai_coding_crew/tests/integration/test_agent.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/langgraph_base_react/app/agent.py +0 -0
- {agent_starter_pack-0.2.3/agents/crewai_coding_crew → agent_starter_pack-0.3.1/agents/langgraph_base_react}/notebooks/evaluating_langgraph_agent.ipynb +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/langgraph_base_react/tests/integration/test_agent.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/live_api/README.md +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/live_api/app/agent.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/live_api/app/server.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/live_api/app/templates.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/live_api/app/vector_store.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/live_api/template/.templateconfig.yaml +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/live_api/tests/integration/test_server_e2e.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/live_api/tests/load_test/load_test.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/agents/live_api/tests/unit/test_server.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/docs/README.md +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/docs/cli/README.md +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/docs/cli/create.md +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/docs/cli/setup_cicd.md +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/docs/data-ingestion.md +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/docs/deployment.md +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/docs/images/ags_banner.png +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/docs/installation.md +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/docs/observability.md +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/docs/troubleshooting.md +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/docs/why_starter_pack.md +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/.gitignore +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/README.md +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/cd/deploy-to-prod.yaml +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/cd/staging.yaml +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/ci/pr_checks.yaml +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/terraform/apis.tf +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/terraform/build_triggers.tf +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/terraform/dev/apis.tf +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/terraform/dev/iam.tf +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/terraform/dev/log_sinks.tf +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/terraform/dev/providers.tf +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/terraform/dev/storage.tf +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/terraform/iam.tf +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/terraform/locals.tf +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/terraform/log_sinks.tf +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/terraform/providers.tf +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/terraform/service_accounts.tf +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/base_template/deployment/terraform/storage.tf +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/cli/main.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/cli/utils/__init__.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/cli/utils/cicd.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/cli/utils/datastores.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/cli/utils/logging.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/cli/utils/version.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/data_ingestion/README.md +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/data_ingestion/data_ingestion_pipeline/components/process_data.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/data_ingestion/data_ingestion_pipeline/pipeline.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/data_ingestion/data_ingestion_pipeline/submit_pipeline.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/data_ingestion/pyproject.toml +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/data_ingestion/uv.lock +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/deployment_targets/agent_engine/deployment_metadata.json +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/deployment_targets/agent_engine/notebooks/intro_agent_engine.ipynb +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/deployment_targets/agent_engine/tests/load_test/.results/.placeholder +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/deployment_targets/agent_engine/tests/load_test/README.md +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/deployment_targets/cloud_run/Dockerfile +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/deployment_targets/cloud_run/tests/load_test/.results/.placeholder +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/deployment_targets/cloud_run/uv.lock +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/package.json +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/public/favicon.ico +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/public/index.html +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/public/robots.txt +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/App.scss +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/App.test.tsx +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/App.tsx +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/components/audio-pulse/AudioPulse.tsx +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/components/audio-pulse/audio-pulse.scss +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/components/control-tray/ControlTray.tsx +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/components/control-tray/control-tray.scss +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/components/logger/Logger.tsx +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/components/logger/logger.scss +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/components/logger/mock-logs.ts +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/components/side-panel/SidePanel.tsx +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/components/side-panel/side-panel.scss +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/contexts/LiveAPIContext.tsx +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/hooks/use-live-api.ts +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/hooks/use-media-stream-mux.ts +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/hooks/use-screen-capture.ts +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/hooks/use-webcam.ts +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/index.css +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/index.tsx +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/multimodal-live-types.ts +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/react-app-env.d.ts +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/reportWebVitals.ts +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/setupTests.ts +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/utils/audio-recorder.ts +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/utils/audio-streamer.ts +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/utils/audioworklet-registry.ts +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/utils/multimodal-live-client.ts +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/utils/store-logger.ts +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/utils/utils.ts +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/utils/worklets/audio-processing.ts +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/src/utils/worklets/vol-meter.ts +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/live_api_react/frontend/tsconfig.json +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/streamlit/frontend/side_bar.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/streamlit/frontend/streamlit_app.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/streamlit/frontend/style/app_markdown.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/streamlit/frontend/utils/chat_utils.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/streamlit/frontend/utils/local_chat_history.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/streamlit/frontend/utils/message_editing.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/streamlit/frontend/utils/multimodal_utils.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/streamlit/frontend/utils/stream_handler.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/frontends/streamlit/frontend/utils/title_summary.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/resources/containers/data_processing/Dockerfile +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/resources/containers/e2e-tests/Dockerfile +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/resources/setup_cicd/cicd_variables.tf +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/resources/setup_cicd/github.tf +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/resources/setup_cicd/providers.tf +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/utils/generate_locks.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/utils/lock_utils.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/src/utils/watch_and_rebuild.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/tests/__init__.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/tests/cicd/example.env +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/tests/cli/commands/test_create.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/tests/cli/commands/test_setup_cicd.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/tests/cli/utils/test_cicd.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/tests/integration/test_template_linting.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/tests/test_frontend/test_side_bar.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/tests/test_frontend/test_streamlit_app.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/tests/test_frontend/test_utils/test_chat_utils.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/tests/test_frontend/test_utils/test_local_chat_history.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/tests/test_frontend/test_utils/test_message_editing.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/tests/test_frontend/test_utils/test_multimodal_utils.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/tests/test_frontend/test_utils/test_stream_handler.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/tests/utils/__init__.py +0 -0
- {agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/tests/utils/get_agents.py +0 -0
{agent_starter_pack-0.2.3 → agent_starter_pack-0.3.1}/.cloudbuild/terraform/build_triggers.tf
RENAMED
|
@@ -48,6 +48,14 @@ locals {
|
|
|
48
48
|
|
|
49
49
|
# Define a local variable for agent/deployment combinations
|
|
50
50
|
agent_testing_combinations = [
|
|
51
|
+
{
|
|
52
|
+
name = "adk_base-agent_engine"
|
|
53
|
+
value = "adk_base,agent_engine"
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
name = "adk_base-cloud_run"
|
|
57
|
+
value = "adk_base,cloud_run"
|
|
58
|
+
},
|
|
51
59
|
{
|
|
52
60
|
name = "langgraph_base_react-agent_engine"
|
|
53
61
|
value = "langgraph_base_react,agent_engine"
|
|
@@ -94,6 +102,14 @@ locals {
|
|
|
94
102
|
]
|
|
95
103
|
}
|
|
96
104
|
e2e_agent_deployment_combinations = [
|
|
105
|
+
{
|
|
106
|
+
name = "adk_base-agent_engine"
|
|
107
|
+
value = "adk_base,agent_engine"
|
|
108
|
+
},
|
|
109
|
+
{
|
|
110
|
+
name = "adk_base-cloud_run"
|
|
111
|
+
value = "adk_base,cloud_run"
|
|
112
|
+
},
|
|
97
113
|
{
|
|
98
114
|
name = "langgraph_base_react-agent_engine"
|
|
99
115
|
value = "langgraph_base_react,agent_engine"
|
|
@@ -13,7 +13,7 @@ generate-lock:
|
|
|
13
13
|
lint:
|
|
14
14
|
uv run ruff check . --config pyproject.toml --diff
|
|
15
15
|
uv run ruff format . --check --config pyproject.toml --diff
|
|
16
|
-
uv run mypy --config-file pyproject.toml ./agents ./src/cli ./tests ./src/frontends/streamlit
|
|
16
|
+
uv run mypy --config-file pyproject.toml ./agents ./src/cli ./tests ./src/frontends/streamlit ./src/frontends/streamlit_adk
|
|
17
17
|
|
|
18
18
|
lint-templated-agents:
|
|
19
19
|
uv run tests/integration/test_template_linting.py
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: agent-starter-pack
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.3.1
|
|
4
4
|
Summary: CLI tool to create GCP-based AI agent projects from templates
|
|
5
5
|
Author-email: Google LLC <agent-starter-pack@google.com>
|
|
6
6
|
License: Apache-2.0
|
|
@@ -60,7 +60,7 @@ For more installation options, see the [Installation Guide](docs/installation.md
|
|
|
60
60
|
🆕 The starter pack offers full support for Agent Engine, a new fully managed solution to deploy agents. Simply run this command to get started:
|
|
61
61
|
|
|
62
62
|
```bash
|
|
63
|
-
agent-starter-pack create my-agent -d agent_engine -a
|
|
63
|
+
agent-starter-pack create my-agent -d agent_engine -a adk_base
|
|
64
64
|
```
|
|
65
65
|
|
|
66
66
|
|
|
@@ -70,13 +70,17 @@ agent-starter-pack create my-agent -d agent_engine -a langgraph_base_react
|
|
|
70
70
|
|
|
71
71
|
| Agent Name | Description |
|
|
72
72
|
|-----------------------------|-----------------------------------------------------------------------------------------------------------------------------------|
|
|
73
|
-
| `
|
|
74
|
-
| `agentic_rag` | A RAG agent
|
|
73
|
+
| `adk_base` | An agent implementing a base ReAct agent using Google's [Agent Development Kit](https://github.com/google/adk-python)
|
|
74
|
+
| `agentic_rag` | A RAG agent for document retrieval and Q&A. Supporting [Vertex AI Search](https://cloud.google.com/generative-ai-app-builder/docs/enterprise-search-introduction) and [Vector Search](https://cloud.google.com/vertex-ai/docs/vector-search/overview). |
|
|
75
|
+
| `langgraph_base_react` | An agent implementing a base ReAct agent using LangGraph |
|
|
75
76
|
| `crewai_coding_crew` | A multi-agent system implemented with CrewAI created to support coding activities |
|
|
76
77
|
| `live_api` | A real-time multimodal RAG agent powered by Gemini, supporting audio/video/text chat with vector DB-backed responses |
|
|
77
78
|
|
|
78
79
|
**More agents are on the way!** We are continuously expanding our [agent library](./agents/). Have a specific agent type in mind? [Contribute!](#contributing)
|
|
79
80
|
|
|
81
|
+
**🔍 ADK Samples**
|
|
82
|
+
|
|
83
|
+
Looking to explore more ADK examples? Check out the [ADK Samples Repository](https://github.com/google/adk-samples) for additional examples and use cases demonstrating ADK's capabilities.
|
|
80
84
|
|
|
81
85
|
#### Extra Features
|
|
82
86
|
|
|
@@ -35,7 +35,7 @@ For more installation options, see the [Installation Guide](docs/installation.md
|
|
|
35
35
|
🆕 The starter pack offers full support for Agent Engine, a new fully managed solution to deploy agents. Simply run this command to get started:
|
|
36
36
|
|
|
37
37
|
```bash
|
|
38
|
-
agent-starter-pack create my-agent -d agent_engine -a
|
|
38
|
+
agent-starter-pack create my-agent -d agent_engine -a adk_base
|
|
39
39
|
```
|
|
40
40
|
|
|
41
41
|
|
|
@@ -45,13 +45,17 @@ agent-starter-pack create my-agent -d agent_engine -a langgraph_base_react
|
|
|
45
45
|
|
|
46
46
|
| Agent Name | Description |
|
|
47
47
|
|-----------------------------|-----------------------------------------------------------------------------------------------------------------------------------|
|
|
48
|
-
| `
|
|
49
|
-
| `agentic_rag` | A RAG agent
|
|
48
|
+
| `adk_base` | An agent implementing a base ReAct agent using Google's [Agent Development Kit](https://github.com/google/adk-python)
|
|
49
|
+
| `agentic_rag` | A RAG agent for document retrieval and Q&A. Supporting [Vertex AI Search](https://cloud.google.com/generative-ai-app-builder/docs/enterprise-search-introduction) and [Vector Search](https://cloud.google.com/vertex-ai/docs/vector-search/overview). |
|
|
50
|
+
| `langgraph_base_react` | An agent implementing a base ReAct agent using LangGraph |
|
|
50
51
|
| `crewai_coding_crew` | A multi-agent system implemented with CrewAI created to support coding activities |
|
|
51
52
|
| `live_api` | A real-time multimodal RAG agent powered by Gemini, supporting audio/video/text chat with vector DB-backed responses |
|
|
52
53
|
|
|
53
54
|
**More agents are on the way!** We are continuously expanding our [agent library](./agents/). Have a specific agent type in mind? [Contribute!](#contributing)
|
|
54
55
|
|
|
56
|
+
**🔍 ADK Samples**
|
|
57
|
+
|
|
58
|
+
Looking to explore more ADK examples? Check out the [ADK Samples Repository](https://github.com/google/adk-samples) for additional examples and use cases demonstrating ADK's capabilities.
|
|
55
59
|
|
|
56
60
|
#### Extra Features
|
|
57
61
|
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# ADK: Minimal Agent Example
|
|
2
|
+
|
|
3
|
+
[](https://google.github.io/adk-docs/)
|
|
4
|
+
|
|
5
|
+
A basic agent built using the **[Google Agent Development Kit (ADK)](https://google.github.io/adk-docs/)**. This example demonstrates core ADK concepts like agent creation and tool integration in a minimal setup.
|
|
6
|
+
|
|
7
|
+
This agent uses the `gemini-2.0-flash` model and is equipped with two simple tools:
|
|
8
|
+
* `get_weather`: Simulates fetching weather (hardcoded for SF).
|
|
9
|
+
* `get_current_time`: Simulates fetching the time (hardcoded for SF).
|
|
10
|
+
|
|
11
|
+
## Additional Resources
|
|
12
|
+
|
|
13
|
+
- **ADK Samples**: Explore more examples and use cases in the [official ADK Samples Repository](https://github.com/google/adk-samples)
|
|
14
|
+
- **ADK Documentation**: Learn more about ADK concepts and capabilities in the [official documentation](https://google.github.io/adk-docs/)
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
# Copyright 2025 Google LLC
|
|
2
|
+
#
|
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
+
# you may not use this file except in compliance with the License.
|
|
5
|
+
# You may obtain a copy of the License at
|
|
6
|
+
#
|
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
|
8
|
+
#
|
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
12
|
+
# See the License for the specific language governing permissions and
|
|
13
|
+
# limitations under the License.
|
|
14
|
+
|
|
15
|
+
import datetime
|
|
16
|
+
import os
|
|
17
|
+
from zoneinfo import ZoneInfo
|
|
18
|
+
|
|
19
|
+
import google.auth
|
|
20
|
+
from google.adk.agents import Agent
|
|
21
|
+
|
|
22
|
+
_, project_id = google.auth.default()
|
|
23
|
+
os.environ.setdefault("GOOGLE_CLOUD_PROJECT", project_id)
|
|
24
|
+
os.environ.setdefault("GOOGLE_CLOUD_LOCATION", "us-central1")
|
|
25
|
+
os.environ.setdefault("GOOGLE_GENAI_USE_VERTEXAI", "True")
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
def get_weather(query: str) -> str:
|
|
29
|
+
"""Simulates a web search. Use it get information on weather.
|
|
30
|
+
|
|
31
|
+
Args:
|
|
32
|
+
query: A string containing the location to get weather information for.
|
|
33
|
+
|
|
34
|
+
Returns:
|
|
35
|
+
A string with the simulated weather information for the queried location.
|
|
36
|
+
"""
|
|
37
|
+
if "sf" in query.lower() or "san francisco" in query.lower():
|
|
38
|
+
return "It's 60 degrees and foggy."
|
|
39
|
+
return "It's 90 degrees and sunny."
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
def get_current_time(query: str) -> str:
|
|
43
|
+
"""Simulates getting the current time for a city.
|
|
44
|
+
|
|
45
|
+
Args:
|
|
46
|
+
city: The name of the city to get the current time for.
|
|
47
|
+
|
|
48
|
+
Returns:
|
|
49
|
+
A string with the current time information.
|
|
50
|
+
"""
|
|
51
|
+
if "sf" in query.lower() or "san francisco" in query.lower():
|
|
52
|
+
tz_identifier = "America/Los_Angeles"
|
|
53
|
+
else:
|
|
54
|
+
return f"Sorry, I don't have timezone information for query: {query}."
|
|
55
|
+
|
|
56
|
+
tz = ZoneInfo(tz_identifier)
|
|
57
|
+
now = datetime.datetime.now(tz)
|
|
58
|
+
return f"The current time for query {query} is {now.strftime('%Y-%m-%d %H:%M:%S %Z%z')}"
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
root_agent = Agent(
|
|
62
|
+
name="root_agent",
|
|
63
|
+
model="gemini-2.0-flash",
|
|
64
|
+
instruction="You are a helpful AI assistant designed to provide accurate and useful information.",
|
|
65
|
+
tools=[get_weather, get_current_time],
|
|
66
|
+
)
|
|
@@ -0,0 +1,305 @@
|
|
|
1
|
+
{
|
|
2
|
+
"cells": [
|
|
3
|
+
{
|
|
4
|
+
"cell_type": "markdown",
|
|
5
|
+
"metadata": {},
|
|
6
|
+
"source": [
|
|
7
|
+
"# ADK Application Testing\n",
|
|
8
|
+
"\n",
|
|
9
|
+
"This notebook demonstrates how to test an ADK (Agent Development Kit) application.\n",
|
|
10
|
+
"It covers both local and remote testing, both with Agent Engine and Cloud Run.\n",
|
|
11
|
+
"\n",
|
|
12
|
+
"<img src=\"https://github.com/GoogleCloudPlatform/agent-starter-pack/blob/main/docs/images/adk_logo.png?raw=true\" width=\"400\">\n"
|
|
13
|
+
]
|
|
14
|
+
},
|
|
15
|
+
{
|
|
16
|
+
"cell_type": "markdown",
|
|
17
|
+
"metadata": {},
|
|
18
|
+
"source": [
|
|
19
|
+
"### Import libraries"
|
|
20
|
+
]
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
"cell_type": "code",
|
|
24
|
+
"execution_count": 1,
|
|
25
|
+
"metadata": {},
|
|
26
|
+
"outputs": [],
|
|
27
|
+
"source": [
|
|
28
|
+
"import json\n",
|
|
29
|
+
"\n",
|
|
30
|
+
"import requests\n",
|
|
31
|
+
"import vertexai.agent_engines"
|
|
32
|
+
]
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"cell_type": "markdown",
|
|
36
|
+
"metadata": {},
|
|
37
|
+
"source": [
|
|
38
|
+
"## If you are using Agent Engine\n",
|
|
39
|
+
"See more documentation at [Agent Engine Overview](https://cloud.google.com/vertex-ai/generative-ai/docs/agent-engine/overview)"
|
|
40
|
+
]
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"cell_type": "markdown",
|
|
44
|
+
"metadata": {},
|
|
45
|
+
"source": [
|
|
46
|
+
"### Local Testing\n",
|
|
47
|
+
"\n",
|
|
48
|
+
"You can import directly the AgentEngineApp class within your environment. "
|
|
49
|
+
]
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
"cell_type": "code",
|
|
53
|
+
"execution_count": 2,
|
|
54
|
+
"metadata": {},
|
|
55
|
+
"outputs": [],
|
|
56
|
+
"source": [
|
|
57
|
+
"from app.agent import root_agent\n",
|
|
58
|
+
"from app.agent_engine_app import AgentEngineApp\n",
|
|
59
|
+
"\n",
|
|
60
|
+
"agent_engine = AgentEngineApp(agent=root_agent)"
|
|
61
|
+
]
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
"cell_type": "code",
|
|
65
|
+
"execution_count": null,
|
|
66
|
+
"metadata": {},
|
|
67
|
+
"outputs": [],
|
|
68
|
+
"source": [
|
|
69
|
+
"for event in agent_engine.stream_query(message=\"hi!\", user_id=\"test\"):\n",
|
|
70
|
+
" print(event)"
|
|
71
|
+
]
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
"cell_type": "markdown",
|
|
75
|
+
"metadata": {},
|
|
76
|
+
"source": [
|
|
77
|
+
"### Remote Testing"
|
|
78
|
+
]
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
"cell_type": "code",
|
|
82
|
+
"execution_count": 4,
|
|
83
|
+
"metadata": {},
|
|
84
|
+
"outputs": [],
|
|
85
|
+
"source": [
|
|
86
|
+
"# Replace with your Agent Engine ID\n",
|
|
87
|
+
"AGENT_ENGINE_ID = \"projects/PROJECT_ID/locations/us-central1/reasoningEngines/ENGINE_ID\""
|
|
88
|
+
]
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
"cell_type": "code",
|
|
92
|
+
"execution_count": 5,
|
|
93
|
+
"metadata": {},
|
|
94
|
+
"outputs": [],
|
|
95
|
+
"source": [
|
|
96
|
+
"remote_agent_engine = vertexai.agent_engines.get(AGENT_ENGINE_ID)"
|
|
97
|
+
]
|
|
98
|
+
},
|
|
99
|
+
{
|
|
100
|
+
"cell_type": "code",
|
|
101
|
+
"execution_count": null,
|
|
102
|
+
"metadata": {},
|
|
103
|
+
"outputs": [],
|
|
104
|
+
"source": [
|
|
105
|
+
"for event in remote_agent_engine.stream_query(message=\"hi!\", user_id=\"test\"):\n",
|
|
106
|
+
" print(event)"
|
|
107
|
+
]
|
|
108
|
+
},
|
|
109
|
+
{
|
|
110
|
+
"cell_type": "markdown",
|
|
111
|
+
"metadata": {},
|
|
112
|
+
"source": [
|
|
113
|
+
"## If you are using Cloud Run"
|
|
114
|
+
]
|
|
115
|
+
},
|
|
116
|
+
{
|
|
117
|
+
"cell_type": "markdown",
|
|
118
|
+
"metadata": {},
|
|
119
|
+
"source": [
|
|
120
|
+
"### Local Testing\n",
|
|
121
|
+
"\n",
|
|
122
|
+
"> You can run the application locally via the `make backend` command."
|
|
123
|
+
]
|
|
124
|
+
},
|
|
125
|
+
{
|
|
126
|
+
"cell_type": "markdown",
|
|
127
|
+
"metadata": {},
|
|
128
|
+
"source": [
|
|
129
|
+
"#### Create a session\n",
|
|
130
|
+
" Create a new session with user preferences and state information\n"
|
|
131
|
+
]
|
|
132
|
+
},
|
|
133
|
+
{
|
|
134
|
+
"cell_type": "code",
|
|
135
|
+
"execution_count": null,
|
|
136
|
+
"metadata": {},
|
|
137
|
+
"outputs": [],
|
|
138
|
+
"source": [
|
|
139
|
+
"user_id = \"test_user_123\"\n",
|
|
140
|
+
"session_id = \"test_session_456\"\n",
|
|
141
|
+
"session_data = {\"state\": {\"preferred_language\": \"English\", \"visit_count\": 1}}\n",
|
|
142
|
+
"\n",
|
|
143
|
+
"session_url = f\"http://127.0.0.1:8000/apps/app/users/{user_id}/sessions/{session_id}\"\n",
|
|
144
|
+
"headers = {\"Content-Type\": \"application/json\"}\n",
|
|
145
|
+
"\n",
|
|
146
|
+
"session_response = requests.post(session_url, headers=headers, json=session_data)\n",
|
|
147
|
+
"print(f\"Session creation status code: {session_response.status_code}\")"
|
|
148
|
+
]
|
|
149
|
+
},
|
|
150
|
+
{
|
|
151
|
+
"cell_type": "markdown",
|
|
152
|
+
"metadata": {},
|
|
153
|
+
"source": [
|
|
154
|
+
"#### Send a message\n",
|
|
155
|
+
"Send a message to the backend service and receive a streaming response\n"
|
|
156
|
+
]
|
|
157
|
+
},
|
|
158
|
+
{
|
|
159
|
+
"cell_type": "code",
|
|
160
|
+
"execution_count": null,
|
|
161
|
+
"metadata": {},
|
|
162
|
+
"outputs": [],
|
|
163
|
+
"source": [
|
|
164
|
+
"message_data = {\n",
|
|
165
|
+
" \"app_name\": \"app\",\n",
|
|
166
|
+
" \"user_id\": user_id,\n",
|
|
167
|
+
" \"session_id\": session_id,\n",
|
|
168
|
+
" \"new_message\": {\"role\": \"user\", \"parts\": [{\"text\": \"Hello! Weather in New york?\"}]},\n",
|
|
169
|
+
" \"streaming\": True,\n",
|
|
170
|
+
"}\n",
|
|
171
|
+
"\n",
|
|
172
|
+
"message_url = \"http://127.0.0.1:8000/run_sse\"\n",
|
|
173
|
+
"message_response = requests.post(\n",
|
|
174
|
+
" message_url, headers=headers, json=message_data, stream=True\n",
|
|
175
|
+
")\n",
|
|
176
|
+
"\n",
|
|
177
|
+
"print(f\"Message send status code: {message_response.status_code}\")\n",
|
|
178
|
+
"\n",
|
|
179
|
+
"# Print streamed response\n",
|
|
180
|
+
"for line in message_response.iter_lines():\n",
|
|
181
|
+
" if line:\n",
|
|
182
|
+
" line_str = line.decode(\"utf-8\")\n",
|
|
183
|
+
" if line_str.startswith(\"data: \"):\n",
|
|
184
|
+
" event_json = line_str[6:]\n",
|
|
185
|
+
" event = json.loads(event_json)\n",
|
|
186
|
+
" print(f\"Received event: {event}\")"
|
|
187
|
+
]
|
|
188
|
+
},
|
|
189
|
+
{
|
|
190
|
+
"cell_type": "markdown",
|
|
191
|
+
"metadata": {},
|
|
192
|
+
"source": [
|
|
193
|
+
"#### Remote Testing\n",
|
|
194
|
+
"\n",
|
|
195
|
+
"For more information about authenticating HTTPS requests to Cloud Run services, see:\n",
|
|
196
|
+
"[Cloud Run Authentication Documentation](https://cloud.google.com/run/docs/triggering/https-request)\n",
|
|
197
|
+
"\n",
|
|
198
|
+
"Remote testing involves using a deployed service URL instead of localhost.\n",
|
|
199
|
+
"\n",
|
|
200
|
+
"Authentication is handled using GCP identity tokens instead of local credentials."
|
|
201
|
+
]
|
|
202
|
+
},
|
|
203
|
+
{
|
|
204
|
+
"cell_type": "code",
|
|
205
|
+
"execution_count": 20,
|
|
206
|
+
"metadata": {},
|
|
207
|
+
"outputs": [],
|
|
208
|
+
"source": [
|
|
209
|
+
"ID_TOKEN = get_ipython().getoutput(\"gcloud auth print-identity-token -q\")[0]"
|
|
210
|
+
]
|
|
211
|
+
},
|
|
212
|
+
{
|
|
213
|
+
"cell_type": "code",
|
|
214
|
+
"execution_count": null,
|
|
215
|
+
"metadata": {},
|
|
216
|
+
"outputs": [],
|
|
217
|
+
"source": [
|
|
218
|
+
"SERVICE_URL = \"YOUR_SERVICE_URL_HERE\" # Replace with your Cloud Run service URL"
|
|
219
|
+
]
|
|
220
|
+
},
|
|
221
|
+
{
|
|
222
|
+
"cell_type": "markdown",
|
|
223
|
+
"metadata": {},
|
|
224
|
+
"source": [
|
|
225
|
+
"You'll need to first create a Session"
|
|
226
|
+
]
|
|
227
|
+
},
|
|
228
|
+
{
|
|
229
|
+
"cell_type": "code",
|
|
230
|
+
"execution_count": null,
|
|
231
|
+
"metadata": {},
|
|
232
|
+
"outputs": [],
|
|
233
|
+
"source": [
|
|
234
|
+
"user_id = \"test_user_123\"\n",
|
|
235
|
+
"session_id = \"test_session_456\"\n",
|
|
236
|
+
"session_data = {\"state\": {\"preferred_language\": \"English\", \"visit_count\": 1}}\n",
|
|
237
|
+
"\n",
|
|
238
|
+
"session_url = f\"{SERVICE_URL}/apps/app/users/{user_id}/sessions/{session_id}\"\n",
|
|
239
|
+
"headers = {\"Content-Type\": \"application/json\", \"Authorization\": f\"Bearer {ID_TOKEN}\"}\n",
|
|
240
|
+
"\n",
|
|
241
|
+
"session_response = requests.post(session_url, headers=headers, json=session_data)\n",
|
|
242
|
+
"print(f\"Session creation status code: {session_response.status_code}\")"
|
|
243
|
+
]
|
|
244
|
+
},
|
|
245
|
+
{
|
|
246
|
+
"cell_type": "markdown",
|
|
247
|
+
"metadata": {},
|
|
248
|
+
"source": [
|
|
249
|
+
"Then you will be able to send a message"
|
|
250
|
+
]
|
|
251
|
+
},
|
|
252
|
+
{
|
|
253
|
+
"cell_type": "code",
|
|
254
|
+
"execution_count": null,
|
|
255
|
+
"metadata": {},
|
|
256
|
+
"outputs": [],
|
|
257
|
+
"source": [
|
|
258
|
+
"message_data = {\n",
|
|
259
|
+
" \"app_name\": \"app\",\n",
|
|
260
|
+
" \"user_id\": user_id,\n",
|
|
261
|
+
" \"session_id\": session_id,\n",
|
|
262
|
+
" \"new_message\": {\"role\": \"user\", \"parts\": [{\"text\": \"Hello! Weather in New york?\"}]},\n",
|
|
263
|
+
" \"streaming\": True,\n",
|
|
264
|
+
"}\n",
|
|
265
|
+
"\n",
|
|
266
|
+
"message_url = f\"{SERVICE_URL}/run_sse\"\n",
|
|
267
|
+
"message_response = requests.post(\n",
|
|
268
|
+
" message_url, headers=headers, json=message_data, stream=True\n",
|
|
269
|
+
")\n",
|
|
270
|
+
"\n",
|
|
271
|
+
"print(f\"Message send status code: {message_response.status_code}\")\n",
|
|
272
|
+
"\n",
|
|
273
|
+
"# Print streamed response\n",
|
|
274
|
+
"for line in message_response.iter_lines():\n",
|
|
275
|
+
" if line:\n",
|
|
276
|
+
" line_str = line.decode(\"utf-8\")\n",
|
|
277
|
+
" if line_str.startswith(\"data: \"):\n",
|
|
278
|
+
" event_json = line_str[6:]\n",
|
|
279
|
+
" event = json.loads(event_json)\n",
|
|
280
|
+
" print(f\"Received event: {event}\")"
|
|
281
|
+
]
|
|
282
|
+
}
|
|
283
|
+
],
|
|
284
|
+
"metadata": {
|
|
285
|
+
"kernelspec": {
|
|
286
|
+
"display_name": ".venv",
|
|
287
|
+
"language": "python",
|
|
288
|
+
"name": "python3"
|
|
289
|
+
},
|
|
290
|
+
"language_info": {
|
|
291
|
+
"codemirror_mode": {
|
|
292
|
+
"name": "ipython",
|
|
293
|
+
"version": 3
|
|
294
|
+
},
|
|
295
|
+
"file_extension": ".py",
|
|
296
|
+
"mimetype": "text/x-python",
|
|
297
|
+
"name": "python",
|
|
298
|
+
"nbconvert_exporter": "python",
|
|
299
|
+
"pygments_lexer": "ipython3",
|
|
300
|
+
"version": "3.12.8"
|
|
301
|
+
}
|
|
302
|
+
},
|
|
303
|
+
"nbformat": 4,
|
|
304
|
+
"nbformat_minor": 2
|
|
305
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# Copyright 2025 Google LLC
|
|
2
|
+
#
|
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
+
# you may not use this file except in compliance with the License.
|
|
5
|
+
# You may obtain a copy of the License at
|
|
6
|
+
#
|
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
|
8
|
+
#
|
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
12
|
+
# See the License for the specific language governing permissions and
|
|
13
|
+
# limitations under the License.
|
|
14
|
+
|
|
15
|
+
description: "An agent implementing a base ReAct agent using Google's Agent Development Kit"
|
|
16
|
+
settings:
|
|
17
|
+
requires_data_ingestion: false
|
|
18
|
+
deployment_targets: ["agent_engine", "cloud_run"]
|
|
19
|
+
extra_dependencies: ["google-adk~=0.1.0"]
|
|
20
|
+
tags: ["adk"]
|
|
21
|
+
frontend_type: "None"
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
# Copyright 2025 Google LLC
|
|
2
|
+
#
|
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
+
# you may not use this file except in compliance with the License.
|
|
5
|
+
# You may obtain a copy of the License at
|
|
6
|
+
#
|
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
|
8
|
+
#
|
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
12
|
+
# See the License for the specific language governing permissions and
|
|
13
|
+
# limitations under the License.
|
|
14
|
+
|
|
15
|
+
# mypy: disable-error-code="union-attr"
|
|
16
|
+
from google.adk.agents.run_config import RunConfig, StreamingMode
|
|
17
|
+
from google.adk.runners import Runner
|
|
18
|
+
from google.adk.sessions import InMemorySessionService
|
|
19
|
+
from google.genai import types
|
|
20
|
+
|
|
21
|
+
from app.agent import root_agent
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
def test_agent_stream() -> None:
|
|
25
|
+
"""
|
|
26
|
+
Integration test for the agent stream functionality.
|
|
27
|
+
Tests that the agent returns valid streaming responses.
|
|
28
|
+
"""
|
|
29
|
+
|
|
30
|
+
session_service = InMemorySessionService()
|
|
31
|
+
|
|
32
|
+
session = session_service.create_session(user_id="test_user", app_name="test")
|
|
33
|
+
runner = Runner(agent=root_agent, session_service=session_service, app_name="test")
|
|
34
|
+
|
|
35
|
+
message = types.Content(
|
|
36
|
+
role="user", parts=[types.Part.from_text(text="Why is the sky blue?")]
|
|
37
|
+
)
|
|
38
|
+
|
|
39
|
+
events = list(
|
|
40
|
+
runner.run(
|
|
41
|
+
new_message=message,
|
|
42
|
+
user_id="test_user",
|
|
43
|
+
session_id=session.id,
|
|
44
|
+
run_config=RunConfig(streaming_mode=StreamingMode.SSE),
|
|
45
|
+
)
|
|
46
|
+
)
|
|
47
|
+
assert len(events) > 0, "Expected at least one message"
|
|
48
|
+
|
|
49
|
+
has_text_content = False
|
|
50
|
+
for event in events:
|
|
51
|
+
if (
|
|
52
|
+
event.content
|
|
53
|
+
and event.content.parts
|
|
54
|
+
and any(part.text for part in event.content.parts)
|
|
55
|
+
):
|
|
56
|
+
has_text_content = True
|
|
57
|
+
break
|
|
58
|
+
assert has_text_content, "Expected at least one message with text content"
|
|
@@ -14,6 +14,7 @@ The agent implements the following architecture:
|
|
|
14
14
|
|
|
15
15
|
### Key Features
|
|
16
16
|
|
|
17
|
+
- **Built on Agent Development Kit (ADK):** ADK is a flexible, modular framework for developing and deploying AI agents. It integrates with the Google ecosystem and Gemini models, supporting various LLMs and open-source AI tools, enabling both simple and complex agent architectures.
|
|
17
18
|
- **Flexible Datastore Options:** Choose between Vertex AI Search or Vertex AI Vector Search for efficient data storage and retrieval based on your specific needs.
|
|
18
19
|
- **Automated Data Ingestion Pipeline:** Automates the process of ingesting data from input sources.
|
|
19
20
|
- **Custom Embeddings:** Generates embeddings using Vertex AI Embeddings and incorporates them into your data for enhanced semantic search.
|