Class VertexAISearch
Retrieve from Vertex AI Search datastore or engine for grounding. datastore and engine are mutually exclusive. See https://cloud.google.com/products/agent-builder. This data type is not supported in Gemini API.
public record VertexAISearch : IEquatable<VertexAISearch>
- Inheritance
-
VertexAISearch
- Implements
- Inherited Members
Properties
DataStoreSpecs
Specifications that define the specific DataStores to be searched, along with configurations for those data stores. This is only considered for Engines with multiple data stores. It should only be set if engine is used.
[JsonPropertyName("dataStoreSpecs")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public List<VertexAISearchDataStoreSpec>? DataStoreSpecs { get; set; }
Property Value
Datastore
Optional. Fully-qualified Vertex AI Search data store resource ID. Format:
projects/{project}/locations/{location}/collections/{collection}/dataStores/{dataStore}
[JsonPropertyName("datastore")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public string? Datastore { get; set; }
Property Value
Engine
Optional. Fully-qualified Vertex AI Search engine resource ID. Format:
projects/{project}/locations/{location}/collections/{collection}/engines/{engine}
[JsonPropertyName("engine")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public string? Engine { get; set; }
Property Value
Filter
Optional. Filter strings to be passed to the search API.
[JsonPropertyName("filter")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public string? Filter { get; set; }
Property Value
MaxResults
Optional. Number of search results to return per query. The default value is 10. The maximumm allowed value is 10.
[JsonPropertyName("maxResults")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public int? MaxResults { get; set; }
Property Value
- int?
Methods
FromJson(string, JsonSerializerOptions?)
Deserializes a JSON string to a VertexAISearch object.
public static VertexAISearch? FromJson(string jsonString, JsonSerializerOptions? options = null)
Parameters
jsonStringstringThe JSON string to deserialize.
optionsJsonSerializerOptionsOptional JsonSerializerOptions.
Returns
- VertexAISearch
The deserialized VertexAISearch object, or null if deserialization fails.