8000 GitHub - cnunlp/SO_with_CoVer
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

cnunlp/SO_with_CoVer

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SO_with_CoVer

Code for 2023 ACL Findings Paper Sentence Ordering with a Coherence Verifier

Requirements

  • python==3.8.10
  • torch==1.13.0
  • transformers==4.24.0
  • dgl==0.9.1

Baselines

Data

For the AAN and NIPS data, please contact the authors of Sentence Ordering and Coherence Modeling using Recurrent Neural Networks.

The SIND dataset can be downloaded from the Visual Storytelling website.

And the ROCStory dataset can be download from here.

Code

CoVer

  • Construct the instance with gradual permutation. Replace the specific name such as 'roc' with 'dataset'

python get_pairwise_hier_dataset.py dataset

  • Train the model.

sh run_score.sh

B-TSort and BERSON with CoVer

If you already have the baseline B-TSort and BERSON model and a CoVer model, you can run run_rerank.sh in Topo_CoVer or run_{dataset}_coherence.sh in BERSON_CoVer.

Besides, we saved the pairwise scores generated by B-TSort in Topo_CoVer/pairwise_score, so that you can directly do the reranking process without having a B-TSort model.

Model

We provide the pretrained coherence model $CoVer$ and reproduced BERSON models for four datasets.

You can download from here: https://drive.google.com/drive/folders/1gHqH3inelArIDPhUIu8XjOAbXcaZSKok?usp=sharing

Reference

If you are intereseted in this work, please cite the following paper.

   @inproceedings{jia-etal-2023-sentence,
    title = "Sentence Ordering with a Coherence Verifier",
    author = "Jia, Sainan  and
      Song, Wei  and
      Gong, Jiefu  and
      Wang, Shijin  and
      Liu, Ting",
    booktitle = "Findings of the Association for Computational Linguistics: ACL 2023",
    month = jul,
    year = "2023",
    address = "Toronto, Canada",
    publisher = "Association for Computational Linguistics",
    url = "https://aclanthology.org/2023.findings-acl.592",
    doi = "10.18653/v1/2023.findings-acl.592",
    pages = "9301--9314",
    abstract = "This paper presents a novel sentence ordering method by plugging a coherence verifier (CoVer) into pair-wise ranking-based and sequence generation-based methods. It does not change the model parameters of the baseline, and only verifies the coherence of candidate (partial) orders produced by the baseline and reranks them in beam search. We also propose a coherence model as CoVer with a novel graph formulation and a novel data construction strategy for contrastive pre-training independently of the sentence ordering task. Experimental results on four benchmarks demonstrate the effectiveness of our method with topological sorting-based and pointer network-based methods as the baselines. Detailed analyses illustrate how CoVer improves the baselines and confirm the importance of its graph formulation and training strategy. Our code is available at https://github.com/SN-Jia/SO{\_}with{\_}CoVer.",
}

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 99.2%
  • Shell 0.8%
0