hwchase17 / chat-your-data

MIT License
903 stars 264 forks source link

Deprecated libraries preventing the app to run from pickle file #31

Open emtabiraobarias opened 4 weeks ago

emtabiraobarias commented 4 weeks ago

The pickle file cannot be deserialised, and re-running the ingest_data.py is producing a blank pickle file.

Furthermore, the following issues are noted:

  1. app.py: AttributeError: 'Button' object has no attribute 'style'.
  2. query.py: Traceback (most recent call last): File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/gradio/queueing.py", line 522, in process_events response = await route_utils.call_process_api( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/gradio/route_utils.py", line 260, in call_process_api output = await app.get_blocks().process_api( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/gradio/blocks.py", line 1741, in process_api result = await self.call_function( ^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/gradio/blocks.py", line 1296, in call_function prediction = await anyio.to_thread.run_sync( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/anyio/to_thread.py", line 56, in run_sync return await get_async_backend().run_sync_in_worker_thread( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/anyio/_backends/_asyncio.py", line 2144, in run_sync_in_worker_thread return await future ^^^^^^^^^^^^ File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/anyio/_backends/_asyncio.py", line 851, in run result = context.run(func, *args) ^^^^^^^^^^^^^^^^^^^^^^^^ File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/gradio/utils.py", line 751, in wrapper response = f(*args, **kwargs) ^^^^^^^^^^^^^^^^^^ File "/Users/emeraldbarias/Source/chat-your-data/app.py", line 16, in set_openai_api_key chain = get_basic_qa_chain() ^^^^^^^^^^^^^^^^^^^^ File "/Users/emeraldbarias/Source/chat-your-data/query_data.py", line 41, in get_basic_qa_chain retriever = load_retriever() ^^^^^^^^^^^^^^^^ File "/Users/emeraldbarias/Source/chat-your-data/query_data.py", line 34, in load_retriever vectorstore = pickle.load(f) ^^^^^^^^^^^^^^ EOFError: Ran out of input
emtabiraobarias commented 4 weeks ago

The accompanying tutorial helped me a lot and I'd like to share the fixes for the issue I reported, but I am not able to publish a branch - don't have permissions to push to "hwchase17/chat-your-data" and create a pull request. @bllchmbrs @hwchase17