Git Product home page Git Product logo

Comments (5)

PolKul avatar PolKul commented on August 18, 2024

parsing the same sentence with amrlib parser, for example, gives me this result with amr-unknown:

# ::snt Which architect of Marine Corps Air Station Kaneohe Bay was also tenant of New Sanno hotel?
(t / tenant-01
      :ARG0 (a / amr-unknown
            :ARG0-of (a2 / architect-01
                  :ARG1 (f / facility
                        :name (n / name
                              :op1 "Marine"
                              :op2 "Corps"
                              :op3 "Air"
                              :op4 "Station"
                              :op5 "Kaneohe"
                              :op6 "Bay"))))
      :ARG1 (h / hotel
            :name (n2 / name
                  :op1 "New"
                  :op2 "Sanno"))
      :mod (a3 / also))

from transition-amr-parser.

ramon-astudillo avatar ramon-astudillo commented on August 18, 2024

It should produce amr-unknown, we use this often for question parsing.

What did you trained it with? I just checked on a v0.4.2 deploy and it parses correctly. Also, do you tokenize?

from transition-amr-parser.

PolKul avatar PolKul commented on August 18, 2024

hi @ramon-astudillo, well, I was trying to follow your setup instructions from here for setup and training (the default action-pointer network config bash run/run_experiment.sh configs/amr2.0-action-pointer.sh ). This is the code for inference:

from transition_amr_parser.parse import AMRParser
amr_parser_checkpoint = "/DATA/AMR2.0/models/exp_cofill_o8.3_act-states_RoBERTa-large-top24/_act-pos-grh_vmask1_shiftpos1_ptr-lay6-h1_grh-lay123-h2-allprev_1in1out_cam-layall-h2-abuf/ep120-seed42/checkpoint_best.pt"
parser = AMRParser.from_checkpoint(amr_parser_checkpoint)
words = [word.strip(string.punctuation) for word in text.split()]
annotations = parser.parse_sentences([words])

from transition-amr-parser.

PolKul avatar PolKul commented on August 18, 2024

would mind sharing your trained checkpoint to see if it makes any difference?

from transition-amr-parser.

ramon-astudillo avatar ramon-astudillo commented on August 18, 2024

would mind sharing your trained checkpoint to see if it makes any difference?

I am certain it should. We are looking into sharing pre-trained models but I can not say anything at this point.

Also FYI we will update to v0.5.1 soon (post EMNLP preprint submission deadline). This new model (Structured-BART) is new SoTA for AMR2.0 and will be published at EMNLP2021, a non updated prerprint is here https://openreview.net/forum?id=qjDQCHLXCNj

From experience in parsing questions, I can say silver-data fine-tuning works well. You can parse some text corpus with questions, filter it with a couple of rules*, and the use it as additional training data. The training scheme silver+gold pre-training with gold fine-tuning seems to work best, see e.g. https://aclanthology.org/2020.findings-emnlp.288/

(*) For example ignore all parses having :rel (which indicates a detached subgraph) or with missing amr-unknown (if you are certain it should have one).

from transition-amr-parser.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.