This PR introduces two new optional fields, order_by and canonical_filter, to the VertexAISearchRetriever class. These fields enhance the flexibility and control over search queries when using Google Vertex AI Search.
I added the corresponding unit test for creating a search request to verify that the VertexAISearchRetriever correctly creates a SearchRequest object with the expected auto-populated fields, including the newly added order_by and canonical_filter fields.
Also, I tested it using my data in GCP, checking different configurations and verifying that the parameters are correctly applied and produce the expected results.
PR Description
This PR introduces two new optional fields,
order_by
andcanonical_filter
, to theVertexAISearchRetriever
class. These fields enhance the flexibility and control over search queries when using Google Vertex AI Search.Type
🆕 New Feature ✅ Test
Issue
https://github.com/langchain-ai/langchain-google/issues/530
Testing
I added the corresponding unit test for creating a search request to verify that the VertexAISearchRetriever correctly creates a
SearchRequest
object with the expected auto-populated fields, including the newly addedorder_by
andcanonical_filter
fields.Also, I tested it using my data in GCP, checking different configurations and verifying that the parameters are correctly applied and produce the expected results.
Thank you again Team!