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: solutions/search/retrievers-examples.md
+13-4Lines changed: 13 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -392,7 +392,9 @@ Which would return the following results:
392
392
393
393
## Example: Grouping results by year with `collapse`[retrievers-examples-collapsing-retriever-results]
394
394
395
-
In our result set, we have many documents with the same `year` value. We can clean this up using the `collapse` parameter with our retriever. This, as with the standard [collapse](/raw-migrated-files/elasticsearch/elasticsearch-reference/collapse-search-results.md) feature, enables grouping results by any field and returns only the highest-scoring document from each group. In this example we’ll collapse our results based on the `year` field.
395
+
In our result set, we have many documents with the same `year` value. We can clean this up using the `collapse` parameter with our retriever. This, as with the standard
enables grouping results by any field and returns only the highest-scoring document from each group. In this example we’ll collapse our results based on the `year` field.
396
398
397
399
```console
398
400
GET /retrievers_example/_search
@@ -541,7 +543,9 @@ This returns the following response with collapsed results.
541
543
542
544
## Example: Highlighting results based on nested sub-retrievers [retrievers-examples-highlighting-retriever-results]
543
545
544
-
Highlighting is now also available for nested sub-retrievers matches. For example, consider the same `rrf` retriever as above, with a `knn` and `standard` retriever as its sub-retrievers. We can specify a `highlight` section, as defined in [highlighting](/raw-migrated-files/elasticsearch/elasticsearch-reference/highlighting.md) documentation, and compute highlights for the top results.
546
+
Highlighting is now also available for nested sub-retrievers matches. For example, consider the same `rrf` retriever as above, with a `knn` and `standard` retriever as its sub-retrievers. We can specify a `highlight` section,
547
+
% TODO URL as defined in the [highlighting](/raw-migrated-files/elasticsearch/elasticsearch-reference/highlighting.md) documentation,
548
+
and compute highlights for the top results.
545
549
546
550
```console
547
551
GET /retrievers_example/_search
@@ -738,7 +742,9 @@ POST /retrievers_example_nested/_doc/3
738
742
POST /retrievers_example_nested/_refresh
739
743
```
740
744
741
-
Now we can run an `rrf` retriever query and also compute [inner hits](/raw-migrated-files/elasticsearch/elasticsearch-reference/inner-hits.md) for the `nested_field.nested_vector` field, based on the `knn` query specified.
745
+
Now we can run an `rrf` retriever query and also compute inner hits
746
+
% TODO URL [inner hits](/raw-migrated-files/elasticsearch/elasticsearch-reference/inner-hits.md)
747
+
for the `nested_field.nested_vector` field, based on the `knn` query specified.
742
748
743
749
```console
744
750
GET /retrievers_example_nested/_search
@@ -1261,7 +1267,10 @@ The output of which, albeit a bit verbose, will provide all the necessary info t
1261
1267
1262
1268
## Example: Rerank results of an RRF retriever [retrievers-examples-text-similarity-reranker-on-top-of-rrf]
1263
1269
1264
-
To demonstrate the full functionality of retrievers, the following examples also require access to a [semantic reranking model](/raw-migrated-files/elasticsearch/elasticsearch-reference/semantic-reranking.md#semantic-reranking-models) set up using the [Elastic inference APIs](/raw-migrated-files/elasticsearch/elasticsearch-reference/inference-apis.md).
1270
+
To demonstrate the full functionality of retrievers, the following examples also require access to a semantic reranking model
1271
+
% TODO URL [semantic reranking model](/raw-migrated-files/elasticsearch/elasticsearch-reference/semantic-reranking.md#semantic-reranking-models)
0 commit comments