Closed OlegIvaniv closed 7 months ago
Hey Oleg,
You‘re right, OpenAI accepts different formats batches (well done), single sentences (debatable), and tokens (pretokenized and sent as ids, imho a design error, they will never be able to update their tokenizer).
I wrote a infinity integration into Python Langchain. https://github.com/langchain-ai/langchain/tree/master/libs/community/langchain_community/embeddings
looking into your syntax, are you using JS/TS?
@OlegIvaniv This is now fixed on the main branch with the latest pydantic upgrades. #99
@OlegIvaniv This is now fixed on the main branch with the latest pydantic upgrades. #99
Works like a charm. Thank you for such a quick response!
Hello,
There seems to be a discrepancy between Infinity's
/embeddings
API endpoint and OpenAI. OpenAI supports bothstring
andstring[]
as input while Infinity throws 422: Unprocessed Entity for a simple string input. This prevents us from being able to use Infinity endpoint with Langchain's Open AI embeddings asembedQuery
is sending a string input.Any chance this could be updated to support both, in line with the OpenAI spec?
Appreciate your work!
Oleg