Giter VIP home page Giter VIP logo

dynsp's Introduction

DynSP (Dynamic Neural Semantic Parser)

This project contains the source code of the Dynamic Neural Semantic Parser (DynSP), based on DyNet.

Detail of DynSP can be found in the following ACL-2017 paper:

Mohit Iyyer, Wen-tau Yih, Ming-Wei Chang. Search-based Neural Structured Learning for Sequential Question Answering. ACL-2017.

@InProceedings{iyyer-yih-chang:2017:Long,
  author    = {Iyyer, Mohit  and  Yih, Wen-tau  and  Chang, Ming-Wei},
  title     = {Search-based Neural Structured Learning for Sequential Question Answering},
  booktitle = {Proceedings of the 55th Annual Meeting of the Association for Computational Linguistics (Volume 1: Long Papers)},
  month     = {July},
  year      = {2017},
  address   = {Vancouver, Canada},
  publisher = {Association for Computational Linguistics},
  pages     = {1821--1831},
}

The output files and the models for producing the reported results are also included. Below are the scripts that produces the results reported in Table 2 of the paper (DynSP and DynSP*).

$ ./check.sh moduleKwNoMap-b15-ind
moduleKwNoMap-b15-ind
Best Accuracy: 0.425963 (Reward: 0.479099) at epoch 28
Best Accuracy: 0.369095 (Reward: 0.423323) at epoch 10
Best Accuracy: 0.348668 (Reward: 0.405460) at epoch 24
Best Accuracy: 0.377477 (Reward: 0.439594) at epoch 29
Best Accuracy: 0.349951 (Reward: 0.413719) at epoch 20
Best Accuracy: 0.351802 (Reward: 0.409400) at epoch 19
0.359399 20
$ ./evalModel-indep.sh moduleKwNoMap-b15-ind 20
Sequence Accuracy = 10.15% (104/1025)
Answer Accuracy =   41.97% (1264/3012)
Break-down:
Position 0 Accuracy = 70.93% (727/1025)
Position 1 Accuracy = 35.84% (367/1024)
Position 2 Accuracy = 20.06% (137/683)
Position 3 Accuracy = 12.23% (28/229)
Position 4 Accuracy = 13.16% (5/38)
Position 5 Accuracy = 0.00% (0/9)
Position 6 Accuracy = 0.00% (0/4)
$ ./check.sh moduleKwNoMap-b15
moduleKwNoMap-b15
Best Accuracy: 0.450863 (Reward: 0.516281) at epoch 17
Best Accuracy: 0.379691 (Reward: 0.439837) at epoch 12
Best Accuracy: 0.366021 (Reward: 0.422335) at epoch 16
Best Accuracy: 0.391892 (Reward: 0.456894) at epoch 26
Best Accuracy: 0.370968 (Reward: 0.442918) at epoch 20
Best Accuracy: 0.368468 (Reward: 0.431721) at epoch 18
0.375408 18
$ ./evalModel.sh moduleKwNoMap-b15 18
Sequence Accuracy = 12.78% (131/1025)
Answer Accuracy =   44.65% (1345/3012)
Break-down:
Position 0 Accuracy = 70.44% (722/1025)
Position 1 Accuracy = 41.11% (421/1024)
Position 2 Accuracy = 23.57% (161/683)
Position 3 Accuracy = 13.97% (32/229)
Position 4 Accuracy = 18.42% (7/38)
Position 5 Accuracy = 11.11% (1/9)
Position 6 Accuracy = 25.00% (1/4)

A tokenzier and some data files are not included in the initial release due to licencing issues. They can be found at a fork. The Sequential Question Answering (SQA) dataset, published and used in the same paper, can be downloaded separately.

Contributing

This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.microsoft.com.

When you submit a pull request, a CLA-bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.

This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.

dynsp's People

Contributors

microsoft-github-policy-service[bot] avatar posenhuang avatar scottyih avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

dynsp's Issues

Required version of dyNET

Hi, the authors of SQA,

Many thanks for your release of code DynSP ! I'm very interested in the dataset and now devoted to reproducing the result of paper. But I have encountered some problems in the required version of dyNET, which is important for producing the result.

When I use the latest version 2.1, it is not compatible with the saved model moduleKwNoMap-b15-0-18-dynetmodel.bin.

Message:
File "/home/DynSP/sqamodel.py", line 141, in load
res.model.populate(header + "-dynetmodel.bin")
File "_dynet.pyx", line 1461, in _dynet.ParameterCollection.populate
File "_dynet.pyx", line 1516, in _dynet.ParameterCollection.populate_from_textfile
RuntimeError: Bad parameter specification in model: 22 serialization::archive 10 1 0

I have also used the latest version to retrain the model, its performance will decrease into 0.370518 (decrease ~8%) in the exact same full setting.

So I'm wondering the version of dyNET that you use in the experiment, and I'd appreciate it if you could reply, thanks a lot!

Attached log file: sqamodel-0.out.log

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.