Closed abdul756 closed 6 months ago
I edited your issue to remove your API token: https://huggingface.co/docs/hub/en/security-tokens#how-to-use-user-access-tokens I'd suggest you revoke your token, as it's been public for several hours.
For the issue, could you try to update Pathway and make sure the LLM xpack is there?
pip install -U "pathway[xpack-llm-docs]"
Agreed to @olruas's comment, if you update the Pathway, this should be resolved.
@olruas thanks for solving the issue and reminding me of revolking API token
Import error
ImportError Traceback (most recent call last) Cell In[14], line 22 20 os.environ["HUGGINGFACEHUB_API_TOKEN"] = "***" 21 import asyncio ---> 22 from pathway.xpacks.llm.question_answering import ( 23 answer_with_geometric_rag_strategy_from_index, 24 )
File ~/project_pathway/personal_assistant/venv/lib/python3.10/site-packages/pathway/xpacks/llm/question_answering.py:7 5 import pathway as pw 6 from pathway.internals import ColumnReference, Table ----> 7 from pathway.stdlib.indexing import DataIndex 8 from pathway.xpacks.llm import Doc, llms, prompts 9 from pathway.xpacks.llm.llms import prompt_chat_single_qa
ImportError: cannot import name 'DataIndex' from 'pathway.stdlib.indexing' (/home/abdul/project_pathway/personal_assistant/venv/lib/python3.10/site-packages/pathway/stdlib/indexing/init.py)
Pathway version used = 0.11.0