bjascob / amrlib

A python library that makes AMR parsing, generation and visualization simple.
MIT License
216 stars 33 forks source link

Question for transformers package #43

Closed waltbai closed 2 years ago

waltbai commented 2 years ago

The original spring requires transformers<3.0 due to the change of positional embeddings. However, amrlib requires transformers>=3.0, should I downgrade the transformers if I want to use spring model?

Besides, we found that spring will produce frames out of propbank frame list. For example, we parse "It was aged in 30 percent new oak barrels , some coopered from American oak and some from French oak ." and the model produces "coch-00" and "coch-01" node.

da0eb47b55785b3c42de0174d50ed7c

I wonder if this problem is caused by the version of transformers.

bjascob commented 2 years ago

The SPRING model in amrlib is conceptually similar but has significantly modified code from the original. It is intended to be compatible with the latest version of the transformers library. see Requirements.txt ...

transformers>=3.0 # Note that original models trained with v3.4.0

waltbai commented 2 years ago

The SPRING model in amrlib is conceptually similar but has significantly modified code from the original. It is intended to be compatible with the latest version of the transformers library. see Requirements.txt ...

transformers>=3.0 # Note that original models trained with v3.4.0

Thank you for your reply. Is that possible for SPRING to generate frames that are out of propbank frame list? Like "coch-00" in the above figure.

bjascob commented 2 years ago

I would expect it to generate output based on the AMR training data. The propbank frames files are not used in training.