Code Monkey home page Code Monkey logo

wikikreator's Introduction

WikiKreator Project

  1. The program allows generation of Content for Wikipedia articles.

  2. The main method is in the class ExistingArticleGenerator in edu.sidd.StubImprover package.

  3. There is a properties file that needs editing -- dir.config in the base directory. The "categoryForTraining" property refers to the Wikipedia category from which articles would be extracted to train the classifier. The "categoryToGenerate" property refers to the Wikipedia category, the stubs/articles of which you wish to generate. Both the above categories can be same, in that case the software generates pages that already exist on Wikipedia. The LDA model requires a category with enough training data to generate reasonable features. The category name should exactly be the way it is on Wikipedia , along with the underscores (_). For example, "Science_fiction_films" and not "Science fiction films". The code requires python 2 and 3 too for some third-party software. Please change the python executables by changing "python2dir" and "python3dir". Number of articles to generate is set using "numFilesToGenerate". Default is 20. The classifier only assigns to sections based on the confidence. The min confidence can be set using "cfThreshold" parameter.

Note: The requirement for both python distributions can be avoided and I will modify the code soon.


####IMPORTANT: DO THIS BEFORE YOU PROCEED##### 4. System Requirements: This code will run on Java 1.7 Maven is required to compile. In addition, it requires GUROBI the optimization solver: http://www.gurobi.com/ on the machine it runs. It cannot be shipped in this software due to licensing regulations. Place gurobi.jar in lib directory. Maven should take care of the compilation. We also provide a modified version of HTMLUnit with a small change in lib directory. For the ILP Model, a language model is also required. Use any ARPA format file. We used 3gram Language model from here: http://www.keithv.com/software/csr/ Download the file and put it into the lib/LM directory Run: mvn install after the libs are included.


  1. Run the main class and the code should run: The various steps it does are: i. Extract all the data from the category. ii. Get the top frequent sections -- set parameter "topFrequentSections" in dir.config (Default: 10) iii. Generate Topic Models and Classifiers iv. Look into Results folder once the text files are generated -- Results/GeneratedOutput/"categoryToGenerate"/system/ v. The directory structure is such that it can be easily used for ROUGE evaluation.(system/models) [ROUGE is not shipped with this software]

Citation If you use any components of this code, please cite: Siddhartha Banerjee and Prasenjit Mitra, "WikiKreator: Improving Wikipedia Stubs Automatically", In Proceedings of the 53rd Annual Meeting of the Association for Computational Linguistics (ACL) and the 7th International Joint Conference on Natural Language Processing of the AFNLP, Beijing, China, July 2015

Please note that all the code is research code, and hence is provided here with any real gurantees.

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.