SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 1912.05372 · 2019

FlauBERT: Unsupervised Language Model Pre-training for French

arXiv · PDF · Open in the Atlas

Code that ran

7 of 9 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, 1 violated it and 6 have no contract verdict; 0 failures of our instrument; 2 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/1912.05372.json · badge: /api/ran/1912.05372.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
TheophileBlard/french-sentiment-analysis-with-bert community (classifier label)
classifier basis not recorded on the link
5 ran · 0 no recorded run
getalp/disambiguate community (classifier label)
classifier basis not recorded on the link
2 ran · 2 no recorded run
FunctionStatusWhere it lives
check_sru_requirement Ran
ran, violated the contract we drafted
getalp/disambiguate/python/onmt/models/sru.py
code served (permissive licence) · get_code("0c93830510f645a3")
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 bool, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. The code mentions cuda, and the harness aliases cuda to the CPU for every sample; whether this run needed that is 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 torch

torch.manual_seed(0)

ARGS = {
    'abort': False
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type bool, ndim 0, dtype family float, shape () — shape () 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
context_gate_factory Ran
ran on a synthesized input
getalp/disambiguate/python/onmt/modules/gate.py
code served (permissive licence) · get_code("655c4a8978903a61")
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 BothContextGate. 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 torch.nn as nn

torch.manual_seed(0)

# Define small, distinct dimensions for different meaning
embeddings_size = 4
decoder_size = 5
attention_size = 6
output_size = 7

ARGS = {
    'gate_type': 'both',
    'embeddings_size': embeddings_size,
    'decoder_size': decoder_size,
    'attention_size': attention_size,
    'output_size': output_size,
}
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 BothContextGate — a BothContextGate output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a BothContextGate 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
get_data Ran
ran on a synthesized input
TheophileBlard/french-sentiment-analysis-with-bert/utils_acl.py
code served (permissive licence) · get_code("1428b5516b0a164b")
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 2, 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 os
import tempfile
from xml.etree.ElementTree import Element, SubElement, ElementTree

# Create temporary directory with test XML files
temp_dir = tempfile.mkdtemp()

# Create train.review file with XML content
train_file_path = os.path.join(temp_dir, 'train.review')
train_root = Element('reviews')

train_item1 = SubElement(train_root, 'item')
text1 = SubElement(train_item1, 'text')
text1.text = 'This product is terrible and broke immediately'
rating1 = SubElement(train_item1, 'rating')
rating1.text = '1'

train_item2 = SubElement(train_root, 'item')
text2 = SubElement(train_item2, 'text')
text2.text = 'Excellent product, highly recommended'
rating2 = SubElement(train_item2, 'rating')
rating2.text = '5'

train_item3 = SubElement(train_root, 'item')
text3 = SubElement(train_item3, 'text')
text3.text = 'Not bad but could be better'
rating3 = SubElement(train_item3, 'rating')
rating3.text = '3'

train_tree = ElementTree(train_root)
train_tree.write(train_file_path)

# Create test.review file with XML content
test_file_path = os.path.join(temp_dir, 'test.review')
test_root = Element('reviews')

test_item1 = SubElement(test_root, 'item')
text4 = SubElement(test_item1, 'text')
text4.text = 'Awful waste of money'
rating4 = SubElement(test_item1, 'rating')
rating4.text = '2'

test_item2 = SubElement(test_root, 'item')
text5 = SubElement(test_item2, 'text')
text5.text = 'Perfect quality and fast shipping'
rating5 = SubElement(test_item2, 'rating')
rating5.text = '4'

test_tree = ElementTree(test_root)
test_tree.write(test_file_path)

ARGS = {
    'folder': temp_dir
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 2, 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
parse_file Ran
ran on a synthesized input
TheophileBlard/french-sentiment-analysis-with-bert/utils_acl.py
code served (permissive licence) · get_code("7843e5379321e72d")
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 2, 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 numpy as np
from xml.etree.ElementTree import Element, ElementTree
import tempfile
import os

# Create a temporary XML file with sample review data
def create_sample_xml():
    root = Element('reviews')
    
    # Item with rating <= 2 (should be labeled 0)
    item1 = Element('item')
    text1 = Element('text')
    text1.text = 'This product is terrible'
    rating1 = Element('rating')
    rating1.text = '1'
    item1.append(text1)
    item1.append(rating1)
    root.append(item1)
    
    # Item with rating >= 4 (should be labeled 1)
    item2 = Element('item')
    text2 = Element('text')
    text2.text = 'This product is amazing'
    rating2 = Element('rating')
    rating2.text = '5'
    item2.append(text2)
    item2.append(rating2)
    root.append(item2)
    
    # Item with rating 3 (should be skipped)
    item3 = Element('item')
    text3 = Element('text')
    text3.text = 'This product is okay'
    rating3 = Element('rating')
    rating3.text = '3'
    item3.append(text3)
    item3.append(rating3)
    root.append(item3)
    
    # Item with rating 2 (should be labeled 0)
    item4 = Element('item')
    text4 = Element('text')
    text4.text = 'Not great'
    rating4 = Element('rating')
    rating4.text = '2'
    item4.append(text4)
    item4.append(rating4)
    root.append(item4)
    
    # Write to temporary file
    temp_fd, temp_path = tempfile.mkstemp(suffix='.xml')
    tree = ElementTree(root)
    tree.write(temp_path, encoding='utf-8', xml_declaration=True)
    os.close(temp_fd)
    return temp_path

xml_file_path = create_sample_xml()

ARGS = {
    'file': xml_file_path
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 2, 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
plot_training_curves Ran
ran on a synthesized input
TheophileBlard/french-sentiment-analysis-with-bert/utils.py
code served (permissive licence) · get_code("3ba692edead757df")
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 Figure. 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 matplotlib.pyplot as plt

class MockHistory:
    def __init__(self):
        self.history = {
            'accuracy': [0.5, 0.6, 0.7, 0.75],
            'val_accuracy': [0.48, 0.58, 0.68, 0.72],
            'loss': [2.3, 1.8, 1.2, 0.9],
            'val_loss': [2.4, 1.9, 1.3, 1.0]
        }

history_obj = MockHistory()

ARGS = {
    'history': history_obj,
    'figsize': (12, 5)
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
matplotlib — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Figure — a Figure output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Figure 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
print_confusion_matrix Ran
ran on a synthesized input
TheophileBlard/french-sentiment-analysis-with-bert/utils.py
code served (permissive licence) · get_code("3766be0864eb80f0")
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 Figure. 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
import matplotlib.pyplot as plt
import pandas as pd
import seaborn as sns

# Create a small confusion matrix
# Using a 3x3 matrix for a 3-class classification problem
confusion_matrix = np.array([
    [45, 5, 0],
    [3, 42, 5],
    [2, 8, 40]
])

# Define class names
class_names = ['Class_A', 'Class_B', 'Class_C']

# Construct the ARGS dictionary
ARGS = {
    'confusion_matrix': confusion_matrix,
    'class_names': class_names,
    'figsize': (10, 7),
    'fontsize': 14
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
matplotlib, numpy, pandas, seaborn — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Figure — a Figure output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Figure 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
process_item Ran
ran on a synthesized input
TheophileBlard/french-sentiment-analysis-with-bert/utils_acl.py
code served (permissive licence) · get_code("fbdb4336ee093312")
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.

from xml.etree.ElementTree import Element, SubElement
import xml.etree.ElementTree as ET

# Create a mock XML item with the required structure
item = Element('item')

# Add text subelement
text_elem = SubElement(item, 'text')
text_elem.text = 'This is a great product! Highly recommended.'

# Add rating subelement
rating_elem = SubElement(item, 'rating')
rating_elem.text = '4.5'

ARGS = {
    'item': item
}
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 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
collapse_copy_scores Not yet run
unverified (harvested, no recorded run)
getalp/disambiguate/python/onmt/modules/copy_generator.py
code served (permissive licence) · get_code("b60aff23d14fc8ae")
How it ran

no invocation recorded.

seq_linear Not yet run
unverified (harvested, no recorded run)
getalp/disambiguate/python/onmt/modules/conv_multi_step_attention.py
pointer only (licence: MIT); the stored copy get_code serves, from Alex-Fabbri/Multi-News, is pointer only (licence: NOASSERTION) · get_code("0c3bddd7d3eaba02")
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 Alex-Fabbri/Multi-News, and GitHub could not classify the licence of that repository (NOASSERTION). 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. No invocation recorded.

Also present in other papers' code

Of 9 samples lifted from this paper's linked repositories, 9 carry a function identity and 0 do not. Of the 9 distinct functions with an identity, 4 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 5 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
check_sru_requirement 8 other papers
5 dated earlier, 3 later
1709.02755 (2017-09)
Simple Recurrent Units for Highly Parallelizable Recurrence
1805.11462 (2018-05)
OpenNMT: Neural Machine Translation Toolkit
1906.06253 (2019-06)
A Simple and Effective Approach to Automatic Post-Editing with Transfer Learning
and 5 more not named here
seq_linear 8 other papers
4 dated earlier, 4 later
1805.11462 (2018-05)
OpenNMT: Neural Machine Translation Toolkit
1906.06253 (2019-06)
A Simple and Effective Approach to Automatic Post-Editing with Transfer Learning
1906.07651 (2019-06)
Scheduled Sampling for Transformers
and 5 more not named here
collapse_copy_scores 3 other papers
1 dated earlier, 2 later
1805.11462 (2018-05)
OpenNMT: Neural Machine Translation Toolkit
2020.acl-main.640 (2020 (year only))
Heterogeneous Graph Transformer for Graph-to-Sequence Learning
2004.00588 (2020-04)
Better Sign Language Translation with STMC-Transformer
context_gate_factory 1 other paper
1 dated earlier
1805.11462 (2018-05)
OpenNMT: Neural Machine Translation Toolkit

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

Language models have become a key step to achieve state-of-the art results in many different Natural Language Processing (NLP) tasks. Leveraging the huge amount of unlabeled texts nowadays available, they provide an efficient way to pre-train continuous word representations that can be fine-tuned for a downstream task, along with their contextualization at the sentence level. This has been widely demonstrated for English using contextualized representations (Dai and Le, 2015; Peters et al., 2018; Howard and Ruder, 2018; Radford et al., 2018; Devlin et al., 2019; Yang et al., 2019b). In this paper, we introduce and share FlauBERT, a model learned on a very large and heterogeneous French corpus. Models of different sizes are trained using the new CNRS (French National Centre for Scientific Research) Jean Zay supercomputer. We apply our French language models to diverse NLP tasks (text classification, paraphrasing, natural language inference, parsing, word sense disambiguation) and show that most of the time they outperform other pre-training approaches. Different versions of FlauBERT as well as a unified evaluation protocol for the downstream tasks, called FLUE (French Language Understanding Evaluation), are shared to the research community for further reproducible experiments in French NLP.

For agents

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

get_harvested_code_for_paper("1912.05372")
get_code_for_paper("1912.05372")
have("1912.05372")

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

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

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

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

Connect an agent — have() is free.