Expected EmbeddingFunction.__call__ to have the following signature: odict_keys(['self', 'input']), got odict_keys(['self', 'args', 'kwargs'])
I used the proper wrapper to download the model, but now I am getting the embedding_function error in Chromadb. I did -
loaded the jina model -
from langchain.embeddings import HuggingFaceEmbeddings
model_name = "jinaai/jina-embeddings-v2-base-en"
model_kwargs = {'device': 'cuda'}
encode_kwargs = {'normalize_embeddings': True}
model = HuggingFaceEmbeddings(
model_name=model_name,
model_kwargs=model_kwargs,
encode_kwargs=encode_kwargs
)
chroma settings -
from chromadb.config import Settings
CHROMA_SETTINGS = Settings(
anonymized_telemetry=False,
is_persistent=True,
)
Creating the persist directory -
persist_directory = 'db'
embedding = model
vectordb = Chroma.from_documents(documents=texts,
embedding=embedding,
persist_directory=persist_directory,
client_settings=CHROMA_SETTINGS)
error in above step -
Expected EmbeddingFunction.call to have the following signature: odict_keys(['self', 'input']), got odict_keys(['self', 'args', 'kwargs'])
closing this as it's already discussed in https://huggingface.co/jinaai/jina-embeddings-v2-base-en/discussions/22