SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2005.04732 · ACL · 2020

Towards Robustifying NLI Models Against Lexical Dataset Biases

Mohit Bansal, Xiang Zhou

arXiv · PDF · Open in the Atlas

Code that ran

4 of 11 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (0 of them constructed an object rather than computing a result; 0 honoured the contract we drafted, 0 violated it and 0 have no contract verdict; 4 failures of our instrument; 7 no recorded run), measured 2026-11-22; repository links from the Papers with Code archive attributed under CC BY-SA, no affiliation; bodies inline only under a permissive licence as GitHub detects it. Not a reproduction of the paper's results.

"Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results. This record, dated, as JSON: /api/ran/2005.04732.json · badge: /api/ran/2005.04732.svg

Each repository's role is a label: a classifier's output recorded on the link, or, where no role is recorded, what the Papers with Code archive marked. The line under it names its basis. Neither says who wrote the code.

RepositoryRoleRan
owenzx/LexicalDebias-ACL2020 marked official in Papers with Code
Papers with Code archive
4 ran · 7 no recorded run
FunctionStatusWhere it lives
combine_last_two_dimensions Ran
ran; our contract draft was wrong, not the code
owenzx/LexicalDebias-ACL2020/models/hex.py
code served (permissive licence) · get_code("4de7e27ebec50a84")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1) and returned EagerTensor, ndim 3, dtype family float, shape (2, 3, 20) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import tensorflow as tf
import numpy as np

# Create a small tensor with shape [..., a, b]
# Using shape (2, 3, 4, 5) where last two dimensions are 4 and 5
x = tf.constant(np.random.randn(2, 3, 4, 5), dtype=tf.float32)

ARGS = {
    "x": x
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
numpy, tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type EagerTensor, ndim 3, dtype family float, shape (2, 3, 20) — shape (2, 3, 20) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
length Ran
ran; our contract draft was wrong, not the code
owenzx/LexicalDebias-ACL2020/models/hex.py
code served (permissive licence) · get_code("bdffe2f0ce34eb31")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1) and returned tuple. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import tensorflow as tf
import numpy as np

# Create a small batch of sequences with shape (batch_size=2, max_seq_length=4, hidden_dim=3)
# Using some non-zero values and some zeros to test the padding detection
sequence = tf.constant([
    [[1.0, 2.0, 3.0], [4.0, 5.0, 6.0], [0.0, 0.0, 0.0], [0.0, 0.0, 0.0]],
    [[1.0, 1.0, 1.0], [2.0, 2.0, 2.0], [3.0, 3.0, 3.0], [0.0, 0.0, 0.0]]
], dtype=tf.float32)

ARGS = {
    "sequence": sequence
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
numpy, tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple — a tuple output has no array shape of its own; none is stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
mask_logits Ran
ran; our contract draft was wrong, not the code
owenzx/LexicalDebias-ACL2020/models/hex.py
code served (permissive licence) · get_code("1b1fb77042d2e192")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1) and returned EagerTensor, ndim 3, dtype family float, shape (2, 2, 4) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import tensorflow as tf
import numpy as np

# Create small tensors for testing
inputs = tf.constant([
    [[1.0, 2.0, 3.0, 4.0],
     [5.0, 6.0, 7.0, 8.0]],
    [[9.0, 10.0, 11.0, 12.0],
     [13.0, 14.0, 15.0, 16.0]]
], dtype=tf.float32)

# Create a mask with shape matching inputs
mask = tf.constant([
    [[1.0, 1.0, 0.0, 1.0],
     [1.0, 0.0, 1.0, 1.0]],
    [[0.0, 1.0, 1.0, 1.0],
     [1.0, 1.0, 0.0, 1.0]]
], dtype=tf.float32)

mask_value = -1e+30

ARGS = {
    "inputs": inputs,
    "mask": mask,
    "mask_value": mask_value
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
numpy, tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type EagerTensor, ndim 3, dtype family float, shape (2, 2, 4) — shape (2, 2, 4) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
split_last_dimension Ran
ran; our contract draft was wrong, not the code
owenzx/LexicalDebias-ACL2020/models/hex.py
code served (permissive licence) · get_code("625e74f352090a3a")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1) and returned EagerTensor, ndim 4, dtype family int, shape (2, 4, 3, 3) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import tensorflow as tf

# Create a small tensor with shape [..., m] where m is divisible by n
# Using shape [2, 3, 12] - batch of 2, some intermediate dim of 3, last dim of 12
x = tf.constant([
    [[1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12],
     [13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24],
     [25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36]],
    [[37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48],
     [49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60],
     [61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72]]
], dtype=tf.int32)

# n should divide evenly into the last dimension (12)
n = 4

ARGS = {
    "x": x,
    "n": n
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type EagerTensor, ndim 4, dtype family int, shape (2, 4, 3, 3) — shape (2, 4, 3, 3) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
HEX Not yet run
unverified (harvested, no recorded run)
owenzx/LexicalDebias-ACL2020/models/hex.py
code served (permissive licence) · get_code("498eb1889a79901e")
How it ran

no invocation recorded.

conv Not yet run
unverified (harvested, no recorded run)
owenzx/LexicalDebias-ACL2020/models/hex.py
code served (permissive licence) · get_code("413976febb345bb5")
How it ran

no invocation recorded.

dot_product_attention Not yet run
unverified (harvested, no recorded run)
owenzx/LexicalDebias-ACL2020/models/hex.py
code served (permissive licence) · get_code("0403fe04af127ad4")
How it ran

no invocation recorded.

layer_norm Not yet run
unverified (harvested, no recorded run)
owenzx/LexicalDebias-ACL2020/models/hex.py
code served (permissive licence) · get_code("11f9661c4bf99c8a")
How it ran

no invocation recorded.

layer_norm_compute_python Not yet run
unverified (harvested, no recorded run)
owenzx/LexicalDebias-ACL2020/models/hex.py
code served (permissive licence) · get_code("df5f1c26bcb94d35")
How it ran

no invocation recorded.

multihead_attention Not yet run
unverified (harvested, no recorded run)
owenzx/LexicalDebias-ACL2020/models/hex.py
code served (permissive licence) · get_code("0e1b744dc6c987e3")
How it ran

no invocation recorded.

simple_self_attention_block Not yet run
unverified (harvested, no recorded run)
owenzx/LexicalDebias-ACL2020/models/hex.py
code served (permissive licence) · get_code("4633aaac6d095124")
How it ran

no invocation recorded.

Also present in other papers' code

Of 11 samples lifted from this paper's linked repositories, 11 carry a function identity and 0 do not. Of the 11 distinct functions with an identity, 1 are also present in other papers whose code we hold (1 with at least one paper dated earlier, 0 the same month, 0 later) and 10 are only here among the 52,977 papers whose code Syntology holds (as of 2026-09-26).

Only here means: among the 52,977 papers whose code Syntology holds (51,887 with lifted samples, 1,090 through their assemblies only), as of 2026-09-26, no other paper's lifted samples or current assembly bricks contain an identical function body after normalisation.

FunctionAlso present inEarliest-datedOthers named
layer_norm_compute_python
brick of this paper's assembly: helper
2 other papers
2 dated earlier
1508.06615 (2015-08)
Character-Aware Neural Language Models
1909.06356 (2019-09)
Addressing Semantic Drift in Question Generation for Semi-Supervised Question Answering

Presence, not direction: an identical function body in two papers' repositories does not say who wrote it, which came from which, or that either paper's method rests on it. Matching is exact after normalisation, so a renamed or edited function is not matched. Dates are when papers appeared, not when code was written. Only .py files the harvester lifted are covered; notebooks are not read. A new-style arXiv id YYMM.NNNN dates a paper to the month 20YY-MM; otherwise Paper.year dates it to the year; otherwise it is undated. Dates are when the paper appeared, not when the code was written. Read 2026-11-22.

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

While deep learning models are making fast progress on the task of Natural Language Inference, recent studies have also shown that these models achieve high accuracy by exploiting several dataset biases, and without deep understanding of the language semantics. Using contradiction-word bias and word-overlapping bias as our two bias examples, this paper explores both data-level and model-level debiasing methods to robustify models against lexical dataset biases. First, we debias the dataset through data augmentation and enhancement, but show that the model bias cannot be fully removed via this method. Next, we also compare two ways of directly debiasing the model without knowing what the dataset biases are in advance. The first approach aims to remove the label bias at the embedding level. The second approach employs a bag-of-words submodel to capture the features that are likely to exploit the bias and prevents the original model from learning these biased features by forcing orthogonality between these two submodels. We performed evaluations on new balanced datasets extracted from the original MNLI dataset as well as the NLI stress tests, and show that the orthogonality approach is better at debiasing the model while maintaining competitive overall accuracy. 1

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("2005.04732")
get_code_for_paper("2005.04732")
have("2005.04732")

The run record, dated, one paper per request, free:

curl https://syntology.ai/api/ran/2005.04732.json

A badge for a README (the split and the date, never a ratio):

[![Syntology run record](https://syntology.ai/api/ran/2005.04732.svg)](https://syntology.ai/paper/2005.04732)

Connect an agent — have() is free.