Hi there, I’m wondering if there is an elegant way to use huggingface’s generate() function given a customized model.
Currently, I’m using the MBartForConditionalGeneration class and I want to change how the inputs are processed inside the forward function e.g. adding stuffs such as variational inference from a prior distribution. I intend to subclass the MBartForConditionalGeneration with additional properties and methods to accomplish this. Is this the right way or is there a better approach out there ?
Thanks in advance !