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
Copy file name to clipboardExpand all lines: weaviate/collections/classes/config_named_vectors.py
+73-25
Original file line number
Diff line number
Diff line change
@@ -39,8 +39,10 @@
39
39
AWSModel,
40
40
AWSService,
41
41
CohereModel,
42
+
CohereMultimodalModel,
42
43
CohereTruncation,
43
44
JinaModel,
45
+
JinaMultimodalModel,
44
46
Multi2VecField,
45
47
OpenAIModel,
46
48
OpenAIType,
@@ -51,6 +53,7 @@
51
53
_Text2VecDatabricksConfig,
52
54
_Text2VecVoyageConfig,
53
55
_Multi2VecCohereConfig,
56
+
_Multi2VecJinaConfig,
54
57
)
55
58
from ...warningsimport_Warnings
56
59
@@ -161,7 +164,7 @@ def text2vec_cohere(
161
164
) ->_NamedVectorConfigCreate:
162
165
"""Create a named vector using the `text2vec_cohere` model.
163
166
164
-
See the [documentation](https://weaviate.io/developers/weaviate/modules/retriever-vectorizer-modules/text2vec-cohere)
167
+
See the [documentation](https://weaviate.io/developers/weaviate/model-providers/cohere/embeddings)
165
168
for detailed usage.
166
169
167
170
Arguments:
@@ -183,7 +186,7 @@ def text2vec_cohere(
183
186
The base URL to use where API requests should go. Defaults to `None`, which uses the server-defined default.
184
187
185
188
Raises:
186
-
`pydantic.ValidationError` if `truncate` is not a valid value from the `CohereModel` type.
189
+
`pydantic.ValidationError` if `model` is not a valid value from the `CohereModel` type or if `truncate` is not a valid value from the `CohereTruncation` type.
"""Create a named vector using the `multi2vec_cohere` model.
213
216
214
-
See the [documentation](https://weaviate.io/developers/weaviate/modules/retriever-vectorizer-modules/text2vec-cohere)
217
+
See the [documentation](https://weaviate.io/developers/weaviate/model-providers/cohere/embeddings-multimodal)
215
218
for detailed usage.
216
219
217
220
Arguments:
@@ -225,8 +228,6 @@ def multi2vec_cohere(
225
228
The model to use. Defaults to `None`, which uses the server-defined default.
226
229
`truncate`
227
230
The truncation strategy to use. Defaults to `None`, which uses the server-defined default.
228
-
`vectorize_collection_name`
229
-
Whether to vectorize the collection name. Defaults to `True`.
230
231
`base_url`
231
232
The base URL to use where API requests should go. Defaults to `None`, which uses the server-defined default.
232
233
`image_fields`
@@ -235,7 +236,7 @@ def multi2vec_cohere(
235
236
The text fields to use in vectorization.
236
237
237
238
Raises:
238
-
`pydantic.ValidationError` if `truncate` is not a valid value from the `CohereModel` type.
239
+
`pydantic.ValidationError` if `model` is not a valid value from the `CohereMultimodalModel` type or if `truncate` is not a valid value from the `CohereTruncation` type.
239
240
"""
240
241
return_NamedVectorConfigCreate(
241
242
name=name,
@@ -294,7 +295,7 @@ def text2vec_databricks(
294
295
) ->_NamedVectorConfigCreate:
295
296
"""Create a named vector using the `text2vec-databricks` model.
296
297
297
-
See the [documentation](https://weaviate.io/developers/weaviate/modules/retriever-vectorizer-modules/text2vec-databricks)
298
+
See the [documentation](https://weaviate.io/developers/weaviate/model-providers/databricks/embeddings)
298
299
for detailed usage.
299
300
300
301
Arguments:
@@ -333,7 +334,7 @@ def text2vec_mistral(
333
334
) ->_NamedVectorConfigCreate:
334
335
"""Create a named vector using the `text2vec-mistral` model.
335
336
336
-
See the [documentation](https://weaviate.io/developers/weaviate/modules/retriever-vectorizer-modules/text2vec-mistral)
337
+
See the [documentation](https://weaviate.io/developers/weaviate/model-providers/mistral/embeddings)
337
338
for detailed usage.
338
339
339
340
Arguments:
@@ -370,7 +371,7 @@ def text2vec_ollama(
370
371
) ->_NamedVectorConfigCreate:
371
372
"""Create a named vector using the `text2vec-ollama` model.
372
373
373
-
See the [documentation](https://weaviate.io/developers/weaviate/modules/retriever-vectorizer-modules/text2vec-ollama)
374
+
See the [documentation](https://weaviate.io/developers/weaviate/model-providers/ollama/embeddings)
374
375
for detailed usage.
375
376
376
377
Arguments:
@@ -417,7 +418,7 @@ def text2vec_openai(
417
418
) ->_NamedVectorConfigCreate:
418
419
"""Create a named vector using the `text2vec_openai` model.
419
420
420
-
See the [documentation](https://weaviate.io/developers/weaviate/modules/retriever-vectorizer-modules/text2vec-openai)
421
+
See the [documentation](https://weaviate.io/developers/weaviate/model-providers/openai/embeddings)
421
422
for detailed usage.
422
423
423
424
Arguments:
@@ -473,7 +474,7 @@ def text2vec_aws(
473
474
) ->_NamedVectorConfigCreate:
474
475
"""Create a named vector using the `text2vec_aws` model.
475
476
476
-
See the [documentation](https://weaviate.io/developers/weaviate/modules/retriever-vectorizer-modules/text2vec-aws)
477
+
See the [documentation](https://weaviate.io/developers/weaviate/model-providers/aws/embeddings)
477
478
for detailed usage.
478
479
479
480
Arguments:
@@ -546,7 +547,7 @@ def multi2vec_clip(
546
547
) ->_NamedVectorConfigCreate:
547
548
"""Create a named vector using the `multi2vec_clip` model.
548
549
549
-
See the [documentation](https://weaviate.io/developers/weaviate/modules/retriever-vectorizer-modules/text2vec-gpt4all)
550
+
See the [documentation](https://weaviate.io/developers/weaviate/model-providers/transformers/embeddings-multimodal)
550
551
for detailed usage.
551
552
552
553
Arguments:
@@ -726,7 +727,7 @@ def multi2vec_bind(
726
727
) ->_NamedVectorConfigCreate:
727
728
"""Create a named vector using the `multi2vec_bind` model.
728
729
729
-
See the [documentation](https://weaviate.io/developers/weaviate/modules/retriever-vectorizer-modules/text2vec-gpt4all)
730
+
See the [documentation](https://weaviate.io/developers/weaviate/model-providers/imagebind/embeddings-multimodal)
730
731
for detailed usage.
731
732
732
733
Arguments:
@@ -797,7 +798,7 @@ def text2vec_azure_openai(
797
798
) ->_NamedVectorConfigCreate:
798
799
"""Create a named vector using the `text2vec_azure_openai` model.
799
800
800
-
See the [documentation](https://weaviate.io/developers/weaviate/modules/retriever-vectorizer-modules/text2vec-gpt4all)
801
+
See the [documentation](https://weaviate.io/developers/weaviate/model-providers/openai-azure/embeddings)
801
802
for detailed usage.
802
803
803
804
Arguments:
@@ -832,7 +833,7 @@ def text2vec_gpt4all(
832
833
) ->_NamedVectorConfigCreate:
833
834
"""Create a named vector using the `text2vec_gpt4all` model.
834
835
835
-
See the [documentation](https://weaviate.io/developers/weaviate/modules/retriever-vectorizer-modules/text2vec-gpt4all)
836
+
See the [documentation](https://weaviate.io/developers/weaviate/model-providers/gpt4all/embeddings)
836
837
for detailed usage.
837
838
838
839
Arguments:
@@ -871,7 +872,7 @@ def text2vec_huggingface(
871
872
) ->_NamedVectorConfigCreate:
872
873
"""Create a named vector using the `text2vec_huggingface` model.
873
874
874
-
See the [documentation](https://weaviate.io/developers/weaviate/modules/retriever-vectorizer-modules/text2vec-huggingface)
875
+
See the [documentation](https://weaviate.io/developers/weaviate/model-providers/huggingface/embeddings)
875
876
for detailed usage.
876
877
877
878
Arguments:
@@ -901,7 +902,7 @@ def text2vec_huggingface(
901
902
Raises:
902
903
`pydantic.ValidationError` if the arguments passed to the function are invalid.
903
904
It is important to note that some of these variables are mutually exclusive.
904
-
See the [documentation](https://weaviate.io/developers/weaviate/modules/retriever-vectorizer-modules/text2vec-huggingface) for more details.
905
+
See the [documentation](https://weaviate.io/developers/weaviate/model-providers/huggingface/embeddings#vectorizer-parameters) for more details.
905
906
"""
906
907
return_NamedVectorConfigCreate(
907
908
name=name,
@@ -936,7 +937,7 @@ def text2vec_palm(
936
937
) ->_NamedVectorConfigCreate:
937
938
"""Create a named vector using the `text2vec_palm` model.
938
939
939
-
See the [documentation](https://weaviate.io/developers/weaviate/modules/retriever-vectorizer-modules/text2vec-palm)
940
+
See the [documentation](https://weaviate.io/developers/weaviate/model-providers/google/embeddings)
940
941
for detailed usage.
941
942
942
943
Arguments:
@@ -990,7 +991,7 @@ def text2vec_google(
990
991
) ->_NamedVectorConfigCreate:
991
992
"""Create a named vector using the `text2vec_palm` model.
992
993
993
-
See the [documentation](https://weaviate.io/developers/weaviate/modules/retriever-vectorizer-modules/text2vec-google)
994
+
See the [documentation]https://weaviate.io/developers/weaviate/model-providers/google/embeddings)
994
995
for detailed usage.
995
996
996
997
Arguments:
@@ -1043,7 +1044,7 @@ def text2vec_transformers(
1043
1044
) ->_NamedVectorConfigCreate:
1044
1045
"""Create a named vector using the `text2vec_transformers` model.
1045
1046
1046
-
See the [documentation](https://weaviate.io/developers/weaviate/modules/retriever-vectorizer-modules/text2vec-transformers)
1047
+
See the [documentation](https://weaviate.io/developers/weaviate/model-providers/transformers/embeddings)
1047
1048
for detailed usage.
1048
1049
1049
1050
Arguments:
@@ -1090,7 +1091,7 @@ def text2vec_jinaai(
1090
1091
) ->_NamedVectorConfigCreate:
1091
1092
"""Create a named vector using the `text2vec-jinaai` model.
1092
1093
1093
-
See the [documentation](https://weaviate.io/developers/weaviate/modules/retriever-vectorizer-modules/text2vec-jinaai)
1094
+
See the [documentation](https://weaviate.io/developers/weaviate/model-providers/jinaai/embeddings)
1094
1095
for detailed usage.
1095
1096
1096
1097
Arguments:
@@ -1109,7 +1110,7 @@ def text2vec_jinaai(
1109
1110
`model`
1110
1111
The model to use. Defaults to `None`, which uses the server-defined default.
1111
1112
See the
1112
-
[documentation](https://weaviate.io/developers/weaviate/modules/retriever-vectorizer-modules/text2vec-jinaai#available-models) for more details.
1113
+
[documentation](https://weaviate.io/developers/weaviate/model-providers/jinaai/embeddings#available-models) for more details.
0 commit comments