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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
|
{
"openapi": "3.1.0",
"info": {
"title": "Azure AI Search",
"description": "Retrieves knowledges for a question.",
"version": "v1.0.0"
},
"servers": [
{
"url": "https://{your-search-name}.search.windows.net"
}
],
"paths": {
"/indexes/{your-index-name}/docs/search": {
"post": {
"description": "Search knowledges for keywords",
"operationId": "Search",
"parameters": [
{
"name": "api-version",
"in": "query",
"description": "the version of api.",
"required": true,
"schema": {
"type": "string",
"default": "2023-10-01-Preview"
}
}
],
"requestBody": {
"required": true,
"description": "Information about a new query",
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"top",
"select",
"search",
"vectorQueries",
"queryType",
"semanticConfiguration",
"captions",
"answers",
"queryLanguage"
],
"properties": {
"top": {
"type": "integer",
"default": 2
},
"select": {
"type": "string",
"default": "chunk,title"
},
"search": {
"type": "string"
},
"vectorQueries": {
"description": "array about query",
"type": "array",
"items": {
"$ref": "#/components/schemas/VectorQuery"
}
},
"queryType": {
"type": "string",
"default": "semantic"
},
"semanticConfiguration": {
"type": "string",
"default": {your-semantic-configuration}
},
"captions": {
"type": "string",
"default": "extractive"
},
"answers": {
"type": "string",
"default": "extractive|count-3"
},
"queryLanguage": {
"type": "string",
"default": "zh-CN"
}
}
}
}
}
},
"responses": {
"200": {
"description": "Get the result"
}
},
"deprecated": false
}
}
},
"components": {
"schemas": {
"VectorQuery": {
"type": "object",
"required": [
"kind",
"text",
"k",
"fields"
],
"properties": {
"kind": {
"description": "string type, value is alway default",
"type": "string",
"default": "text",
"enum": [
"text"
]
},
"text": {
"description": "string equals to query search",
"type": "string"
},
"k": {
"type": "integer",
"default": 5
},
"fields": {
"description": "string type, value is alway default",
"type": "string",
"default": "vector",
"enum": [
"vector"
]
}
}
}
}
}
}
|