-
Notifications
You must be signed in to change notification settings - Fork 25.5k
[ES\QL] Add a section for vector functions in the doc. #136077
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
afoucret
merged 16 commits into
elastic:main
from
afoucret:esql-vector-function-doc-page
Oct 7, 2025
Merged
Changes from 2 commits
Commits
Show all changes
16 commits
Select commit
Hold shift + click to select a range
0946c62
Add a section for vector functions in the doc.
afoucret 94f33f1
Add vector functions to the TOC
afoucret 3bccdd5
Hiding snapshot functions.
afoucret 98afbff
Fix KNN docs
afoucret b0d6106
Remove KNN from search functions.
afoucret 7c814f2
Renamed vector functions into dense vector functions
afoucret b7d6732
Fix typo in toc
afoucret 53af9e8
Appy suggestion from review.
afoucret 18652e3
Add a link to dense vector function in the search functions section.
afoucret 2cb9118
Modify the link to dense vector functions in the search function sect…
afoucret 86c7df6
Try to fix dense vectors function list.
afoucret 1c16050
Fix newlines in the code.
afoucret d9ec999
Set specific version for unreleased vector functions (can be revisite…
afoucret e25ebac
Fix versioning of the KNN function.
afoucret 391c6a0
Improved versioning
afoucret 926f490
[CI] Auto commit changes from spotless
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
7 changes: 7 additions & 0 deletions
7
docs/reference/query-languages/esql/_snippets/lists/vector-functions.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
* <<esql-knn>> | ||
* <<esql-v_cosine>> | ||
* <<esql-v_dot_product>> | ||
* <<esql-v_hamming>> | ||
* <<esql-v_l1_norm>> | ||
* <<esql-v_l2_norm>> | ||
* <<esql-v_magnitude>> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
48 changes: 48 additions & 0 deletions
48
docs/reference/query-languages/esql/functions-operators/vector-functions.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
--- | ||
applies_to: | ||
stack: preview | ||
serverless: preview | ||
navigation_title: "Vector functions" | ||
mapped_pages: | ||
- https://www.elastic.co/guide/en/elasticsearch/reference/current/esql-functions-operators.html#esql-vector-functions | ||
--- | ||
|
||
# {{esql}} vector functions [esql-vector-functions] | ||
|
||
{{esql}} supports vector functions for dense vector similarity calculations and k-nearest neighbor search. | ||
|
||
These functions are primarily used for: | ||
- Computing similarity between dense vectors using various similarity metrics | ||
- Finding the k-nearest neighbors in vector space | ||
- Calculating vector magnitudes and norms | ||
|
||
:::{note} | ||
Vector functions are currently in **preview** and may change in future versions. | ||
They work with `dense_vector` fields and require appropriate field mappings. | ||
::: | ||
|
||
{{esql}} supports these vector functions: | ||
|
||
:::{include} ../_snippets/lists/vector-functions.md | ||
::: | ||
|
||
:::{include} ../_snippets/functions/layout/knn.md | ||
::: | ||
|
||
:::{include} ../_snippets/functions/layout/v_cosine.md | ||
::: | ||
|
||
:::{include} ../_snippets/functions/layout/v_dot_product.md | ||
::: | ||
|
||
:::{include} ../_snippets/functions/layout/v_hamming.md | ||
::: | ||
|
||
:::{include} ../_snippets/functions/layout/v_l1_norm.md | ||
::: | ||
|
||
:::{include} ../_snippets/functions/layout/v_l2_norm.md | ||
::: | ||
|
||
:::{include} ../_snippets/functions/layout/v_magnitude.md | ||
::: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.