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
[Docs] Edit semantic_text update instructions for clarity (#137345)
* [Docd] Update semantic_text update instructions for clarity
while reviewing #137340, I noticed this section was a little messy
refactored to use definition lists
* Clarify instructions on preserving embeddings
Copy file name to clipboardExpand all lines: docs/reference/elasticsearch/mapping-reference/semantic-text.md
+9-9Lines changed: 9 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -424,20 +424,20 @@ POST test-index/_search
424
424
425
425
## Updates and partial updates for `semantic_text` fields [semantic-text-updates]
426
426
427
-
When updating documents that contain `semantic_text` fields, it’s important to understand how inference is triggered:
427
+
When updating documents that contain `semantic_text` fields, it's important to understand how inference is triggered:
428
428
429
-
***Full document updates**
430
-
When you perform a full document update, **all `semantic_text` fields will re-run inference**even if their values did not change. This ensures that the embeddings are always consistent with the current document state but can increase ingestion costs.
429
+
Full document updates
430
+
: Full document updates re-run inference on all `semantic_text` fields, even if their values did not change. This ensures that embeddings remain consistent with the current document state but can increase ingestion costs.
431
431
432
-
***Partial updates using the Bulk API**
433
-
Partial updates that **omit `semantic_text` fields** and are submitted through the [Bulk API](https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-bulk)will **reuse the existing embeddings** stored in the index. In this case, inference is **not triggered** for fields that were not updated, which can significantly reduce processing time and cost.
432
+
Partial updates using the Bulk API
433
+
: Partial updates submitted through the [Bulk API](https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-bulk) reuse existing embeddings when you omit `semantic_text` fields. Inference does not run for omitted fields, which can significantly reduce processing time and cost.
434
434
435
-
***Partial updates using the Update API**
436
-
When using the [Update API](https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-update)with a `doc` object that **omits `semantic_text` fields**, inference **will still run** on all `semantic_text` fields. This means that even if the field values are not changed, embeddings will be re-generated.
435
+
Partial updates using the Update API
436
+
: Partial updates submitted through the [Update API](https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-update)re-run inference on all `semantic_text` fields, even when you omit them from the `doc` object. Embeddings are re-generated regardless of whether field values changed.
437
437
438
-
If you want to avoid unnecessary inference and keep existing embeddings:
438
+
To preserve existing embeddings and avoid unnecessary inference costs:
439
439
440
-
* Use **partial updates through the Bulk API**.
440
+
* Use partial updates with the Bulk API.
441
441
* Omit any `semantic_text` fields that did not change from the `doc` object in your request.
0 commit comments