Hyperparticle / udify

A single model that parses Universal Dependencies across 75 languages. Given a sentence, jointly predicts part-of-speech tags, morphology tags, lemmas, and dependency trees.
https://arxiv.org/abs/1904.02099
MIT License
219 stars 56 forks source link

Using other transformer models #30

Open VasilisTz1 opened 2 years ago

VasilisTz1 commented 2 years ago

Hello,

I am trying to use the XLMRoberta model instead of BERT and I made the following changes to the bert_pretrained.py:

from transformers import XLMRobertaTokenizer
from transformers import XLMRobertaModel, XLMRobertaConfig

However, I get the following error:

super().__init__(vocab=bert_tokenizer.vocab, AttributeError: 'XLMRobertaTokenizer' object has no attribute 'vocab'

Any guidance would be much appreciated!

ayushbits commented 2 years ago

Hey @VasilisTz1 ,

Were you able to resolve this issue ?

VasilisTz1 commented 2 years ago

Hello @ayushbits,

No, there are a couple of changes that should be done I guess.