vigil-llm icon indicating copy to clipboard operation
vigil-llm copied to clipboard

Support cohere embeddings

Open deadbits opened this issue 2 years ago • 1 comments

Add support for Cohere embeddings

  • Create datasets for Huggingface
  • Update vectordb scanner to use Cohere as custom embedding function
  • Update config parser to load Cohere model choice and API key
import cohere
co = cohere.Client(API_KEY)
response = co.embed(
  model='embed-english-v2.0',
  texts=[""])
print('Embeddings: {}'.format(response.embeddings))

deadbits avatar Sep 04 '23 20:09 deadbits

hi @deadbits I'm the maintainer of LiteLLM. We've added support for Cohere embedding models: https://docs.litellm.ai/docs/embedding/supported_embedding#cohere-embedding-models

You can call it using the OpenAI embedding Input/Output format

ishaan-jaff avatar Sep 29 '23 17:09 ishaan-jaff