Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

点击Submit,页面显示错误,控制台显示AttributeError: 'PrelrainedlokenizerFast' object has no attribute 'build_chat_input' #10

Open
1 of 2 tasks
1105135335 opened this issue Aug 16, 2024 · 4 comments

Comments

@1105135335
Copy link

System Info / 系統信息

CUDA :11.1
transformers:4.44.0
Python:3.10.0
操作系统:Windows10 64

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

No response

Information / 问题信息

  • The official example scripts / 官方的示例脚本
  • My own modified scripts / 我自己修改的脚本和任务

Reproduction / 复现过程

  1. 在conda控制台进入项目路径并进入搭好环境的虚拟环境,然后运行python trans_web_demo.py;
  2. 项目正常运行启动并自动弹出网页;
  3. 在输入框中输入”User: 写一篇10000字的中国旅游指南“,点击Submit。出现如下午所示的错误。

1

2

Expected behavior / 期待表现

在输入框中输入示例中的”User: 写一篇10000字的中国旅游指南“,点击Submit,正常生成例如示例中的1w+内容。

@bys0318
Copy link
Member

bys0318 commented Aug 16, 2024

hi, please update to the newest trans_web_demo.py.

@yungongzi
Copy link

yungongzi commented Aug 20, 2024

  • 使用LongWriter-llama3.1-8b模型
  • 更新到最新代码,transformers==4.44.0,
  • 依然报错:
    image

@bys0318
Copy link
Member

bys0318 commented Aug 20, 2024

你好,我们提供的trans_web_demo.py示例代码适配的是LongWriter-glm4-9b模型,如果要在LongWriter-llama3.1-8b上尝试此demo需要更改代码,请参考hf readme中的推理代码进行更改。

@yungongzi
Copy link

你好,我们提供的trans_web_demo.py示例代码适配的是LongWriter-glm4-9b模型,如果要在LongWriter-llama3.1-8b上尝试此demo需要更改代码,请参考hf readme中的推理代码进行更改。
多谢,我去试一下

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants