Skip to content

Commit aed5730

Browse files
authored
Add Titan Embeddings G2 (#94)
1 parent 4e8a913 commit aed5730

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/api/models/bedrock.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ def get_inference_region_prefix():
6969
"cohere.embed-multilingual-v3": "Cohere Embed Multilingual",
7070
"cohere.embed-english-v3": "Cohere Embed English",
7171
# Disable Titan embedding.
72-
# "amazon.titan-embed-text-v1": "Titan Embeddings G1 - Text",
72+
"amazon.titan-embed-text-v2:0": "Titan Embeddings G2 - Text",
7373
# "amazon.titan-embed-image-v1": "Titan Multimodal Embeddings G1"
7474
}
7575

@@ -860,6 +860,8 @@ def get_embeddings_model(model_id: str) -> BedrockEmbeddingsModel:
860860
match model_name:
861861
case "Cohere Embed Multilingual" | "Cohere Embed English":
862862
return CohereEmbeddingsModel()
863+
case "Titan Embeddings G2 - Text":
864+
return TitanEmbeddingsModel()
863865
case _:
864866
logger.error("Unsupported model id " + model_id)
865867
raise HTTPException(

0 commit comments

Comments
 (0)