Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multithreading issue causes chat functionality to stop working #183

Open
tyaga001 opened this issue Apr 23, 2024 · 0 comments
Open

Multithreading issue causes chat functionality to stop working #183

tyaga001 opened this issue Apr 23, 2024 · 0 comments

Comments

@tyaga001
Copy link
Contributor

tyaga001 commented Apr 23, 2024

Description

Attempting to build a RAG on SQL data results in the first collection not being created due to an error in Qdrant local. After making a change to the model selection, the issue seemed resolved, but the chat functionality began to fail intermittently due to a multithreading issue.

Error Message

Received the following error message when the first issue occurred:
ERROR vector_db_proxy: [utils] Error: status: InvalidArgument, message: "Validation error in body: [vectors_config.config.map[].size: value 0 invalid, must be from 1.0 to 65536.0]", details: [], metadata: MetadataMap { headers: {"content-type": "application/grpc", "date": "Fri, 19 Apr 2024 GMT", "content-length": "0"} }

Steps to Reproduce

  1. Create a collection in Qdrant local.
  2. Observe the failure to create the first collection.
  3. Change the model selection to Fast Embed instead of OpenAI.
  4. Note that the collection is now created but chat functionality is impacted.

Troubleshooting Steps Taken

  • Added more logs to debug the issue.
  • Checked the logs of the agent_backend service.
  • Attempted to use the service multiple times; issue is intermittent.

Logs

image

Additional Information

  • The issue seems to involve multithreading where values are being overwritten by another thread.
  • Problem is intermittent, making it difficult to diagnose precisely.

Temporary Workaround to build a RAG on SQL Data

If you need you can Implement a temporary local fix for the RAG creation issue involving a multithreading problem and a collection not being created in Qdrant:

To resolve the issue I was facing, I had to remove the MongoDB container and volume and build everything from scratch. I feel there must be a bug in the DB CRUD code which might not be updating the foreign key fields properly. Because of which the data might have got corrupted.

This is not a permanent solution. Further investigation is needed to find the root cause and develop a long-term fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant