Skip to content

junbread/text-summary

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

63 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

text-summary

Generates text summaries from given inputs through several methods. supports Korean only, for now.

Currently implemented methods:

  • Pointer-Generator Network (most codes are from this project with some modification.)
  • TextRank (by textrankr library)
  • Transformer

This is a sub-project of skku-coop-project backed by SK Planet.

Requirements

Python packages

hanja
textrankr
django
tensorflow >= 2.0.0
koalanlp

Other requirements

NOTE: Now all requirements are included. No need to download.

Setup

NOTE

  • Automated bash script is included. Now you just need to run run_demo.sh only.
  • I recommend to use python virtual environment venv to isolate the development environment.

Before running demo page server, you should export your working directory as PYTHONPATH. Try with this:

export PYTHONPATH=$PYTHONPATH:path/to/project

Also this project uses Stanford CoreNLP library to regularize input sentences. We assume you already installed Java runtime & downloaded CoreNLP library.

Like PYTHONPATH, to run the server you need to specify CoreNLP jar file into CLASSPATH. Try with this:

export CLASSPATH=$CLASSPATH:path/to/corenlp/stanford-corenlp-(version number).jar

Download dataset (& pretrained model)

Since datasets are too large to upload on Github, the files are uploaded on Google Drive. Download with links below:

Extract data

Dataset location

original: project-root/data/
preprocessed: project-root/src/sum/pgn/data/

Model location

project-root/src/sum/pgn/model/

Note that you have to extract content only. Do not create subdirectory under the location.

How to run the demo

The demo page is made with Django framework. To run the demo, try this:

python src/demo/manage.py runserver

About

✏️ generates abstractive text summary

Topics

Resources

Stars

Watchers

Forks

Languages