microsoft / LLMLingua

To speed up LLMs' inference and enhance LLM's perceive of key information, compress the prompt and KV-Cache, which achieves up to 20x compression with minimal performance loss.
https://llmlingua.com/
MIT License
4.18k stars 222 forks source link

[Bug]: 返回中文会出现乱码 #152

Open CEfanmin opened 1 month ago

CEfanmin commented 1 month ago

Describe the bug

�外公司将命名为3,其针对多个行业的、、和记者,其还广泛使用的网站来。组织除了攻击对、国家攻击,其套功能的恶意代码,并结合商业工具。1年月组织进入期,并年月了规模轮,大量受害者因打开感染。一直至今组织中国内的活动依然。us,3,Calt,APT-0us �似来源 �南响国家、、、菲律宾、、事、海域企业 �11-1Z时间00Z术 �、攻击术能力 中 �用、中

如上所示,在处理中文提示的时候,返回的压缩提示会出现乱码。

Steps to reproduce

No response

Expected Behavior

No response

Logs

No response

Additional Information

No response

iofu728 commented 1 month ago

Hi @CEfanmin, thanks for your feedback. Since LLMLingua uses token-level prompt compression, it can indeed cause garbled text in some languages. You can try using LLMLingua-2.

CEfanmin commented 1 month ago

Hi @CEfanmin, thanks for your feedback. Since LLMLingua uses token-level prompt compression, it can indeed cause garbled text in some languages. You can try using LLMLingua-2.

Thanks!