T5 Finetuning Tips

not sure about why it’s generating extra id,

Yes, you could try different values for generate arguments to control the length. Specifically you could use the length_penalty argument. Set to values < 1.0 in order to encourage the model to generate shorter sequences, to a value > 1.0 in order to encourage the model to produce longer sequences.

Be default generate will use arguments from config or config.task_specific_params but you could also directly pass these args to generate to override them

1 Like