task_categories:text-classification size_categories:100K<n<1M language:en license:cc-by-4.0 arxiv:2305.18917 arxiv:2201.05955 region:us
WANLI (Worker-AI Collaboration for NLI) is a collection of 108K English sentence pairs for the task of natural language inference (NLI). 
Each example is created by first identifying a "pocket" of examples in MultiNLI (Williams et al., 2018) that share a challenging reasoning pattern, then instructing GPT-3 to write a new example with the same pattern. 
The set of generated examples are automatically filtered to contain those most likely to aid model training, and finally labeled and optionally revised by human annotators.
@misc{liu-etal-2022-wanli,
    title = "WANLI: Worker and AI Collaboration for Natural Language Inference Dataset Creation",
    author = "Liu, Alisa  and
      Swayamdipta, Swabha  and
      Smith, Noah A.  and
      Choi, Yejin",
    month = jan,
    year = "2022",
    url = "https://arxiv.org/pdf/2201.05955",
}
---
license: cc-by-4.0
dataset_info:
- config_name: minority_examples
  features:
  - name: id
    dtype: int64
  - name: premise
    dtype: string
  - name: hypothesis
    dtype: string
  - name: gold
    dtype: string
  - name: genre
    dtype: string
  - name: pairID
    dtype: string
  splits:
  - name: train.biased
    num_bytes: 17807491
    num_examples: 89402
  - name: train.anti_biased
    num_bytes: 2690706
    num_examples: 13483
  - name: test.biased
    num_bytes: 865310
    num_examples: 4363
  - name: test.anti_biased
    num_bytes: 127605
    num_examples: 637
  download_size: 26671494
  dataset_size: 21491112
- config_name: partial_input
  features:
  - name: id
    dtype: int64
  - name: premise
    dtype: string
  - name: hypothesis
    dtype: string
  - name: gold
    dtype: string
  - name: genre
    dtype: string
  - name: pairID
    dtype: string
  splits:
  - name: train.biased
    num_bytes: 17792846
    num_examples: 89402
  - name: train.anti_biased
    num_bytes: 2705351
    num_examples: 13483
  - name: test.biased
    num_bytes: 858069
    num_examples: 4344
  - name: test.anti_biased
    num_bytes: 134846
    num_examples: 656
  download_size: 26671494
  dataset_size: 21491112
task_categories:
- text-classification
language:
- en
pretty_name: WANLI
size_categories:
- 100K<n<1M
---


# Dataset Card for Bias-amplified Splits for WANLI

## Table of Contents
- [Table of Contents](#table-of-contents)
- [Dataset Description](#dataset-description)
  - [Dataset Summary](#dataset-summary)
- [Dataset Structure](#dataset-structure)
  - [Data Instances](#data-instances)
  - [Data Fields](#data-fields)
  - [Data Splits](#data-splits)
- [Dataset Creation](#dataset-creation)
  - [Curation Rationale](#curation-rationale)
  - [Annotations](#annotations)
- [Considerations for Using the Data](#considerations-for-using-the-data)
  - [Social Impact of Dataset](#social-impact-of-dataset)
  - [Discussion of Biases](#discussion-of-biases)
- [Additional Information](#additional-information)
  - [Dataset Curators](#dataset-curators)
  - [Citation Information](#citation-information)

## Dataset Description

- **Repository:** [Fighting Bias with Bias repo](https://github.com/schwartz-lab-nlp/fight-bias-with-bias)
- **Paper:** [arXiv](https://arxiv.org/abs/2305.18917)
- **Point of Contact:** [Yuval Reif](mailto:yuval.reif@mail.huji.ac.il)
- **Original Dataset's Paper:** [WANLI](https://arxiv.org/abs/2201.05955)

### Dataset Summary

Bias-amplified splits is a novel evaluation framework to assess model robustness, by amplifying dataset biases in the training data and challenging models to generalize beyond them. This framework is defined by a bias-amplified training set and a hard, anti-biased test set, which we automatically extract from existing datasets using model-based methods.

Our experiments show that the identified anti-biased examples are naturally challenging for models, and moreover, models trained on bias-amplified data exhibit dramatic performance drops on anti-biased examples, which are not mitigated by common approaches to improve generalization.

Here we apply our framework to WANLI (**W**orker-**A**I Collaboration for **NLI**), a collection of 108K English sentence pairs for the task of natural language inference (NLI). WANLI was found to be more diverse and challenging for models compared to existing NLI datasets.

Our evaluation framework can be applied to any existing dataset, even those considered obsolete, to test model robustness. We hope our work will guide the development of robust models that do not rely on superficial biases and correlations.

#### Evaluation Results (DeBERTa-large)

##### For splits based on minority examples:

| Training Data \ Test Data | Original test | Anti-biased test |
|---------------------------|---------------|------------------|
| Original training split   | 77.1          | 61.7             |
| Biased training split     | 75.5          | 31.8             |

##### For splits based on partial-input model:

| Training Data \ Test Data | Original test | Anti-biased test |
|---------------------------|---------------|------------------|
| Original training split   | 77.1          | 62.6             |
| Biased training split     | 76.7          | 49.6             |

#### Loading the Data

```
from datasets import load_dataset

# choose which bias detection method to use for the bias-amplified splits: either "minority_examples" or "partial_input"
dataset = load_dataset("bias-amplified-splits/wanli", "minority_examples")

# use the biased training split and anti-biased test split
train_dataset = dataset['train.biased']
eval_dataset = dataset['test.anti_biased']
```

## Dataset Structure

### Data Instances

Data instances are taken directly from WANLI, and re-split into biased and anti-biased subsets. Here is an example of an instance from the dataset:
```
{
  "id": 225295,
  "premise": "It is a tribute to the skill of the coach that the team has been able to compete at the highest level.",
  "hypothesis": "The coach is a good coach.",
  "gold": "entailment",
  "genre": "generated",
  "pairID": "171408"
}
```
 
### Data Fields

- `id`: unique identifier for the example
- `premise`: a piece of text 
- `hypothesis`: a piece of text that may be true, false, or whose truth conditions may not be knowable when compared to the premise
- `gold`: one of `entailment`, `neutral`, and `contradiction`
- `genre`: one of `generated` and `generated_revised`, depending on whether the example was revised by annotators
- `pairID`: id of seed MNLI example, corresponding to those in `data/mnli/train.jsonl`

### Data Splits

Bias-amplified splits require a method to detect *biased* and *anti-biased* examples in datasets. We release bias-amplified splits based created with each of these two methods:
- **Minority examples**: A novel method we introduce that leverages representation learning and clustering for identifying anti-biased *minority examples* (Tu et al., 2020)—examples that defy common statistical patterns found in the rest of the dataset.
- **Partial-input baselines**: A common method for identifying biased examples containing annotation artifacts in a dataset, which examines the performance of models that are restricted to using only part of the input. Such models, if successful, are bound to rely on unintended or spurious patterns in the dataset.

Using each of the two methods, we split each of the original train and test splits into biased and anti-biased subsets. See the [paper](https://arxiv.org/abs/2305.18917) for more details.

#### Minority Examples

| Dataset Split       | Number of Instances in Split |
|---------------------|------------------------------|
| Train - biased      | 89402                        |
| Train - anti-biased | 13483                        |
| Test - biased       | 4363                         |
| Test - anti-biased  | 637                          |

#### Partial-input Baselines

| Dataset Split       | Number of Instances in Split |
|---------------------|------------------------------|
| Train - biased      | 89402                        |
| Train - anti-biased | 13483                        |
| Test - biased       | 4344                         |
| Test - anti-biased  | 656                          |

## Dataset Creation

### Curation Rationale

NLP models often rely on superficial cues known as *dataset biases* to achieve impressive performance, and can fail on examples where these biases do not hold. To develop more robust, unbiased models, recent work aims to filter bisased examples from training sets. We argue that in order to encourage the development of robust models, we should in fact **amplify** biases in the training sets, while adopting the challenge set approach and making test sets anti-biased. To implement our approach, we introduce a simple framework that can be applied automatically to any existing dataset to use it for testing model robustness.

### Annotations

#### Annotation process

No new annotations are required to create bias-amplified splits. Existing data instances are split into *biased* and *anti-biased* splits based on automatic model-based methods to detect such examples.

## Considerations for Using the Data

### Social Impact of Dataset

Bias-amplified splits were created to promote the development of robust NLP models that do not rely on superficial biases and correlations, and provide more challenging evaluation of existing systems.

### Discussion of Biases

We propose to use bias-amplified splits to complement benchmarks with challenging evaluation settings that test model robustness, in addition to the dataset’s main training and test sets. As such, while existing dataset biases are *amplified* during training with bias-amplified splits, these splits are intended primarily for model evaluation, to expose the bias-exploiting behaviors of models and to identify more robsut models and effective robustness interventions.

## Additional Information

### Dataset Curators

Bias-amplified splits were introduced by Yuval Reif and Roy Schwartz from the [Hebrew University of Jerusalem](https://schwartz-lab-huji.github.io).

WANLI was developed by Alisa Liu, Swabha Swayamdipta, Noah A. Smith, and Yejin Choi from the [University of Washington](https://www.cs.washington.edu/) and [AI2](https://allenai.org/).

### Citation Information

```
@misc{reif2023fighting,
    title = "Fighting Bias with Bias: Promoting Model Robustness by Amplifying Dataset Biases",
    author = "Yuval Reif and Roy Schwartz",
    month = may,
    year = "2023",
    url = "https://arxiv.org/pdf/2305.18917",
}
```

Source dataset:
```
@misc{liu-etal-2022-wanli,
    title = "WANLI: Worker and AI Collaboration for Natural Language Inference Dataset Creation",
    author = "Liu, Alisa  and
      Swayamdipta, Swabha  and
      Smith, Noah A.  and
      Choi, Yejin",
    month = jan,
    year = "2022",
    url = "https://arxiv.org/pdf/2201.05955",
}
```