Open younes-io opened 4 months ago
Hi @younes-io, thank you for your support and the detailed issue information.
Although prompts compressed by LLMLingua might have garbled text and be hard for humans to understand, I acknowledge that "à comp duvier 20." indeed lost crucial information.
However, I suspect this might be due to the weaker semantic capability of GPT-2. You might consider using LLaMA or another SLM as a compressor, like compressor = LLMLinguaCompressor(model_name="NousResearch/Llama-2-7b-hf", device_map="cpu")
.
Hi @younes-io, thank you for your support and the detailed issue information.
Although prompts compressed by LLMLingua might have garbled text and be hard for humans to understand, I acknowledge that "à comp duvier 20." indeed lost crucial information.
However, I suspect this might be due to the weaker semantic capability of GPT-2. You might consider using LLaMA or another SLM as a compressor, like
compressor = LLMLinguaCompressor(model_name="NousResearch/Llama-2-7b-hf", device_map="cpu")
.
@iofu728 : Thanks for the feedback. I tried this "NousResearch/Llama-2-7b-hf"
but it's "heavy" for my testing purposes.. I'll have to allocate more resources.. anything else I could use (more lightweight) ?
Hi @younes-io, maybe you can try "microsoft/phi-2" model.
Describe the bug
I used the code in the README and also in the notebook. Check the code below.
Steps to reproduce
I get this for example:
Expected Behavior
My original retriever
Neo4j
does retrieve the data in utf-8 (especially that I use the French language), but after compression, it's a mess, unfortunately...For example, I get this after compression:
à comp duvier 20.
(meaningless) which is originallyà compter du 1 janvier 2024
Logs
No response
Additional Information
LLMLingua Version: 0.1.6 Operating System: WSL2 (in DOcker) Python Version: