microsoft / MetaXL

Meta Representation Transformation for Low-resource Cross-lingual Learning
MIT License
40 stars 7 forks source link

Sentiment Classification - Clarification #3

Closed ashissamal closed 3 years ago

ashissamal commented 3 years ago

Thank you team for sharing the wonderful approach and repo. While experimenting the existing implementation for sentiment analysis meta learning for en and te languages, I came across the SequenceTagger object which inherits XLMRobertaForTokenClassification class. As per my understanding, it should be XLMRobertaForSequenceClassification for text classifications like Sentiment, Intent. Where as XLMRobertaForTokenClassification, would be apt for NER use cases.

Please correct me if I am misunderstood.

xiamengzhou commented 3 years ago

Hi, sorry for the confusion. Yeah you are right, we should have used XLMRobertaForSequenceClassification for sentiment analysis. But at the time, we simply build the sequence classification module on top of the XLMRobertaForTokenClassification module by adding a flag and an additional classifier. It's essentially the same as XLMRobertaForSequenceClassification. Please let me know if you have more questions!

ashissamal commented 3 years ago

Thank you for the clarification.