Hey gang getting errors with PEGASUS PARAPHRASE

I’m getting these random output errors maybe 1/50 times I process a sentence.

generated text: Is a 12 person tent 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110 888-739-5110

This is the number for some random pizza place. Why does it keep appearing in my output. Is there anyway I can make sure this doesn’t happen again. I can’t find the pattern to my input data causing this.

Please let me know if you have a solution. I have found this error on both the hugging face interference and also using torch on Gcollab. It’s driving me nuts.

Hey, I’m also getting the same issues. Were you by any chance able to figure out the bug?

I got the same error (also a repetition of the number 888-739-5110) for the following input text: HuggingFace Pegasus XSUM error

After investigating the issue, it seems that the probability vector contained an infinity value. To overcome the issue, I used the following parameters for the model:

parameters = {
            "temperature": 0.1,
            "repetition_penalty": 100.0,
            "do_sample": False,
            "top_k": 100,
            "top_p": 0.8,
            "no_repeat_ngram_size": 3,
}

This will overcome the issue with the repetitive numbers at least (and solved my problem).