GithubHelp home page GithubHelp logo

hyukhunkoh-ai / mfma Goto Github PK

View Code? Open in Web Editor NEW

This project forked from hwanheelee1993/mfma

0.0 0.0 0.0 37 KB

Factual consistency checking model for abstractive summaries (NAACL-22 Findings)

Python 100.00%

mfma's Introduction

MFMA

This repository provides a factual consistency checking model from our NAACL-Findings 2022 paper Masked Summarization to Generate Factually Inconsistent Summaries for Improved Factual Consistency Checking.

1. Usage of pre-trained factual consistency checking model

MFMA is a pre-trained factual consistency checking model(trained as a binary classifier) for abstractive summaries trained with the augmented negative samples using Mask-and-Fill with Article(MFMA).

You only need huggingface transformers library to load the pre-trained model.

from transformers import AutoModelforSequenceClassification
model = AutoModelforSequenceClassification("henry931007/mfma")

2. Training MFMA Instructions

Usage

1) Install Prerequisites

Create a python 3.8 environment and then install the requirements.

Install packages using "requirements.txt"

conda create -name msm python=3.8
pip install -r requirements.txt

2) Training MFMA

python train_fb.py --mask_ratio1 $MASK_ARTICLE \
                   --mask_ratio2 $MASK_ARTICLE \

3) Generating Negative Summaries with MFMA

python infer_fb.py --mask_ratio1 $MASK_ARTICLE \
                   --mask_ratio2 $MASK_ARTICLE \

4) Training Factual Consistency Checking Model using the Data

python train_metric.py --datadir $DATA_PATH \

References

@inproceedings{lee2022mfma,
      title={Masked Summarization to Generate Factually Inconsistent Summaries for Improved Factual Consistency Checking}, 
      author={Hwanhee Lee and Kang Min Yoo and Joonsuk Park and Hwaran Lee and Kyomin Jung},
      year={2022},
      month={july},
      booktitle={Findings of the Association for Computational Linguistics: NAACL 2022},
}

mfma's People

Contributors

hwanheelee1993 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.