Inference input token number set as the max length always?

these are the sources which i learned from. might help you.