Code Monkey home page Code Monkey logo

question-generation's Introduction

Question Generation from Declarative Sentences

Update: If you have a feature request please open an issue or feel free to submit a pull request.

Introduction

Given a statement of text such as,

Handheld devices find ways to bolster U.S. homeland defense and response.

The questions generated will be:

What do handheld devices find?

The original software is a product of PhD thesis of Michael Heilman. The original JAVA code and other instructions/resources/dependencies can be found here.

For all Pythonistas ๐Ÿ˜Ž out there this repository provides a Python wrapper to simplify the execution of the code above. The hardest part of the whole project is setup. Yes you heard it right!

Setup

To run the original code you need to have a JAVA Runtime Environment installed. JAVA downloads can be found on the Oracle website here. Version 1.6.0_07 of JAVA was used in developing the original system. The code is packaged for use on UNIX systems or for use in the Eclipse IDE.

Dependencies

The following are the dependencies of the original code.

-Apache Commons Lang (http://commons.apache.org/lang/)

-Apahce Commons Logging (http://commons.apache.org/logging/)

-JUnit (http://www.junit.org/)

-JWNL (http://sourceforge.net/projects/jwordnet/)

-Stanford NLP tools (http://www-nlp.stanford.edu/software/)

-WordNet (http://wordnet.princeton.edu/)

-The sst-light-0.4 release of the SuperSenseTagger, from which we used the SemCor data for training the supersense tagger (http://sourceforge.net/projects/supersensetag/)

-The Semcor corpus, used for training the supersense tagger (http://www.cse.unt.edu/~rada/downloads.html#semcor)

-The WEKA toolkit, version 3.6.0 (http://www.cs.waikato.ac.nz/ml/weka/)

The good news is that you don't need to download each one of those individually ๐Ÿ˜€. Everything is neatly packed in the QuestionGeneration.zip bundled with the code.

Steps

  1. Clone this repository,

    git clone https://github.com/sumehta/question-generation.git

  2. Unzip the QuestionGeneration.zip file

    unzip QuestionGeneration.zip

  3. [Optional] Start two servers to speed up the script, Stanford Parser server and the SST servers in two separate terminals.

    cd QuestionGeneration

    bash runStanfordParserServer.sh

    bash runSSTServer.sh

  4. Finally, to get a list of questions for a statement, from the parent directory execute this command

    python question.py -s 'Handheld devices find ways to bolster U.S. homeland defense and response'

For other options exposed by the script type,

python question.py -help

Note: For developers, I have also included a QuestionGenerator class, that exposes other methods for processing large collections.

Cite this repository

If you use this repository in a technical report or a research paper, please cite this repository.

  author = {Sneha Mehta},
  title = {Question Generation - Python Wrapper},
  year = {2017},
  publisher = {GitHub},
  journal = {GitHub repository},
  howpublished = {\url{https://github.com/sumehta/question-generation}},
  commit = {master}
}

question-generation's People

Contributors

sumehta avatar leticiawanderley avatar

Stargazers

Prince Osei Aboagye avatar

Watchers

James Cloos avatar

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.