text-generation-inference icon indicating copy to clipboard operation
text-generation-inference copied to clipboard

The transformation between repetition_penalty and presence_penalty seems to be incorrect

Open boxiaowave opened this issue 10 months ago • 0 comments

https://github.com/huggingface/text-generation-inference/blob/ed72e9212620d4de10fbe476f0b7af2ab94e4cd7/router/src/server.rs#L1006

When repetition_penalty=1.0 or presence_penalty=0.0, there is no repeat penalty in the generation. However the transformation in the code set the repetition_penalty to 2 when presence_penalty=0 which violates it.

boxiaowave avatar Apr 23 '24 11:04 boxiaowave