Need help with pointer_summarizer?
Click the “chat” button below for chat support from the developer who created it, or find similar developers for support.


pytorch implementation of "Get To The Point: Summarization with Pointer-Generator Networks"

570 Stars 169 Forks Apache License 2.0 85 Commits 21 Opened issues

Services available

Need anything else?

pytorch implementation of Get To The Point: Summarization with Pointer-Generator Networks

  1. Train with pointer generation and coverage loss enabled
  2. Training with pointer generation enabled
  3. How to run training
  4. Papers using this code

Train with pointer generation and coverage loss enabled

After training for 100k iterations with coverage loss enabled (batch size 8)

rouge_1_f_score: 0.3907 with confidence interval (0.3885, 0.3928)
rouge_1_recall: 0.4434 with confidence interval (0.4410, 0.4460)
rouge_1_precision: 0.3698 with confidence interval (0.3672, 0.3721)

ROUGE-2: rouge_2_f_score: 0.1697 with confidence interval (0.1674, 0.1720) rouge_2_recall: 0.1920 with confidence interval (0.1894, 0.1945) rouge_2_precision: 0.1614 with confidence interval (0.1590, 0.1636)

ROUGE-l: rouge_l_f_score: 0.3587 with confidence interval (0.3565, 0.3608) rouge_l_recall: 0.4067 with confidence interval (0.4042, 0.4092) rouge_l_precision: 0.3397 with confidence interval (0.3371, 0.3420)

Alt text

Training with pointer generation enabled

After training for 500k iterations (batch size 8)

rouge_1_f_score: 0.3500 with confidence interval (0.3477, 0.3523)
rouge_1_recall: 0.3718 with confidence interval (0.3693, 0.3745)
rouge_1_precision: 0.3529 with confidence interval (0.3501, 0.3555)

ROUGE-2: rouge_2_f_score: 0.1486 with confidence interval (0.1465, 0.1508) rouge_2_recall: 0.1573 with confidence interval (0.1551, 0.1597) rouge_2_precision: 0.1506 with confidence interval (0.1483, 0.1529)

ROUGE-l: rouge_l_f_score: 0.3202 with confidence interval (0.3179, 0.3225) rouge_l_recall: 0.3399 with confidence interval (0.3374, 0.3426) rouge_l_precision: 0.3231 with confidence interval (0.3205, 0.3256)

Alt text

How to run training:

1) Follow data generation instruction from 2) Run, you might need to change some path and parameters in datautil/ 3) For training run, for decoding run, and for evaluating run


  • In decode mode beam search batch should have only one example replicated to batch size

  • It is tested on pytorch 0.4 with python 2.7

  • You need to setup pyrouge to get the rouge score

Papers using this code:

1) Automatic Program Synthesis of Long Programs with a Learned Garbage Collector NeuroIPS 2018 2) Automatic Fact-guided Sentence Modification AAAI 2020 3) Resurrecting Submodularity in Neural Abstractive Summarization 4) StructSum: Incorporating Latent and Explicit Sentence Dependencies for Single Document Summarization 5) Concept Pointer Network for Abstractive Summarization EMNLP'2019 7) VAE-PGN based Abstractive Model in Multi-stage Architecture for Text Summarization INLG2019 8) Clickbait? Sensational Headline Generation with Auto-tuned Reinforcement Learning EMNLP'2019 9) Abstractive Spoken Document Summarization using Hierarchical Model with Multi-stage Attention Diversity Optimization INTERSPEECH 2020

We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.