1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
/*
* OpenAI API
*
* The OpenAI REST API. Please see pub https://platform.openai.com/docs/api-reference for more details.
*
* OpenAPI spec pub version: 2.3.0
*
* Generated pub by: https://github.com/swagger-api/swagger-codegen.git
*/
/// pub FileSearchTool : A tool that searches for relevant content from uploaded files. Learn more about the [file search tool](https://platform.openai.com/docs/guides/tools-file-search).
#[allow(unused_imports)]
use serde_json::Value;
#[derive(Debug, Serialize, Deserialize)]
pub struct FileSearchTool {
#[serde(rename = "filters")]
pub filters: Option<Value>,
/// The maximum number of results to return. This number should be between 1 and 50 inclusive.
#[serde(rename = "max_num_results")]
pub max_num_results: Option<i32>,
/// Ranking options for search.
#[serde(rename = "ranking_options")]
pub ranking_options: Option<crate::models::RankingOptions>,
/// The type of the file search tool. Always `file_search`.
#[serde(rename = "type")]
#[serde(default = "default_type")]
pub _type: String,
/// The IDs of the vector stores to search.
#[serde(rename = "vector_store_ids")]
pub vector_store_ids: Vec<String>,
}
fn default_type() -> String {
"file_search".into()
}