SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2020.emnlp-main.750 · EMNLP · 2020

Evaluating the Factual Consistency of Abstractive Text Summarization

Richard Socher, Caiming Xiong, Bryan Mccann, Wojciech Kryści

Code that ran

6 of 8 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; 3 failures of our instrument; 2 no recorded run), measured 2026-11-24; 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/2020.emnlp-main.750.json · badge: /api/ran/2020.emnlp-main.750.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
salesforce/factCC canonical (classifier label)
classifier basis: census
6 ran · 2 no recorded run
FunctionStatusWhere it lives
acc_and_f1 Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
salesforce/factCC/modeling/utils.py
code served (permissive licence) · get_code("69c708de1ef7ce9c")
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 dict. 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 numpy as np
from sklearn.metrics import f1_score, balanced_accuracy_score, accuracy_score

def simple_accuracy(preds, labels):
    return (preds == labels).mean()

def acc_and_f1(preds, labels):
    acc = simple_accuracy(preds, labels)
    f1 = f1_score(y_true=labels, y_pred=preds)
    return {'acc': acc, 'f1': f1, 'acc_and_f1': (acc + f1) / 2}

# Create valid predictions and labels for binary classification
preds = np.array([0, 1, 1, 0, 1, 1])
labels = np.array([0, 1, 0, 0, 1, 1])

ARGS = {
    'preds': preds,
    'labels': labels
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, sklearn — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type dict — a dict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a dict 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
align_ws Ran
ran on a synthesized input
salesforce/factCC/data_generation/augmentation_ops.py
code served (permissive licence) · get_code("fe29fc9f48b1f885")
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.

import torch

torch.manual_seed(0)

def align_ws(old_token, new_token):
    if old_token[-1] == new_token[-1] == ' ':
        return new_token
    elif old_token[-1] == ' ':
        return new_token + ' '
    elif new_token[-1] == ' ':
        return new_token[:-1]
    else:
        return new_token

ARGS = {
    'old_token': 'hello ',
    'new_token': 'hi'
}
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 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
apply_transformation Ran
ran, honoured the contract we drafted
salesforce/factCC/data_generation/create_data.py
code served (permissive licence) · get_code("ef2e56035a5aec2f")
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 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
import torch.nn as nn

torch.manual_seed(0)

# Define a simple operation class that has a transform method
class SimpleOperation:
    def transform(self, example):
        # Transform the example by adding 1 to each element
        if example is not None:
            return example + 1
        return None

# Create sample data - list of small tensors
data = [
    torch.tensor([1.0, 2.0, 3.0, 4.0]),
    torch.tensor([5.0, 6.0, 7.0, 8.0]),
    torch.tensor([9.0, 10.0, 11.0, 12.0]),
]

# Create operation instance
operation = SimpleOperation()

# Define ARGS dict with all parameters
ARGS = {
    'data': data,
    'operation': operation,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch, tqdm — 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 float — 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
load_source_docs Ran
ran; our contract draft was wrong, not the code
salesforce/factCC/data_generation/create_data.py
code served (permissive licence) · get_code("769a10193e8f8886")
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 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 json
import tempfile
import os

# Create a temporary file with JSONL data
temp_dir = tempfile.mkdtemp()
temp_file = os.path.join(temp_dir, "test_docs.jsonl")

# Write sample JSONL data
with open(temp_file, 'w', encoding='utf-8') as f:
    f.write(json.dumps({'id': '1', 'text': 'Document one'}) + '\n')
    f.write(json.dumps({'id': '2', 'text': 'Document two'}) + '\n')
    f.write(json.dumps({'id': '3', 'text': 'Document three'}) + '\n')

ARGS = {
    'file_path': temp_file,
    'to_dict': False
}
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 list, ndim 1, dtype family float — 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
make_new_example Ran
ran on a synthesized input
salesforce/factCC/data_generation/augmentation_ops.py
code served (permissive licence) · get_code("6ff4bcea1267b8a9")
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 dict. 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 torch

torch.manual_seed(0)

ARGS = {
    'eid': 'example_001',
    'text': 'The quick brown fox jumps over the lazy dog',
    'claim': 'The fox is brown',
    'label': 1,
    'extraction_span': (4, 9),
    'backtranslation': 'The quick brown fox jumps over the lazy dog',
    'augmentation': 'The quick brown fox leaps over the lazy dog',
    'augmentation_span': (4, 9),
    'noise': 0.05
}
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 dict — a dict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a dict 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
parse_story_file Ran
ran; our contract draft was wrong, not the code
salesforce/factCC/data_pairing/pair_data.py
code served (permissive licence) · get_code("314e4a6841248541")
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.

import torch
import numpy as np

def parse_story_file(content):
    """
    Remove article highlights and unnecessary white characters.
    """
    content_raw = content.split('@highlight')[0]
    content = ' '.join(filter(None, [x.strip() for x in content_raw.split('\n')]))
    return content

# Construct valid arguments for parse_story_file
# The function expects a string 'content' parameter
sample_content = """This is the first paragraph of the story.
This is the second paragraph.

This is the third paragraph with some spacing.
@highlight
This is a highlight that should be removed.
@highlight
Another highlight."""

ARGS = {
    'content': sample_content
}
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 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
convert_examples_to_features Not yet run
unverified (harvested, no recorded run)
salesforce/factCC/modeling/utils.py
code served (permissive licence) · get_code("e6c482d1d48b3fc1")
How it ran

no invocation recorded.

simple_accuracy Not yet run
unverified (harvested, no recorded run)
salesforce/factCC/modeling/utils.py
code served (permissive licence) · get_code("3c241ecfe3749a6d")
How it ran

no invocation recorded.

Also present in other papers' code

Of 8 samples lifted from this paper's linked repositories, 8 carry a function identity and 0 do not. Of the 8 distinct functions with an identity, 5 are also present in other papers whose code we hold (4 with at least one paper dated earlier, 0 the same month, 3 later) and 3 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
simple_accuracy 59 other papers
13 dated earlier, 35 later, 11 same year, order not determinable
1506.05865 (2015-06)
LCSTS: A Large Scale Chinese Short Text Summarization Dataset
1509.01626 (2015-09)
Character-level Convolutional Networks for Text Classification *
1810.04805 (2018-10)
BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding
and 56 more not named here
acc_and_f1 22 other papers
6 dated earlier, 15 later, 1 same year, order not determinable
1810.04805 (2018-10)
BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding
1905.12866 (2019-05)
Semantically Conditioned Dialog Response Generation via Hierarchical Disentangled Self-Attention
1908.09355 (2019-08)
Patient Knowledge Distillation for BERT Model Compression
and 19 more not named here
apply_transformation 1 other paper
1 dated earlier
1910.12840 (2019-10)
Evaluating the Factual Consistency of Abstractive Text Summarization
load_source_docs 1 other paper
1 dated earlier
1910.12840 (2019-10)
Evaluating the Factual Consistency of Abstractive Text Summarization
parse_story_file 1 other paper
1 later
2606.28044 (2026-06)
A Tree-of-Thoughts Hybrid Approach for Legal Case Judgement Summarization using LLMs

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-24.

Repositories linked to this paper

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

Abstract

The most common metrics for assessing summarization algorithms do not account for whether summaries are factually consistent with source documents. We propose a weakly-supervised, model-based approach for verifying factual consistency and identifying conflicts between source documents and generated summaries. Training data is generated by applying a series of rule-based transformations to the sentences of source documents. The factual consistency model is then trained jointly for three tasks: 1) predict whether each summary sentence is factually consistent or not, 2) in either case, extract a span in the source document to support this consistency prediction, 3) for each summary sentence that is deemed inconsistent, extract the inconsistent span from it. Transferring this model to summaries generated by several neural models reveals that this highly scalable approach outperforms previous models, including those trained with strong supervision using datasets from related domains, such as natural language inference and fact checking. Additionally, human evaluation shows that the auxiliary span extraction tasks provide useful assistance in the process of verifying factual consistency. We also release a manually annotated dataset for factual consistency verification, code for training data generation, and trained model weights at https://github.com/salesforce/factCC.

For agents

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

get_harvested_code_for_paper("2020.emnlp-main.750")
get_code_for_paper("2020.emnlp-main.750")
have("2020.emnlp-main.750")

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

curl https://syntology.ai/api/ran/2020.emnlp-main.750.json

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

[![Syntology run record](https://syntology.ai/api/ran/2020.emnlp-main.750.svg)](https://syntology.ai/paper/2020.emnlp-main.750)

Connect an agent — have() is free.