cotitan / textsum-transformer

Transformer for text summarization implemented in pytorch
11 stars 0 forks source link

Transformer for text summarization, implemented in pytorch

Requirments, * means not necessary

Data

Training and evaluation data for Gigaword is available https://drive.google.com/open?id=0B6N7tANPyVeBNmlSX19Ld2xDU1E

Training and evaluation data for CNN/DM is available https://s3.amazonaws.com/opennmt-models/Summary/cnndm.tar.gz

Noticement

  1. we use another thread to preprocess a batch of data, which would not terminate after the main process terminate. So you need to press ctrl+c again to terminate the thread.

Directories:

.                  
├── log           
├── models         
├── sumdata       
├── tmp           
├── transformer 
├── Beam.py       
├── config.py    
├── train.py          
├── mytest.py        
├── Transformer.py
├── translate.py  
└── utils.py      

Make sure your project contains the folders above.

How-to

  1. Run python train.py to train
  2. Run python mytest.py to generate summaries