Code and data for the EMNLP 2021 paper "Just Say No: Analyzing the Stance of Neural Dialogue Generation in Offensive Contexts". Coming soon!

Overview

ToxiChat

Code and data for the EMNLP 2021 paper "Just Say No: Analyzing the Stance of Neural Dialogue Generation in Offensive Contexts".

Install dependencies

conda env create -f environment.yml

Data

The train, dev, test split of the data are given in data/OC_S_post_thread/ folder

Offensive and Stance Classification models

Single instance Offensive Classification

NBOW model

We will train NBOW single sentence classification model initialized with GloVe embedding
To train NBOW model, you'd need to download and extract GloVe vectors into data/GloVe/ dir and then run python convert_glove_text_vectors_to_pkl.py from within the directory

  • Training offensive classifier on OC_S_post_thread data
    python experiments/train_and_evaluate_NBOW_offensive_classifier.py -g data/GloVe/glove.6B.300d.pkl -td "{'OC_S':'data/OC_S_post_thread/'}" -s saved_models/OC_S_post_thread/NBOW_OC_S_offensive_e30 -o results/OC_S_post_thread/NBOW_OC_S_offensive_e30 -e 30 -dv 1 -t

BERT large cased model

  • Training offensive classifier on OC_S_post_thread data
    python experiments/train_and_evaluate_BERT_offensive_classifier.py -e 8 -td "{'OC_S':'data/OC_S_post_thread/'}" -s saved_models/OC_S_post_thread/BERT_large_OC_S_offensive_e8 -o results/OC_S_post_thread/BERT_large_OC_S_offensive_e8 -t

Full Sequence Offensive Classification (DGPT)

We will train a DGPT model offensive classifier for the entire comment thread with EOS tokens used for sentence representations.

  • Training offensive classifier on OC_S_post_thread data
    python experiments/train_and_evaluate_DGPT_offensive_classifier.py -e 12 -td "{'OC_S':'data/OC_S_post_thread/'}" -s saved_models/OC_S_post_thread/DGPT_medium_OC_S_offensive_e12 -o results/OC_S_post_thread/DGPT_medium_OC_S_offensive_e12 -t
  • Training offensive classifier on OC_S_post_thread + SBF data
    python experiments/train_and_evaluate_DGPT_offensive_classifier.py -e 3 -td "{'OC_S':'data/OC_S_post_thread/', 'SBF':'data/SBF'}" -s saved_models/OC_S_post_thread/DGPT_medium_OC_S_and_SBF_offensive_e3 -o results/OC_S_post_thread/DGPT_medium_OC_S_and_SBF_offensive_e3 -t -dv 4

Stance Classification

Pairwise Stance Classification

NBOW model

We will train NBOW Sentence Pair classification model initialized with GloVe embedding

  • Training Stance classifier on OC_S_post_thread_data (cross entropy)
    python experiments/train_and_evaluate_NBOW_pairwise_stance_classifier.py -g data/GloVe/glove.6B.300d.pkl -td "{'OC_S':'data/OC_S_post_thread/'}" -s saved_models/OC_S_post_thread/NBOW_OC_S_pairwise_stance_e30 -o results/OC_S_post_thread/NBOW_OC_S_pairwise_stance_e30 -e 30 -dv 1 -t

BERT large cased model

We will train Bert Sentence Pair classification model

  • Training Stance classifier on OC_S_post_thread_data (cross entropy)
    python experiments/train_and_evaluate_BERT_pairwise_stance_classifier.py -e 8 -td "{'OC_S':'data/OC_S_post_thread/'}" -s saved_models/OC_S_post_thread/BERT_large_OC_S_pairwise_stance_e8 -o results/OC_S_post_thread/BERT_large_OC_S_pairwise_stance_e8 -t

Full Sequence Stance Classification

We will train a DGPT model stance classifier for the entire comment thread with EOS tokens used for sentence representations.

  • Training Stance classifier on OC_S_post_thread_data (cross entropy)
    python experiments/train_and_evaluate_DGPT_stance_classifier.py -e 12 -td "{'OC_S':'data/OC_S_post_thread/'}" -s saved_models/OC_S_post_thread/DGPT_medium_OC_S_stance_e12 -o results/OC_S_post_thread/DGPT_medium_OC_S_stance_e12 -t
  • Training Stance classifier on OC_S_post_thread_data (Focal Loss)
    python experiments/train_and_evaluate_DGPT_stance_classifier.py -e 16 -td "{'OC_S':'data/OC_S_post_thread/'}" -s saved_models/OC_S_post_thread/DGPT_medium_OC_S_stance_e16_focal_lr5e_5 -o results/OC_S_post_thread/DGPT_medium_OC_S_stance_e16_focal_lr5e_5 -foc -lr 5e-5 -t

To download pretrained DGPT offensive and Stance (Focal) classifiers use the following link

Mitigating Offensive language using Controlled Text Generation

Dataset Preparation

We will first create a dataset of posts and comments from all of the reddit. Then we will create comment trees from these posts and comments and label them with our stance and offensive classifiers

Downloading the reddit posts and comments dumps

  1. Download the reddit comments and submissions dumps from August(08) to October(10), 2019 in the data folder
    mkdir -p data/reddit_dumps/comments_compressed
    cd data/reddit_dumps/comments_compressed
    wget -nc https://files.pushshift.io/reddit/comments/RC_2019-10.zst
    wget -nc https://files.pushshift.io/reddit/comments/RC_2019-09.zst
    wget -nc https://files.pushshift.io/reddit/comments/RC_2019-08.zst
    wget -nc https://files.pushshift.io/reddit/comments/RC_2019-07.zst
    wget -nc https://files.pushshift.io/reddit/comments/RC_2019-06.zst
    wget -nc https://files.pushshift.io/reddit/comments/RC_2019-05.zst
    cd ..
    mkdir posts_compressed
    cd posts_compressed
    wget -nc https://files.pushshift.io/reddit/submissions/RS_2019-10.zst
    wget -nc https://files.pushshift.io/reddit/submissions/RS_2019-09.zst
    wget -nc https://files.pushshift.io/reddit/submissions/RS_2019-08.zst
    wget -nc https://files.pushshift.io/reddit/submissions/RS_2019-07.zst
    wget -nc https://files.pushshift.io/reddit/submissions/RS_2019-06.zst
    wget -nc https://files.pushshift.io/reddit/submissions/RS_2019-05.zst
    cd ../../
    

Create posts and comments sample

  • python extract_reddit_posts.py -f data/reddit_dumps/posts_compressed/RS_2019-10.zst data/reddit_dumps/posts_compressed/RS_2019-09.zst data/reddit_dumps/posts_compressed/RS_2019-08.zst data/reddit_dumps/posts_compressed/RS_2019-07.zst data/reddit_dumps/posts_compressed/RS_2019-06.zst data/reddit_dumps/posts_compressed/RS_2019-05.zst -p 0.8 -o data/reddit_dumps/posts/all_mitigating_sample/
  • python extract_reddit_comments_for_posts.py -f data/reddit_dumps/comments_compressed/RC_2019-05.zst data/reddit_dumps/comments_compressed/RC_2019-06.zst data/reddit_dumps/comments_compressed/RC_2019-07.zst data/reddit_dumps/comments_compressed/RC_2019-08.zst data/reddit_dumps/comments_compressed/RC_2019-09.zst data/reddit_dumps/comments_compressed/RC_2019-10.zst -p data/reddit_dumps/posts/all_mitigating_sample/all_subreddit_posts.jsonl -o data/reddit_dumps/comments/all_mitigating_sample/

Create threads from posts and comments sample

python create_post_comment_trees_from_all_reddit_sample.py -ip data/reddit_dumps/posts/all_mitigating_sample/all_subreddit_posts.jsonl -ic data/reddit_dumps/comments/all_mitigating_sample/all_subreddit_post_related_comments.jsonl -mc 3 -o data/reddit_dumps/post_comment_threads/all_mitigating_sample/

Split the post comment threads into 4 splits

python split_threads_into_files.py -i data/reddit_dumps/post_comment_threads/all_mitigating_sample/all_reddit_post_and_comments_3_threads.pkl -o data/reddit_dumps/post_comment_threads/all_mitigating_sample/splits/ -n 4

Predict separately for each split

  • python predict_DGPT_stance_on_post_comment_trees.py -i data/reddit_dumps/post_comment_threads/all_mitigating_sample/splits/split_0.pkl -sm saved_models/OC_S_post_thread/DGPT_medium_OC_S_stance_e16_focal_lr5e_5 -om saved_models/OC_S_post_thread/DGPT_medium_OC_S_and_SBF_offensive_e2 -o data/reddit_dumps/post_comment_threads/all_mitigating_sample/splits/predictions_both/ -s data/reddit_dumps/post_comment_threads/all_mitigating_sample/splits/predictions_both/split_0_preds.pkl
  • python predict_DGPT_stance_on_post_comment_trees.py -i data/reddit_dumps/post_comment_threads/all_mitigating_sample/splits/split_1.pkl -sm saved_models/OC_S_post_thread/DGPT_medium_OC_S_stance_e16_focal_lr5e_5 -om saved_models/OC_S_post_thread/DGPT_medium_OC_S_and_SBF_offensive_e2 -o data/reddit_dumps/post_comment_threads/all_mitigating_sample/splits/predictions_both/ -s data/reddit_dumps/post_comment_threads/all_mitigating_sample/splits/predictions_both/split_1_preds.pkl
  • python predict_DGPT_stance_on_post_comment_trees.py -i data/reddit_dumps/post_comment_threads/all_mitigating_sample/splits/split_2.pkl -sm saved_models/OC_S_post_thread/DGPT_medium_OC_S_stance_e16_focal_lr5e_5 -om saved_models/OC_S_post_thread/DGPT_medium_OC_S_and_SBF_offensive_e2 -o data/reddit_dumps/post_comment_threads/all_mitigating_sample/splits/predictions_both/ -s data/reddit_dumps/post_comment_threads/all_mitigating_sample/splits/predictions_both/split_2_preds.pkl
  • python predict_DGPT_stance_on_post_comment_trees.py -i data/reddit_dumps/post_comment_threads/all_mitigating_sample/splits/split_3.pkl -sm saved_models/OC_S_post_thread/DGPT_medium_OC_S_stance_e16_focal_lr5e_5 -om saved_models/OC_S_post_thread/DGPT_medium_OC_S_and_SBF_offensive_e2 -o data/reddit_dumps/post_comment_threads/all_mitigating_sample/splits/predictions_both/ -s data/reddit_dumps/post_comment_threads/all_mitigating_sample/splits/predictions_both/split_3_preds.pkl

Merge predictions

python merge_Off_Stance_predictions.py -i data/reddit_dumps/post_comment_threads/all_mitigating_sample/splits/predictions_both/ -n 4 -o data/reddit_dumps/post_comment_threads/all_mitigating_sample/splits/predictions_both/merged_split_predictions.pkl

Create CTG fine-tuning dataset from post_comment threads with stance and offensive labels

python get_fine_tuning_subsets_from_label_predicted_convs.py -i data/reddit_dumps/post_comment_threads/all_mitigating_sample/splits/predictions_both/merged_split_predictions.pkl -o data/reddit_dumps/post_comment_threads/CTG_experiments/all_mitigating_sample/final/

Fine-tune DGPT medium model for different CTG experiments

DAPT

CTG using DAPT i.e. simply training on the subset we care about

1. Off Control [SAFE] subset (DAPT - [S])

python experiments/CTG_DGPT_finetuner.py -so [SAFE] -t data/reddit_dumps/post_comment_threads/CTG_experiments/all_mitigating_sample/final/off_control_train.pkl -d data/reddit_dumps/post_comment_threads/CTG_experiments/all_mitigating_sample/final/off_control_dev.pkl -s saved_models/CTG/Off_control_DGPT_safe_subset -o results/CTG/Off_control_DGPT_safe_subset -e 3

2. Safe Stance Control [NO-STANCE] subset (DAPT - [S][N])

python experiments/CTG_DGPT_finetuner.py -so [NO-STANCE] -t data/reddit_dumps/post_comment_threads/CTG_experiments/all_mitigating_sample/final/safe_stance_control_train.pkl -d data/reddit_dumps/post_comment_threads/CTG_experiments/all_mitigating_sample/final/safe_stance_control_dev.pkl -s saved_models/CTG/safe_stance_control_DGPT_no_stance_subset -o results/CTG/safe_stance_control_DGPT_no_stance_subset -e 3

ATCON

CTG using control labels

1. Offensive Label Control (ATCON [S])

python experiments/CTG_DGPT_finetuner.py -t data/reddit_dumps/post_comment_threads/CTG_experiments/all_mitigating_sample/final/off_control_train.pkl -d data/reddit_dumps/post_comment_threads/CTG_experiments/all_mitigating_sample/final/off_control_dev.pkl -s saved_models/CTG/Off_control_DGPT -o results/CTG/Off_control_DGPT -e 3 -dv 100

2. Stance Label Control (Safe) (ATCON [N])

python experiments/CTG_DGPT_finetuner.py -t data/reddit_dumps/post_comment_threads/CTG_experiments/all_mitigating_sample/final/safe_stance_control_train.pkl -d data/reddit_dumps/post_comment_threads/CTG_experiments/all_mitigating_sample/final/safe_stance_control_dev.pkl -s saved_models/CTG/safe_stance_control_DGPT -o results/CTG/safe_stance_control_DGPT -e 3

3. Both Offensive and Stance Label Control (both) (ATCON [S][N])

python experiments/CTG_DGPT_finetuner.py -t data/reddit_dumps/post_comment_threads/CTG_experiments/all_mitigating_sample/final/both_control_train.pkl -d data/reddit_dumps/post_comment_threads/CTG_experiments/all_mitigating_sample/final/both_control_dev.pkl -s saved_models/CTG/both_control_DGPT -o results/CTG/both_control_DGPT -e 3

Generate Responses on test set using CTG models

Control labels [OFF]/[SAFE] and [AGREE]/[NO-STANCE]

  • Baseline No Control
    python generate_CTG_responses_and_make_off_and_stance_predictions.py -m microsoft/DialoGPT-medium -d data/reddit_dumps/post_comment_threads/CTG_experiments/all_mitigating_sample/final/test_threads.pkl -sm saved_models/OC_S_post_thread/DGPT_medium_OC_S_stance_e16_focal_lr5e_5 -om saved_models/OC_S_post_thread/DGPT_medium_OC_S_and_SBF_offensive_e3 -n 1 -bs 10 -o results/CTG/DGPT/test_threads_replies_and_off_stance_preds.pkl
  • DAPT Offensive Control Safe Subset (DAPT - [S])
    python generate_CTG_responses_and_make_off_and_stance_predictions.py -m saved_models/CTG/Off_control_DGPT_safe_subset -d data/reddit_dumps/post_comment_threads/CTG_experiments/all_mitigating_sample/final/test_threads.pkl -sm saved_models/OC_S_post_thread/DGPT_medium_OC_S_stance_e16_focal_lr5e_5 -om saved_models/OC_S_post_thread/DGPT_medium_OC_S_and_SBF_offensive_e2 -n 1 -bs 10 -o results/CTG/Off_control_DGPT/DAPT_Off_control_safe_subset_test_threads_replies_and_off_stance_preds.pkl
  • DAPT Safe Stance Control No-Stance Subset (DAPT - [S][N])
    python generate_CTG_responses_and_make_off_and_stance_predictions.py -m saved_models/CTG/safe_stance_control_DGPT_no_stance_subset -d data/reddit_dumps/post_comment_threads/CTG_experiments/all_mitigating_sample/final/test_threads.pkl -sm saved_models/OC_S_post_thread/DGPT_medium_OC_S_stance_e16_focal_lr5e_5 -om saved_models/OC_S_post_thread/DGPT_medium_OC_S_and_SBF_offensive_e2 -n 1 -bs 10 -o results/CTG/safe_stance_control_DGPT/DAPT_safe_stance_control_no_stance_subset_test_threads_replies_and_off_stance_preds.pkl
  • Offensive Control (ATCON - [S])
    python generate_CTG_responses_and_make_off_and_stance_predictions.py -m saved_models/CTG/Off_control_DGPT -p [SAFE] -d data/reddit_dumps/post_comment_threads/CTG_experiments/all_mitigating_sample/final/test_threads.pkl -sm saved_models/OC_S_post_thread/DGPT_medium_OC_S_stance_e16_focal_lr5e_5 -om saved_models/OC_S_post_thread/DGPT_medium_OC_S_and_SBF_offensive_e2 -n 1 -bs 10 -o results/CTG/Off_control_DGPT/Off_control_test_threads_safe_replies_and_off_stance_preds.pkl
  • Stance Control (Safe) (ATCON - [N])
    python generate_CTG_responses_and_make_off_and_stance_predictions.py -m saved_models/CTG/safe_stance_control_DGPT -p [NO-STANCE] -d data/reddit_dumps/post_comment_threads/CTG_experiments/all_mitigating_sample/final/test_threads.pkl -sm saved_models/OC_S_post_thread/DGPT_medium_OC_S_stance_e16_focal_lr5e_5 -om saved_models/OC_S_post_thread/DGPT_medium_OC_S_and_SBF_offensive_e2 -n 1 -bs 10 -o results/CTG/safe_stance_control_DGPT/safe_stance_control_test_threads_no_stance_replies_and_off_stance_preds.pkl
  • Both Control (ATCON - [S][N])
    python generate_CTG_responses_and_make_off_and_stance_predictions.py -m saved_models/CTG/both_control_DGPT -p [SAFE][NO-STANCE] -d data/reddit_dumps/post_comment_threads/CTG_experiments/all_mitigating_sample/final/test_threads.pkl -sm saved_models/OC_S_post_thread/DGPT_medium_OC_S_stance_e16_focal_lr5e_5 -om saved_models/OC_S_post_thread/DGPT_medium_OC_S_and_SBF_offensive_e2 -n 1 -bs 10 -o results/CTG/both_control_DGPT/both_control_test_threads_safe_no_stance_replies_and_off_stance_preds.pkl

Automatic evalaution of CTG test predictions

python automatic_evaluation_of_CTG_test_predictions.py -mg "[('DGPT medium baseline', 'results/CTG/DGPT/test_threads_replies_and_off_stance_preds.pkl'), ('ATCON - [S]', 'results/CTG/Off_control_DGPT/Off_control_test_threads_safe_replies_and_off_stance_preds.pkl'), ('ATCON [N]', 'results/CTG/safe_stance_control_DGPT/safe_stance_control_test_threads_no_stance_replies_and_off_stance_preds.pkl'), ('ATCON [N][S]', 'results/CTG/both_control_DGPT/both_control_test_threads_safe_no_stance_replies_and_off_stance_preds.pkl'), ('DAPT [S]', 'results/CTG/Off_control_DGPT/DAPT_Off_control_safe_subset_test_threads_replies_and_off_stance_preds.pkl'), ('DAPT [S][N]', 'results/CTG/safe_stance_control_DGPT/DAPT_safe_stance_control_no_stance_subset_test_threads_replies_and_off_stance_preds.pkl')]" -o results/CTG/auto_eval/

Citation

@article{baheti2021just,
  title={Just Say No: Analyzing the Stance of Neural Dialogue Generation in Offensive Contexts},
  author={Baheti, Ashutosh and Sap, Maarten and Ritter, Alan and Riedl, Mark},
  journal={arXiv preprint arXiv:2108.11830},
  year={2021}
}
You might also like...
Code for our EMNLP 2021 paper “Heterogeneous Graph Neural Networks for Keyphrase Generation”
Code for our EMNLP 2021 paper “Heterogeneous Graph Neural Networks for Keyphrase Generation”

GATER This repository contains the code for our EMNLP 2021 paper “Heterogeneous Graph Neural Networks for Keyphrase Generation”. Our implementation is

Code for our paper Aspect Sentiment Quad Prediction as Paraphrase Generation in EMNLP 2021.

Aspect Sentiment Quad Prediction (ASQP) This repo contains the annotated data and code for our paper Aspect Sentiment Quad Prediction as Paraphrase Ge

Abstractive opinion summarization system (SelSum) and the largest dataset of Amazon product summaries (AmaSum). EMNLP 2021 conference paper.
Abstractive opinion summarization system (SelSum) and the largest dataset of Amazon product summaries (AmaSum). EMNLP 2021 conference paper.

Learning Opinion Summarizers by Selecting Informative Reviews This repository contains the codebase and the dataset for the corresponding EMNLP 2021

EMNLP 2021 paper Models and Datasets for Cross-Lingual Summarisation.

This repository contains data and code for our EMNLP 2021 paper Models and Datasets for Cross-Lingual Summarisation. Please contact me at [email protected]

Implementation for the EMNLP 2021 paper "Interactive Machine Comprehension with Dynamic Knowledge Graphs".

Interactive Machine Comprehension with Dynamic Knowledge Graphs Implementation for the EMNLP 2021 paper. Dependencies apt-get -y update apt-get instal

This repository contains the PyTorch implementation of the paper STaCK: Sentence Ordering with Temporal Commonsense Knowledge appearing at EMNLP 2021.
This repository contains the PyTorch implementation of the paper STaCK: Sentence Ordering with Temporal Commonsense Knowledge appearing at EMNLP 2021.

STaCK: Sentence Ordering with Temporal Commonsense Knowledge This repository contains the pytorch implementation of the paper STaCK: Sentence Ordering

Pytorch implementation of paper
Pytorch implementation of paper "Efficient Nearest Neighbor Language Models" (EMNLP 2021)

Pytorch implementation of paper "Efficient Nearest Neighbor Language Models" (EMNLP 2021)

Data augmentation for NLP, accepted at EMNLP 2021 Findings
Data augmentation for NLP, accepted at EMNLP 2021 Findings

AEDA: An Easier Data Augmentation Technique for Text Classification This is the code for the EMNLP 2021 paper AEDA: An Easier Data Augmentation Techni

“Data Augmentation for Cross-Domain Named Entity Recognition” (EMNLP 2021)
“Data Augmentation for Cross-Domain Named Entity Recognition” (EMNLP 2021)

Data Augmentation for Cross-Domain Named Entity Recognition Authors: Shuguang Chen, Gustavo Aguilar, Leonardo Neves and Thamar Solorio This repository

Comments
  • Getting different result on the baseline DGPT

    Getting different result on the baseline DGPT

    result

    I am trying to reproduce the results in your paper given the codes and the model weights. I am getting different results. I run the experiment using the below command line, but I was not able to get the same results of yours.

    python generate_CTG_responses_and_make_off_and_stance_predictions.py -m microsoft/DialoGPT-medium -d ./final/test_threads.pkl -sm saved_models/OC_S_post_thread/DGPT_medium_OC_S_stance_e16_focal_lr5e_5 -om saved_models/OC_S_post_thread/DGPT_medium_OC_S_and_SBF_offensive_e3 -n 1 -bs 10 -o results/CTG/DGPT/test_threads_replies_and_off_stance_preds.pkl

    opened by jin8 2
  • data description

    data description

    Thanks for releasing the data and code. Could you please add some description of the collected data? An additional question: Why some u3stance labels are empty?

    opened by jing-qian 1
  • Setting up the environment

    Setting up the environment

    Hello, thanks for the awesome work! I tried to install the environment as in the README, but unfortunately, it's not working :( I've tried it on Mac and Linux, but neither worked for me.. Any suggestions?

    opened by skywalker023 7
Owner
Ashutosh Baheti
I am a Computer Science PhD student working with Prof. Alan Ritter. I will be a graduate student at Georgia Tech starting from Fall 2020.
Ashutosh Baheti
Related resources for our EMNLP 2021 paper

Plan-then-Generate: Controlled Data-to-Text Generation via Planning Authors: Yixuan Su, David Vandyke, Sihui Wang, Yimai Fang, and Nigel Collier Code

Yixuan Su 61 Jan 3, 2023
This repo is the code release of EMNLP 2021 conference paper "Connect-the-Dots: Bridging Semantics between Words and Definitions via Aligning Word Sense Inventories".

Connect-the-Dots: Bridging Semantics between Words and Definitions via Aligning Word Sense Inventories This repo is the code release of EMNLP 2021 con

null 12 Nov 22, 2022
Code and data for "Broaden the Vision: Geo-Diverse Visual Commonsense Reasoning" (EMNLP 2021).

GD-VCR Code for Broaden the Vision: Geo-Diverse Visual Commonsense Reasoning (EMNLP 2021). Research Questions and Aims: How well can a model perform o

Da Yin 24 Oct 13, 2022
Code and data to accompany the camera-ready version of "Cross-Attention is All You Need: Adapting Pretrained Transformers for Machine Translation" in EMNLP 2021

Code and data to accompany the camera-ready version of "Cross-Attention is All You Need: Adapting Pretrained Transformers for Machine Translation" in EMNLP 2021

Mozhdeh Gheini 16 Jul 16, 2022
The code repository for EMNLP 2021 paper "Vision Guided Generative Pre-trained Language Models for Multimodal Abstractive Summarization".

Vision Guided Generative Pre-trained Language Models for Multimodal Abstractive Summarization [Paper] accepted at the EMNLP 2021: Vision Guided Genera

CAiRE 42 Jan 7, 2023
This repository contains the official implementation code of the paper Improving Multimodal Fusion with Hierarchical Mutual Information Maximization for Multimodal Sentiment Analysis, accepted at EMNLP 2021.

MultiModal-InfoMax This repository contains the official implementation code of the paper Improving Multimodal Fusion with Hierarchical Mutual Informa

Deep Cognition and Language Research (DeCLaRe) Lab 89 Dec 26, 2022
Code for EMNLP 2021 paper Contrastive Out-of-Distribution Detection for Pretrained Transformers.

Contra-OOD Code for EMNLP 2021 paper Contrastive Out-of-Distribution Detection for Pretrained Transformers. Requirements PyTorch Transformers datasets

Wenxuan Zhou 27 Oct 28, 2022
Code for EMNLP 2021 main conference paper "Text AutoAugment: Learning Compositional Augmentation Policy for Text Classification"

Text-AutoAugment (TAA) This repository contains the code for our paper Text AutoAugment: Learning Compositional Augmentation Policy for Text Classific

LancoPKU 105 Jan 3, 2023
PyTorch code for EMNLP 2021 paper: Don't be Contradicted with Anything! CI-ToD: Towards Benchmarking Consistency for Task-oriented Dialogue System

Don’t be Contradicted with Anything!CI-ToD: Towards Benchmarking Consistency for Task-oriented Dialogue System This repository contains the PyTorch im

Libo Qin 25 Sep 6, 2022
PyTorch code for EMNLP 2021 paper: Don't be Contradicted with Anything! CI-ToD: Towards Benchmarking Consistency for Task-oriented Dialogue System

PyTorch code for EMNLP 2021 paper: Don't be Contradicted with Anything! CI-ToD: Towards Benchmarking Consistency for Task-oriented Dialogue System

Libo Qin 12 Sep 26, 2021