You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've created a custom component embedding model for Oracle OCI AI hosted Embedding models (which hosts Cohere embedding models). I've attached the custom component - OCI GenAI Embedding.json.
This worked as expected in Langflow 1.1.1, but it fails in Langflow 1.1.2. with the following error in the terminal.
ERROR - chat - Error building vertices: Error serializing vertex build response: Unable to serialize unknown type: chat.py:405
<class 'oci.generative_ai_inference.generative_ai_inference_client.GenerativeAiInferenceClient'>
I've also tried the in-built "Cohere Embeddings" from Langflow, and that also fails with the same error (but referencing different class - as shown below). Both use langchain community embeddings.
ERROR - chat - Error building vertices: Error serializing vertex build response: Unable to serialize unknown type: chat.py:405
<class 'cohere.client.Client'>
Reproduction
Attach Embeddings model component to a Vector Store. Try to ingest data or execute similarity search (anything that uses the Embedding) - Flow fails, with Embedding model component throwing out an error.
Expected behavior
Flow/Build to success, and the Data ingestion and/or Similarity search (both of which involve embedding), to succeed.
Hey @ShahvaizJanjua! 👋 I'm here to help you with bugs, questions, and becoming a contributor. Let's squash those bugs together!
The issue you're encountering with Langflow 1.1.2 seems to be related to the serialization of external client objects, specifically GenerativeAiInferenceClient and cohere.client.Client. Langflow's serialization mechanism has limitations when dealing with objects from external libraries that do not have straightforward serialization methods like dict or model_dump. When such objects are encountered, the mechanism defaults to converting them to a string, which can lead to incomplete serialization and errors [1].
In Langflow 1.1.2, there have been improvements in error handling and logging related to serialization issues. These improvements include catching specific serialization errors and providing more detailed error messages, which can help in diagnosing the problem [2][3][4].
To address this issue, you might consider implementing a custom serialization method for these specific client objects or checking if there are any updates or patches available that address this serialization limitation in Langflow 1.1.2.
Bug Description
I've created a custom component embedding model for Oracle OCI AI hosted Embedding models (which hosts Cohere embedding models). I've attached the custom component - OCI GenAI Embedding.json.
This worked as expected in Langflow 1.1.1, but it fails in Langflow 1.1.2. with the following error in the terminal.
I've also tried the in-built "Cohere Embeddings" from Langflow, and that also fails with the same error (but referencing different class - as shown below). Both use langchain community embeddings.
Reproduction
Attach Embeddings model component to a Vector Store. Try to ingest data or execute similarity search (anything that uses the Embedding) - Flow fails, with Embedding model component throwing out an error.
Expected behavior
Flow/Build to success, and the Data ingestion and/or Similarity search (both of which involve embedding), to succeed.
Who can help?
No response
Operating System
MacOS (Container)
Langflow Version
1.1.2
Python Version
3.12
Screenshot
No response
Flow File
OCIVSIngestData1.1.2.json
The text was updated successfully, but these errors were encountered: