binary-husky / binary-husky/gpt_academic
[Bug]: No module named 'trafilatura'
- Dominant language
- Python
- Stars
- 71.3k
- Forks
- 8.3k
- PR merge metrics
- No merged PRs in 30d
Description
### Installation Method | 安装方法与平台
Pip Install (I used latest requirements.txt)
### Version | 版本
Latest | 最新版
### OS | 操作系统
Windows
### Describe the bug | 简述
qwen-max是正常的,代理打开也是正常的。切换成gpt-4报如下错误。
### Screen Shot | 有帮助的截图
`Traceback (most recent call last):
File "F:\Conda\envs\gpt_academic\lib\site-packages\gradio\routes.py", line 422, in run_predict
output = await app.get_blocks().process_api(
File "F:\Conda\envs\gpt_academic\lib\site-packages\gradio\blocks.py", line 1323, in process_api
result = await self.call_function(
File "F:\Conda\envs\gpt_academic\lib\site-packages\gradio\blocks.py", line 1067, in call_function
prediction = await utils.async_iteration(iterator)
File "F:\Conda\envs\gpt_academic\lib\site-packages\gradio\utils.py", line 336, in async_iteration
return await iterator.__anext__()
File "F:\Conda\envs\gpt_academic\lib\site-packages\gradio\utils.py", line 329, in __anext__
return await anyio.to_thread.run_sync(
File "F:\Conda\envs\gpt_academic\lib\site-packages\anyio\to_thread.py", line 65, in run_sync
return await get_async_backend().run_sync_in_worker_thread(
File "F:\Conda\envs\gpt_academic\lib\site-packages\anyio\_backends\_asyncio.py", line 2641, in run_sync_in_worker_thread
return await future
File "F:\Conda\envs\gpt_academic\lib\site-packages\anyio\_backends\_asyncio.py", line 1033, in run
result = context.run(func, *args)
File "F:\Conda\envs\gpt_academic\lib\site-packages\gradio\utils.py", line 312, in run_sync_iterator_async
return next(iterator)
File "F:\AI_models\gpt_academic\toolbox.py", line 144, in decorated
yield from f(txt_passon, llm_kwargs, plugin_kwargs, chatbot_with_cookie, history, system_prompt, *args)
File "F:\AI_models\gpt_academic\request_llms\bridge_all.py", line 1571, in predict
yield from load_web_content(inputs, chatbot, history)
File "F:\AI_models\gpt_academic\shared_utils\doc_loader_dynamic.py", line 23, in load_web_content
from crazy_functions.doc_fns.read_fns.web_reader import WebTextExtractor, WebExtractorConfig
File "F:\AI_models\gpt_academic\crazy_functions\doc_fns\read_fns\web_reader.py", line 7, in
import trafilatura
ModuleNotFoundError: No module named 'trafilatura'`
### Terminal Traceback & Material to Help Reproduce Bugs | 终端traceback(如有) + 帮助我们复现的测试材料样本(如有)
_No response_
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with requirements.txt and the import path shown in shared_utils/doc_loader_dynamic.py and crazy_functions/doc_fns/read_fns/web_reader.py. Reproduce the GPT-4 web-content flow on Windows and verify that the trafilatura import succeeds without ModuleNotFoundError.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 58/100