Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

support for text generation task #5

Open
zhipeng-cai opened this issue Mar 23, 2023 · 0 comments
Open

support for text generation task #5

zhipeng-cai opened this issue Mar 23, 2023 · 0 comments

Comments

@zhipeng-cai
Copy link

i wonder how to use bert model for multitask learning, i hava two tasks: sequence classification and seq2seq text generation. Can i use a bert model as encoder, and another bert model as decoder for the text generation task? And for the sequence classifiction task, i want to use one sequence classification prediction head, they all share the same bert encoder model. Is that right?

I want to create a MultitaskModel, with an bert encoder, and an encoderdecoder model combining the bert encoder and another bert decoder, and also a sequence classification prediciton head. In the forward() method, if the training batch is from text generation task, then i will call the encoderdecoder model's forward method, or if the traing batch is from sequence classification task, i will call the forward() method from the classification head, is that implement right?

Thank you very much!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant