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
NOTE: In Serverless, you must create an {infer} endpoint using the <<put-inference-api>> and reference it when setting up `semantic_text` even if you use the ELSER service.
38
+
39
+
If you use a service other than ELSER, you must create an {infer} endpoint using the <<put-inference-api>> and reference it when setting up `semantic_text` as the following example demonstrates:
<1> The task type is `sparse_embedding` in the path as the `elser` service will
50
-
be used and ELSER creates sparse vectors. The `inference_id` is
51
-
`my-elser-endpoint`.
52
-
<2> The `elser` service is used in this example.
53
-
<3> This setting enables and configures {ml-docs}/ml-nlp-auto-scale.html#nlp-model-adaptive-allocations[adaptive allocations].
54
-
Adaptive allocations make it possible for ELSER to automatically scale up or down resources based on the current load on the process.
27
+
NOTE: In Serverless, you must create an {infer} endpoint using the <<put-inference-api>> and reference it when setting up `semantic_text` even if you use the ELSER service.
55
28
56
-
[NOTE]
57
-
====
58
-
You might see a 502 bad gateway error in the response when using the {kib} Console.
59
-
This error usually just reflects a timeout, while the model downloads in the background.
60
-
You can check the download progress in the {ml-app} UI.
61
-
If using the Python client, you can set the `timeout` parameter to a higher value.
62
-
====
63
29
64
30
[discrete]
65
31
[[semantic-text-index-mapping]]
@@ -75,8 +41,7 @@ PUT semantic-embeddings
75
41
"mappings": {
76
42
"properties": {
77
43
"content": { <1>
78
-
"type": "semantic_text", <2>
79
-
"inference_id": "my-elser-endpoint" <3>
44
+
"type": "semantic_text" <2>
80
45
}
81
46
}
82
47
}
@@ -85,9 +50,16 @@ PUT semantic-embeddings
85
50
// TEST[skip:TBD]
86
51
<1> The name of the field to contain the generated embeddings.
87
52
<2> The field to contain the embeddings is a `semantic_text` field.
88
-
<3> The `inference_id` is the inference endpoint you created in the previous step.
89
-
It will be used to generate the embeddings based on the input text.
90
-
Every time you ingest data into the related `semantic_text` field, this endpoint will be used for creating the vector representation of the text.
53
+
Since no `inference_id` is provided, the <<infer-service-elser,ELSER service>> is used by default.
54
+
To use a different {infer} service, you must create an {infer} endpoint first using the <<put-inference-api>> and then specify it in the `semantic_text` field mapping using the `inference_id` parameter.
55
+
56
+
57
+
[NOTE]
58
+
====
59
+
If you're using web crawlers or connectors to generate indices, you have to <<indices-put-mapping,update the index mappings>> for these indices to include the `semantic_text` field.
60
+
Once the mapping is updated, you'll need to run a full web crawl or a full connector sync.
61
+
This ensures that all existing documents are reprocessed and updated with the new semantic embeddings, enabling semantic search on the updated data.
0 commit comments