You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/expression/function/fulltext/Match.java
+54-13Lines changed: 54 additions & 13 deletions
Original file line number
Diff line number
Diff line change
@@ -173,13 +173,33 @@ public Match(
173
173
description = "Value to find in the provided field."
174
174
) ExpressionmatchQuery,
175
175
@MapParam(
176
-
name="options",
176
+
name = "options",
177
177
params = {
178
-
@MapParam.MapParamEntry(name = "analyzer", valueHint = { "standard" }, description = "Analyzer used to convert the text in the query value into token."),
179
-
@MapParam.MapParamEntry(name = "auto_generate_synonyms_phrase_query", valueHint = { "true", "false" }, description = "If true, match phrase queries are automatically created for multi-term synonyms."),
@MapParam.MapParamEntry(name = "boost", valueHint = { "2.5" }, description = "Floating point number used to decrease or increase the relevance scores of the query."),
182
-
@MapParam.MapParamEntry(name = "fuzzy_transpositions", valueHint = { "true", "false" }, description = "If true, edits for fuzzy matching include transpositions of two adjacent characters (ab → ba)."),
178
+
@MapParam.MapParamEntry(
179
+
name = "analyzer",
180
+
valueHint = { "standard" },
181
+
description = "Analyzer used to convert the text in the query value into token."
182
+
),
183
+
@MapParam.MapParamEntry(
184
+
name = "auto_generate_synonyms_phrase_query",
185
+
valueHint = { "true", "false" },
186
+
description = "If true, match phrase queries are automatically created for multi-term synonyms."
187
+
),
188
+
@MapParam.MapParamEntry(
189
+
name = "fuzziness",
190
+
valueHint = { "AUTO", "1", "2" },
191
+
description = "Maximum edit distance allowed for matching."
192
+
),
193
+
@MapParam.MapParamEntry(
194
+
name = "boost",
195
+
valueHint = { "2.5" },
196
+
description = "Floating point number used to decrease or increase the relevance scores of the query."
197
+
),
198
+
@MapParam.MapParamEntry(
199
+
name = "fuzzy_transpositions",
200
+
valueHint = { "true", "false" },
201
+
description = "If true, edits for fuzzy matching include transpositions of two adjacent characters (ab → ba)."
202
+
),
183
203
@MapParam.MapParamEntry(
184
204
name = "fuzzy_rewrite",
185
205
valueHint = {
@@ -188,14 +208,35 @@ public Match(
188
208
"constant_score_boolean",
189
209
"top_terms_blended_freqs_N",
190
210
"top_terms_boost_N",
191
-
"top_terms_N" }, description = "Method used to rewrite the query. See the rewrite parameter for valid values and more information."
211
+
"top_terms_N" },
212
+
description = "Method used to rewrite the query. See the rewrite parameter for valid values and more information."
213
+
),
214
+
@MapParam.MapParamEntry(
215
+
name = "lenient",
216
+
valueHint = { "true", "false" },
217
+
description = "If false, format-based errors, such as providing a text query value for a numeric field, are not ignored."
218
+
),
219
+
@MapParam.MapParamEntry(
220
+
name = "max_expansions",
221
+
valueHint = { "50" },
222
+
description = "Maximum number of terms to which the query will expand."
223
+
),
224
+
@MapParam.MapParamEntry(
225
+
name = "minimum_should_match",
226
+
valueHint = { "2" },
227
+
description = "Minimum number of clauses that must match for a document to be returned."
228
+
),
229
+
@MapParam.MapParamEntry(
230
+
name = "operator",
231
+
valueHint = { "AND", "OR" },
232
+
description = "Boolean logic used to interpret text in the query value"
192
233
),
193
-
@MapParam.MapParamEntry(name = "lenient", valueHint = { "true", "false" }, description = "If false, format-based errors, such as providing a text query value for a numeric field, are not ignored."),
194
-
@MapParam.MapParamEntry(name = "max_expansions", valueHint = { "50" }, description = "Maximum number of terms to which the query will expand."),
195
-
@MapParam.MapParamEntry(name = "minimum_should_match", valueHint = { "2" }, description = "Minimum number of clauses that must match for a document to be returned."),
196
-
@MapParam.MapParamEntry(name = "operator", valueHint = { "AND", "OR" }, description = "Boolean logic used to interpret text in the query value"),
Copy file name to clipboardExpand all lines: x-pack/plugin/esql/src/test/java/org/elasticsearch/xpack/esql/expression/function/fulltext/MatchTests.java
0 commit comments