THUDM / ChatGLM3

ChatGLM3 series: Open Bilingual Chat LLMs | 开源双语对话语言模型
Apache License 2.0
13.44k stars 1.56k forks source link

macos上运行综合demo报huggingface-hub的错 #1037

Closed Crispinli closed 7 months ago

Crispinli commented 7 months ago

System Info / 系統信息

Who can help? / 谁可以帮助到您?

Information / 问题信息

Reproduction / 复现过程

执行综合demo就会报错

Expected behavior / 期待表现

Traceback (most recent call last): File "/miniconda3/envs/chatglm/lib/python3.11/site-packages/streamlit/runtime/scriptrunner/script_runner.py", line 542, in _run_script exec(code, module.dict) File "/Downloads/projects/ChatGLM3/composite_demo/main.py", line 10, in import demo_chat, demo_ci, demo_tool File "/Downloads/projects/ChatGLM3/composite_demo/demo_chat.py", line 4, in from client import get_client File "/Downloads/projects/ChatGLM3/composite_demo/client.py", line 9, in from huggingface_hub.inference._text_generation import TextGenerationStreamResponse, Token ModuleNotFoundError: No module named 'huggingface_hub.inference._text_generation'

zhxknb1 commented 7 months ago
image

已经安装了依赖,但这行代码报错

Crispinli commented 7 months ago

image 已经安装了依赖,但这行代码报错

我已经解决了该问题,需要安装 huggingface-hub==0.20.3

zhxknb1 commented 7 months ago

@Crispinli 👍

BrunoGao commented 7 months ago

cool