how to suppress warning Setting `pad_token_id` to `eos_token_id`:2 for open-end generation.

#5
by huashiyiqike - opened

every model.chat call will print this
Setting pad_token_id to eos_token_id:2 for open-end generation.

Knowledge Engineering Group (KEG) & Data Mining at Tsinghua University org

Fixed

zxdu20 changed discussion status to closed

I need the same solution ...... it is very irritating, when we generate text in batches.

how did you fix it

Add the argument pad_token_id to model.generate(..., pad_token_id=tokenizer.eos_token_id)

Sign up or log in to comment