Skip to content

Commit 8b3fb96

Browse files
Adding embedding type for custom service (#5522) (#5524)
* Adding embedding type * Adding default * Trying to fix formating * Trying to fix formatting 2 (cherry picked from commit 912d733) Co-authored-by: Jonathan Buttner <[email protected]>
1 parent bbbef45 commit 8b3fb96

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

specification/inference/_types/CommonTypes.ts

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1064,6 +1064,22 @@ export class CustomResponseParams {
10641064
* }
10651065
* }
10661066
*
1067+
* # Elasticsearch supports the following embedding types:
1068+
* * float
1069+
* * byte
1070+
* * bit (or binary)
1071+
*
1072+
* To specify the embedding type for the response, the `embedding_type`
1073+
* field should be added in the `json_parser` object. Here's an example:
1074+
* "response":{
1075+
* "json_parser":{
1076+
* "text_embeddings":"$.data[*].embedding[*]",
1077+
* "embedding_type":"bit"
1078+
* }
1079+
* }
1080+
*
1081+
* If `embedding_type` is not specified, it defaults to `float`.
1082+
*
10671083
* # sparse_embedding
10681084
* # For a response like this:
10691085
*

0 commit comments

Comments
 (0)