Refactor/centralize vertex ai version config #924
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Pull-Request Template
Thank you for your contribution! Please provide a brief description of your changes and ensure you've completed the checklist below.
Description
What does this PR do?
Centralizes the Vertex AI API version in [default.py] via a new VERTEX_API_VERSION setting (defaulting to v1beta1).
Updates all Vertex/GenAI client initializations in
models/character_consistency.pymodels/image_models.pymodels/model_setup.pymodels/upscale.pymodels/veo.pyvto.pyto pass
http_options={'api_version': cfg.VERTEX_API_VERSION}(or config.VERTEX_API_VERSION), merging with any existing http_options where needed.Why is it necessary?
Consistency: Previously, the Vertex AI API version was either implicit or scattered; centralizing it avoids subtle mismatches across different model entry points.
Configurability: The API version can now be changed via configuration/environment without code changes, simplifying upgrades and rollbacks when Vertex AI versions change.
Reliability: Explicitly setting the API version reduces risk of breaking changes when the default backend version changes, helping keep all media workflows (Imagen, Veo, VTO, upscaling, character consistency) behaving predictably across environments.
Fixes #913 (if applicable)
Checklist
nox -s formatto format the code.aaie_notebook_template.ipynbif submitting a new jupyter notebook.