Skip to content

Conversation

@cnaples79
Copy link

@cnaples79 cnaples79 commented Oct 15, 2025

Summary

Migrates RAG-related code from using the preview API to the stable API.

Changes Made

Updated import statements in RAG agent files.

Rationale

The Vertex AI RAG API has moved from preview to stable. Using the stable import ensures:

  • Better API stability and support
  • Alignment with current Vertex AI best practices
  • Future compatibility as preview APIs may be deprecated

Testing

  • Verified import statements are syntactically correct
  • No functional changes to the code logic

Fixes #395

Update RAG-related imports to use stable vertexai API instead of
preview API:
- Change 'from vertexai.preview import rag' to 'from vertexai import rag'

Files updated:
- python/agents/RAG/rag/agent.py
- python/agents/RAG/rag/shared_libraries/prepare_corpus_and_data.py

Fixes google#395
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

refactor code from using vertexai.preview to vertexai

1 participant