Help releasing own research on NLP
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
app/controllers
libs
static
views
.gitignore
Procfile
README.md
README_JP.md
index.py
requirements.txt
runtime.txt
screen_shot.png

README.md

NLP Web Demonstration Template

(日本語での説明はこちらから)

This template helps releasing own research for NLP researcher.

Knowledge requirements for customizing the template:

  • basic Python
  • basic HTML
  • basic javascript (jquery)
  • basic web application

demonstration image

Usage

Run the example demonstration

git clone https://github.com/kanjirz50/web-nlp-interface.git
cd web-nlp-interface
gunicorn -b 127.0.0.1:8080 -w 1 index:app

You can see the example demonstration on the browser, 127.0.0.1:8080.

** Notice: Firewall port:8080 have to be opened for this demonstration. **

Run own application

Put your application

If your application is developed by Python code, put your codes to under the libs directory.

If your application is not developed by Python, there are two ways. One is using submodule, the other is build a Python interface.

Modify a view page and js file for showing your application result

A data format of example demonstration is simple. Input is text, output is list[[Word, lowercased word], ...]. You have to modify rendering codes.

  • static/js/analyze.js

    • unnamed function: submit text data using GET request
    • writeTable function: write result to table in a html file
  • views/contents/demo.html

    • Result is shown as a table. Please modify a number of column and column name.

Deployment

We can use some servers, Bottle-Deployment.

heroku

heroku is a cloud application platform that can build and run application.

If you use default templates, the template runs on the heroku only push the repository.

Example:http://web-nlp-interface-template.herokuapp.com/

These are the summary of a heroku settings.

  • Procfile
    • is a declares what commands are run by an application
  • requirements.txt
    • Python module (pip) dependecy
  • runtime.txt
    • set Python version

Template structure

Coming soon...

Examples

Acknowledgment

This demonstration templates uses the following open source software:

License

MIT License, see LICENSE for details.