netease-youdao / QAnything

Question and Answer based on Anything.
https://qanything.ai
GNU Affero General Public License v3.0
11.36k stars 1.1k forks source link

[解析出错] 上传文件 #217

Open LixiangHello opened 5 months ago

LixiangHello commented 5 months ago

是否已有关于该错误的issue或讨论? | Is there an existing issue / discussion for this?

该问题是否在FAQ中有解答? | Is there an existing answer for this in FAQ?

当前行为 | Current Behavior

INFO:debug_logger:success init localfile rag应用.pdf INFO:debug_logger:insert_files_to_faiss: KBee28c5c5c40e49238beec251217835f5 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 9/9 [00:00<00:00, 29.04it/s] docs number: 1 INFO:debug_logger:before 2nd split doc lens: 1 INFO:debug_logger:after 2nd split doc lens: 0 INFO:debug_logger:langchain analysis docs is empty! INFO:debug_logger:split time: 0.32176852226257324 0 ERROR:asyncio:Task exception was never retrieved future: <Task finished name='Task-10' coro=<LocalDocQA.insert_files_to_faiss() done, defined at /root/autodl-tmp/QAnything/qanything_kernel/core/local_doc_qa.py:74> exception=IndexError('list index out of range')> Traceback (most recent call last): File "/root/autodl-tmp/QAnything/qanything_kernel/core/local_doc_qa.py", line 94, in insert_files_to_faiss add_ids = await self.faiss_client.add_document(local_file.docs) File "/root/autodl-tmp/QAnything/qanything_kernel/connector/database/faiss/faiss_client.py", line 87, in add_document kb_id = docs[0].metadata['kb_id'] IndexError: list index out of range

期望行为 | Expected Behavior

No response

运行环境 | Environment

- OS:
- NVIDIA Driver:
- CUDA:
- docker:
- docker-compose:
- NVIDIA GPU:
- NVIDIA GPU Memory:

QAnything日志 | QAnything logs

No response

复现方法 | Steps To Reproduce

No response

备注 | Anything else?

No response

lotus0903 commented 1 month ago

同问