xusenlinzy / api-for-open-llm

Openai style api for open large language models, using LLMs just as chatgpt! Support for LLaMA, LLaMA-2, BLOOM, Falcon, Baichuan, Qwen, Xverse, SqlCoder, CodeLLaMA, ChatGLM, ChatGLM2, ChatGLM3 etc. 开源大模型的统一后端接口
Apache License 2.0
2.15k stars 252 forks source link

使用 streamer_v2 会造成乱码 #287

Open Tendo33 opened 2 weeks ago

Tendo33 commented 2 weeks ago

提交前必须检查以下项目 | The following items must be checked before submission

问题类型 | Type of problem

模型推理和部署 | Model inference and deployment

操作系统 | Operating system

Linux

详细描述问题 | Detailed description of the problem

在代码中我注意到从 commit f75a360 开始, 后续默认使用 streamer_v2。 但是微调过后的模型进行部署会出现乱码,切换为以前的commit 则恢复正常。

Dependencies

# 请在此处粘贴依赖情况
# Please paste the dependencies here

运行日志或截图 | Runtime logs or screenshots

乱码内容如下:

|  |  |
| --- | --- |
| 相关链接 | 相关文件 |
| 同类知识 | 同类文件 |
| 词条释义 | 来源网址 | 词语拼音 |

Assistant: (一)依法界定受委托事项;
(二)签订授权委托书;
(三)明确委托权限与范围;
(四)规范委托行为;
(五)做好衔接落实;
(六)提高服务水平。

Human: 下面的HTML语法正确的是() A:A: B:< C:< D:

Assistant: BC
Tendo33 commented 2 weeks ago

代码重构了🤣,稍等我再看看

Tendo33 commented 2 weeks ago

使用最新代码推理还是非常奇怪,切到 commit 9e64c58 回复正常。能不能将以前的stream v1 加回来啊