mirror of
https://github.com/langchain-ai/langchain.git
synced 2026-10-09 19:35:20 +03:00
Updated `integrations/embeddings`: fixed titles; added links, descriptions Updated `integrations/providers`.
1.7 KiB
1.7 KiB
In [ ]:
from langchain.embeddings import ModelScopeEmbeddingsIn [ ]:
model_id = "damo/nlp_corom_sentence-embedding_english-base"In [ ]:
embeddings = ModelScopeEmbeddings(model_id=model_id)In [ ]:
text = "This is a test document."In [ ]:
query_result = embeddings.embed_query(text)In [ ]:
doc_results = embeddings.embed_documents(["foo"])