Feature/integrate brand aligner#1288
Conversation
Signed-off-by: Moises Bitton Simana <162650235+MoisesRBitton@users.noreply.github.com>
…ussain/adk-samples-capstone into feature/integrate-brand-aligner
| packages = ["financial_advisor"] | ||
|
|
||
| [tool.ruff.lint.pydocstyle] | ||
| convention = "google" |
There was a problem hiding this comment.
why was this removed? is it not in the other files? aim for consistency and intentional changes
| indent-style = "space" | ||
| quote-style = "double" | ||
| skip-magic-trailing-comma = false | ||
| docstring-code-format = true |
There was a problem hiding this comment.
why was this removed? is it not in the other files? aim for consistency and intentional changes
|
|
||
| [[tool.uv.index]] | ||
| url = "https://pypi.org/simple" | ||
| default = true |
There was a problem hiding this comment.
why was this removed? is it not in the other files? aim for consistency and intentional changes
There was a problem hiding this comment.
I'll actually say, I think we do want to keep this. I believe we (Googlers) need it to avoid some package mirror errors
| ``` | ||
|
|
||
| 2. **Configure `.env`:** Open the newly created `.env` file and fill in the required values (Project ID, Region, GCS Bucket, Model Name, etc.). | ||
|
|
There was a problem hiding this comment.
PR #1286 has a pretty good README, we should standardize the UV install block and the getting started to all be about the same. @maeve2024 to collaborate
| * **`ge_register.sh`**: Registers the deployed agent with Gemini Enterprise. | ||
| * **`ge_unregister.sh`**: Unregisters the agent from Gemini Enterprise. | ||
|
|
||
| ### Alternative: Using Agent Starter Pack (ASP) |
There was a problem hiding this comment.
ASP should be the default, not the alternative
|
|
||
|
|
||
| class Category(str, StrEnum): | ||
| class Category(StrEnum): |
There was a problem hiding this comment.
please confirm this change is necessary, and that the agent is fully functional via the adk web UI going through a secenario.
| load_dotenv(override=True) | ||
| _, project_id = google.auth.default() | ||
| os.environ.setdefault("GOOGLE_CLOUD_PROJECT", project_id) | ||
| os.environ["GOOGLE_CLOUD_LOCATION"] = "global" |
There was a problem hiding this comment.
should this be a default as well? confirm with other samples
zeroasterisk
left a comment
There was a problem hiding this comment.
ASP Integration Checklist (ref: PR #1286 as approved template)
- ✅ ASP section added,
__init__.pyauth block added ⚠️ ASP listed as "Alternative" — Should be the recommended path. Flip the structure: ASP first withuvxone-liner as the primary command, then collapse the manual setup in<details>. See #1286 for the exact pattern.⚠️ pip/venv is primary,uvxis collapsed — This is backwards.uvxone-liner should be the main visible command, pip/venv in a collapsed<details>block.⚠️ os.environ["GOOGLE_CLOUD_LOCATION"] = "global"is a hard override — Useos.environ.setdefault("GOOGLE_CLOUD_LOCATION", "global")instead. Hard assignment silently overwrites user-configured values.
Main fixes needed: flip ASP to recommended (not alternative), and fix setdefault.
|
Checking in — the review feedback from Mar 21 hasn't been addressed yet. Key changes needed:
See PR #1286 for the exact pattern to follow. |
…ance * restore ruff pydocstyle and format blocks for pyproject consistency * keep tool.uv.index to avoid package mirror issues * make Agent Starter Pack the recommended setup path with uvx one-liner first * move pip or venv setup into collapsed alternative section * change GOOGLE_CLOUD_LOCATION assignment to setdefault to avoid overriding user config * align enum implementation with StrEnum in models for clearer intent
…tristanhussain/adk-samples-capstone into feature/integrate-brand-aligner
zeroasterisk
left a comment
There was a problem hiding this comment.
A few things to adjust:
- Simplify
__init__.pyimports: Currently importing everything (from . import agent, auth, models, services, tools, utils). This can cause circular imports and slows down package initialization. Simplify to just the auth block +from . import agent(or just the auth block if the agent is imported elsewhere). - Bump
agent-starter-packto>=0.32.0 - Position ASP as recommended in README — currently it reads more like an alternative. Make it the primary/recommended setup path, with manual clone in a collapsed
<details>block.
Ref: PR #1368 for a clean example of the pattern.
…sible section fix: remove unused imports in __init__.py deps: bump agent-starter-pack version to 0.32.0 in pyproject.toml and uv.lock
Signed-off-by: Moises Bitton Simana <162650235+MoisesRBitton@users.noreply.github.com>
|
Thanks for the feedback Alan. I’ve addressed all three items in the latest commit and pushed: Simplified package initialization imports to avoid loading everything at import time: |
zeroasterisk
left a comment
There was a problem hiding this comment.
Changes look great, thank you! ✅
zeroasterisk
left a comment
There was a problem hiding this comment.
Changes look great, thank you! ✅
zeroasterisk
left a comment
There was a problem hiding this comment.
Changes look great, thank you! ✅
zeroasterisk
left a comment
There was a problem hiding this comment.
Changes look great, thank you! ✅
Implemented ASP for brand-aligner and cleaned up the project so it actually runs/tests reliably.
ASP config + dependency added
uv-based setup/testing flow
fixed env init/import order
fixed enum issue causing python 3.12 test collection errors
updated README
@zeroasterisk