struct AI::Google::Tools::FileSearch

Overview

File Search tool.

Enables Retrieval Augmented Generation (RAG) via the Gemini File Search tool.

Defined in:

ai/google/google_tools.cr

Constant Summary

ID = "google.file_search"
NAME = "file_search"

Constructors

Instance Method Summary

Constructor Detail

def self.new(file_search_store_names : Array(String), top_k : Int32 | Nil = nil, metadata_filter : String | Nil = nil) #

[View source]

Instance Method Detail

def args : Hash(String, JSON::Any) #

[View source]
def file_search_store_names : Array(String) #

File Search store resource names. Example: "fileSearchStores/my-file-search-store-123"


[View source]
def id : String #

[View source]
def metadata_filter : String | Nil #

Metadata filter to apply to the file search retrieval documents. See https://google.aip.dev/160 for the syntax.


[View source]
def name : String #

[View source]
def top_k : Int32 | Nil #

Number of file search retrieval chunks to retrieve.


[View source]
def type : String #

[View source]