Add Exmaples for how to use A2UI on Gemini Enterprise#1043
Add Exmaples for how to use A2UI on Gemini Enterprise#1043yuantian-agentspace merged 8 commits intomainfrom
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces comprehensive samples and scripts for deploying A2UI agents on Gemini Enterprise using both Vertex AI Agent Engine and Cloud Run. The implementation includes a base agent executor with A2UI validation, sample UI templates, and registration logic. The review feedback identifies several critical issues that need to be addressed: a shell syntax error in the documentation's curl command, potential data corruption in the JSON cleaning logic due to incorrect string stripping, the use of invalid Gemini model identifiers across multiple files, and a dependency mismatch in the requirements file that would result in runtime import errors.
samples/agent/adk/gemini_enterprise/agent_engine/agent_executor.py
Outdated
Show resolved
Hide resolved
samples/agent/adk/gemini_enterprise/agent_engine/gemini_agent.py
Outdated
Show resolved
Hide resolved
|
Hi Yuan, Thanks for the PR. Can you work with @nan-yu to use the python SDK he built for things like loading samples, loading the catalog, generating system instructions, etc? It'll let this sample focus on the interesting behavior (GE integration) and stop using some antipatterns we have in our earlier samples like copy and pasting the catalog json into a python string. |
| "--- ContactAgent.fetch_response: Received no final response" | ||
| f" content from runner (Attempt {attempt}). ---" | ||
| ) | ||
| if attempt <= max_retries: |
There was a problem hiding this comment.
im not sure we need this retries TBH, we already auto correct malformed json and it complicates the code, but feel free to leave if it you find them useful @nan-yu
There was a problem hiding this comment.
I think it's okay to keep the retry here as the auto-fixer only removes trailing commas for now. There're other JSON failures, such as fields in snake_case vs. camelCase.
The retry may not be triggered because the examples have the correct format, but it may serve as a guardrail for other random failures.
Description
Provide examples of how to use A2UI on Gemini Enterprise. It covers Cloud Run deployment and Agent Engine Deployment.
Pre-launch Checklist
If you need help, consider asking for advice on the discussion board.