SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2108.11846 · 2021

Alleviating Exposure Bias via Contrastive Learning for Abstractive Text Summarization

arXiv · PDF · Open in the Atlas

Code that ran

5 of 6 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; 1 honoured the contract we drafted, 0 violated it and 2 have no contract verdict; 2 failures of our instrument; 1 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/2108.11846.json · badge: /api/ran/2108.11846.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
shichaosun/conabssum canonical (classifier label)
classifier basis: census
5 ran · 1 no recorded run
FunctionStatusWhere it lives
add_newline_to_end_of_each_sentence Ran
ran on a synthesized input
shichaosun/conabssum/src/sentence_splitter.py
code served (permissive licence) · get_code("8609dcbe6167c497")
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, through the batch API) and returned str. 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.

# Setup code for add_newline_to_end_of_each_sentence

ARGS = {
    'x': 'This is a sentence<n>This is another sentence<n>End of text'
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not 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
count_trainable_parameters Ran
ran, honoured the contract we drafted
shichaosun/conabssum/src/callbacks.py
pointer only (licence: MIT); the stored copy get_code serves, from manga-uofa/fdistill, is pointer only (licence: NONE) · get_code("a3826392847cbef3")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from manga-uofa/fdistill, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

get_early_stopping_callback Ran
ran; our contract draft was wrong, not the code
shichaosun/conabssum/src/callbacks.py
pointer only (licence: MIT); the stored copy get_code serves, from manga-uofa/fdistill, is pointer only (licence: NONE) · get_code("295d9fdc5ce0b054")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from manga-uofa/fdistill, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

label_smoothed_nll_loss Ran
ran on a synthesized input
shichaosun/conabssum/src/utils.py
code served (permissive licence) · get_code("e386d3a24af4d168")
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, through the batch API) and returned tuple, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim 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 torch

torch.manual_seed(0)

# Create log probabilities tensor
# Shape: (batch_size=2, vocab_size=4)
# lprobs should be log probabilities, so values between -inf and 0
lprobs = torch.log(torch.softmax(torch.randn(2, 4), dim=-1))

# Create target indices tensor
# Shape: (batch_size=2,) - indices into the vocabulary
# Values should be in range [0, vocab_size) or ignore_index
target = torch.tensor([1, 2], dtype=torch.long)

# Epsilon for label smoothing (typically small, e.g., 0.1)
epsilon = 0.1

# Ignore index for padding tokens
ignore_index = -100

ARGS = {
    "lprobs": lprobs,
    "target": target,
    "epsilon": epsilon,
    "ignore_index": ignore_index,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 1, dtype family float — a tuple output has no array shape of its own; none is stated
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
lmap Ran
ran; our contract draft was wrong, not the code
shichaosun/conabssum/src/utils.py
code served (permissive licence) · get_code("7c43af131a6f39a6")
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, through the batch API) and returned list, ndim 1, dtype family int; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim 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 torch
import numpy as np
from typing import Callable, List, Iterable

torch.manual_seed(0)

# Define a simple callable function
def square(x):
    """Simple function that squares its input"""
    return x ** 2

# Define an iterable (list of numbers)
numbers = [1, 2, 3, 4, 5]

# Construct ARGS dict
ARGS = {
    "f": square,
    "x": numbers,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 1, dtype family int — a list output has no array shape of its own; none is stated
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
get_checkpoint_callback Not yet run
unverified (harvested, no recorded run)
shichaosun/conabssum/src/callbacks.py
code served (permissive licence) · get_code("952f6fff9428619b")
How it ran

no invocation recorded.

Also present in other papers' code

Of 6 samples lifted from this paper's linked repositories, 6 carry a function identity and 0 do not. Of the 6 distinct functions with an identity, 5 are also present in other papers whose code we hold (5 with at least one paper dated earlier, 0 the same month, 4 later) and 1 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
count_trainable_parameters 13 other papers
6 dated earlier, 7 later
1911.13299 (2019-11)
What's Hidden in a Randomly Weighted Neural Network?
2007.08426 (2020-07)
Investigating Pretrained Language Models for Graph-to-Text Generation
2010.05953 (2020-10)
COMET-ATOMIC 2020: On Symbolic and Neural Commonsense Knowledge Graphs
and 10 more not named here
get_early_stopping_callback 9 other papers
4 dated earlier, 5 later
2007.08426 (2020-07)
Investigating Pretrained Language Models for Graph-to-Text Generation
2010.11856 (2020-10)
XOR QA: Cross-lingual Open-Retrieval Question Answering
2104.08400 (2021-04)
Structure-Aware Abstractive Conversation Summarization via Discourse and Action Graphs
and 6 more not named here
lmap 9 other papers
5 dated earlier, 4 later
2007.08426 (2020-07)
Investigating Pretrained Language Models for Graph-to-Text Generation
2104.08400 (2021-04)
Structure-Aware Abstractive Conversation Summarization via Discourse and Action Graphs
2104.08691 (2021-04)
The Power of Scale for Parameter-Efficient Prompt Tuning
and 6 more not named here
label_smoothed_nll_loss 7 other papers
5 dated earlier, 2 later
2007.08426 (2020-07)
Investigating Pretrained Language Models for Graph-to-Text Generation
2104.08400 (2021-04)
Structure-Aware Abstractive Conversation Summarization via Discourse and Action Graphs
2104.08691 (2021-04)
The Power of Scale for Parameter-Efficient Prompt Tuning
and 4 more not named here
get_checkpoint_callback 1 other paper
1 dated earlier
2105.11174 (2021-05)
Retrieval Enhanced Model for Commonsense Generation

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

Encoder-decoder models have achieved remarkable success in abstractive text summarization, which aims to compress one or more documents into a shorter version without the loss of the essential content. Unfortunately, these models mostly suffer a discrepancy between training and inference, i.e., the exposure bias problem. During the training stage, with teacher forcing these models are optimized to maximize the likelihood of the gold summary given the gold summary tokens as input to the decoder, while at inference the given tokens are replaced by the generated tokens. Consequently, low-quality summaries are very likely to be generated. To remedy this problem, we propose to leverage contrastive learning to decrease the likelihood of these low-quality summaries, and meanwhile increase the likelihood of the gold summary. Since our solution expands the states that the model perceives during training, we expect that the exposure bias problem can be alleviated. We experimentally demonstrate that our method effectively improves the performance of the state-of-the-art model on different datasets.

For agents

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

get_harvested_code_for_paper("2108.11846")
get_code_for_paper("2108.11846")
have("2108.11846")

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

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

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

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

Connect an agent — have() is free.