A tool that searches for relevant content from uploaded files. Learn more about the file search tool.

interface FileSearchTool {
    filters?: ComparisonFilter | CompoundFilter;
    max_num_results?: number;
    ranking_options?: OpenAIClient.Responses.FileSearchTool.RankingOptions;
    type: "file_search";
    vector_store_ids: string[];
}

Properties

filters?: ComparisonFilter | CompoundFilter

A filter to apply based on file attributes.

max_num_results?: number

The maximum number of results to return. This number should be between 1 and 50 inclusive.

Ranking options for search.

type: "file_search"

The type of the file search tool. Always file_search.

vector_store_ids: string[]

The IDs of the vector stores to search.