Skip to content

Commit 2cd12a5

Browse files
committed
Addresses feedback.
1 parent bdc3db8 commit 2cd12a5

File tree

1 file changed

+30
-15
lines changed

1 file changed

+30
-15
lines changed

docs/reference/elasticsearch/mapping-reference/semantic-text.md

Lines changed: 30 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -33,22 +33,9 @@ Newly created indices with `semantic_text` fields using dense embeddings will be
3333
[quantized](/reference/elasticsearch/mapping-reference/dense-vector.md#dense-vector-quantization)
3434
to `bbq_hnsw` automatically.
3535

36-
{applies_to}`stack: preview 9.1` If you use the preconfigured `.elser-2-elastic` endpoint that utilizes the ELSER model as a service (ELSER on EIS), you can
37-
set up `semantic_text` with the following API request:
36+
## Default and custom endpoints
3837

39-
```console
40-
PUT my-index-000001
41-
{
42-
"mappings": {
43-
"properties": {
44-
"inference_field": {
45-
"type": "semantic_text",
46-
"inference_id": ".elser-2-elastic"
47-
}
48-
}
49-
}
50-
}
51-
```
38+
### Using the default ELSER endpoint
5239

5340
If you use the preconfigured `.elser-2-elasticsearch` endpoint, you can set up
5441
`semantic_text` with the following API request:
@@ -66,6 +53,8 @@ PUT my-index-000001
6653
}
6754
```
6855

56+
### Using a custom endpoint
57+
6958
To use a custom {{infer}} endpoint instead of the default
7059
`.elser-2-elasticsearch`, you
7160
must [Create {{infer}} API](https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-inference-put)
@@ -109,6 +98,32 @@ PUT my-index-000003
10998
}
11099
```
111100

101+
### Using ELSER on EIS
102+
103+
```{applies_to}
104+
stack: preview 9.1
105+
serverless: preview
106+
```
107+
108+
If you use the preconfigured `.elser-2-elastic` endpoint that utilizes the ELSER model as a service ([ELSER on EIS](docs-content://explore-analyze/elastic-inference/eis.md#elser-on-eis)), you can
109+
set up `semantic_text` with the following API request:
110+
111+
```console
112+
PUT my-index-000001
113+
{
114+
"mappings": {
115+
"properties": {
116+
"inference_field": {
117+
"type": "semantic_text",
118+
"inference_id": ".elser-2-elastic"
119+
}
120+
}
121+
}
122+
}
123+
```
124+
125+
While we do encourage experimentation, we do not recommend implementing production use cases on top of this feature while it is in Technical Preview.
126+
112127
## Parameters for `semantic_text` fields [semantic-text-params]
113128

114129
`inference_id`

0 commit comments

Comments
 (0)