SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2204.05125 · 2022

ESCM$^2$: Entire Space Counterfactual Multi-Task Model for Post-Click Conversion Rate Estimation

arXiv · PDF · Open in the Atlas

Code that ran

6 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; 0 honoured the contract we drafted, 0 violated it and 4 have no contract verdict; 2 failures of our instrument; 0 no recorded run), measured 2026-11-23; 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/2204.05125.json · badge: /api/ran/2204.05125.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
PaddlePaddle/PaddleRec community (classifier label)
classifier basis not recorded on the link
6 ran · 0 no recorded run
FunctionStatusWhere it lives
convert_by_vocab Ran
ran; our contract draft was wrong, not the code
PaddlePaddle/PaddleRec/datasets/Beauty/data_augment_candi_gen.py
pointer only (licence: Apache-2.0); the stored copy get_code serves, from huawei-noah/Pretrained-Language-Model, is pointer only (licence: NONE) · get_code("bf6088a6a68ef09c")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (Apache-2.0), but get_code serves the stored copy, first harvested from huawei-noah/Pretrained-Language-Model, 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.

create_NETFLIX_data_timesplit Ran
ran on a synthesized input
PaddlePaddle/PaddleRec/datasets/Netflix_deeprec/netflix_data_convert.py
code served (permissive licence) · get_code("3e1f263053e0bc1c")
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 random
import time
import datetime

random.seed(0)
time.sleep(0)

# Create mock NETFLIX data structure
# Expected format: {userId: [(itemId, rating, timestamp), ...]}
all_data = {
    'user1': [
        (101, 5, time.mktime(datetime.datetime.strptime('2020-01-15', '%Y-%m-%d').timetuple())),
        (102, 4, time.mktime(datetime.datetime.strptime('2020-01-20', '%Y-%m-%d').timetuple())),
        (103, 3, time.mktime(datetime.datetime.strptime('2020-03-10', '%Y-%m-%d').timetuple())),
        (104, 5, time.mktime(datetime.datetime.strptime('2020-03-25', '%Y-%m-%d').timetuple())),
    ],
    'user2': [
        (101, 4, time.mktime(datetime.datetime.strptime('2020-01-10', '%Y-%m-%d').timetuple())),
        (105, 5, time.mktime(datetime.datetime.strptime('2020-01-25', '%Y-%m-%d').timetuple())),
        (102, 3, time.mktime(datetime.datetime.strptime('2020-03-05', '%Y-%m-%d').timetuple())),
        (106, 4, time.mktime(datetime.datetime.strptime('2020-03-20', '%Y-%m-%d').timetuple())),
    ],
    'user3': [
        (103, 5, time.mktime(datetime.datetime.strptime('2020-01-05', '%Y-%m-%d').timetuple())),
        (104, 2, time.mktime(datetime.datetime.strptime('2020-01-30', '%Y-%m-%d').timetuple())),
        (105, 4, time.mktime(datetime.datetime.strptime('2020-03-15', '%Y-%m-%d').timetuple())),
    ],
}

train_min = '2020-01-01'
train_max = '2020-02-28'
test_min = '2020-03-01'
test_max = '2020-03-31'

ARGS = {
    'all_data': all_data,
    'train_min': train_min,
    'train_max': train_max,
    'test_min': test_min,
    'test_max': test_max,
}
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
data_partition Ran
ran; our contract draft was wrong, not the code
PaddlePaddle/PaddleRec/datasets/Beauty/data_augment_candi_gen.py
code served (permissive licence) · get_code("928d8fadc3a9fe9b")
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.

from collections import defaultdict
import tempfile
import os

# Create a temporary file with sample data
temp_file = tempfile.NamedTemporaryFile(mode='w', delete=False, suffix='.txt')
temp_file.write("1 10\n")
temp_file.write("1 20\n")
temp_file.write("1 30\n")
temp_file.write("2 15\n")
temp_file.write("2 25\n")
temp_file.write("2 35\n")
temp_file.write("3 40\n")
temp_file.write("3 50\n")
temp_file.write("3 60\n")
temp_file.write("4 100\n")
temp_file.write("4 200\n")
temp_file.close()

fname = temp_file.name

ARGS = {
    'fname': fname
}
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
load_graph Ran
ran on a synthesized input
PaddlePaddle/PaddleRec/datasets/AmazonBook/preprocess.py
code served (permissive licence) · get_code("e192b64a7c6ac2de")
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 tempfile
import os

# Create a temporary CSV file with test data
temp_file = tempfile.NamedTemporaryFile(mode='w', delete=False, suffix='.csv')
temp_file.write("1,10,100\n")
temp_file.write("1,20,50\n")
temp_file.write("2,30,200\n")
temp_file.write("1,40,75\n")
temp_file.write("2,35,150\n")
temp_file.close()

ARGS = {
    "source": temp_file.name
}
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 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
printable_text Ran
ran on a synthesized input
PaddlePaddle/PaddleRec/datasets/Beauty/data_augment_candi_gen.py
code served (permissive licence) · get_code("e4dbe9646176983b")
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 six

# The function takes a single parameter 'text' which should be either:
# - a str (works in both Python 2 and 3)
# - bytes (works in Python 3)

# Since we're running Python 3, we can test with both str and bytes
text_str = "Hello, world!"
text_bytes = b"Hello, bytes!"

# Test with string (most common case)
ARGS = {
    'text': text_str
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
six — 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
word_count Ran
ran on a synthesized input
PaddlePaddle/PaddleRec/datasets/ag_news/text2paddle.py
code served (permissive licence) · get_code("5d079a1802fd6cb9")
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 defaultdict. 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 collections
import csv
import re
import io

# Create a small CSV file in memory
csv_content = """hello world,test data
foo bar baz,another row
hello foo test,final row"""

input_file = io.StringIO(csv_content)

ARGS = {
    "column_num": 0,
    "input_file": input_file,
    "word_freq": None
}
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 defaultdict — a defaultdict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a defaultdict 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

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, 6 are also present in other papers whose code we hold (6 with at least one paper dated earlier, 0 the same month, 0 later) and 0 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
convert_by_vocab 4 other papers
4 dated earlier · 1 only as an assembly brick
1810.04805 (2018-10)
BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding
1904.06690 (2019-04)
BERT4Rec: Sequential Recommendation with Bidirectional Encoder Representations from Transformer
2003.11235 (2020-03)
AutoFIS: Automatic Feature Interaction Selection in Factorization Models for Click-Through Rate Prediction
and 1 more not named here
load_graph 3 other papers
3 dated earlier
2003.11235 (2020-03)
AutoFIS: Automatic Feature Interaction Selection in Factorization Models for Click-Through Rate Prediction
2008.13535 (2020-08)
DCN V2: Improved Deep & Cross Network and Practical Lessons for Web-scale Learning to Rank Systems
2106.03760 (2021-06)
DSelect-k: Differentiable Selection in the Mixture of Experts with Applications to Multi-Task Learning
word_count 3 other papers
3 dated earlier
2003.11235 (2020-03)
AutoFIS: Automatic Feature Interaction Selection in Factorization Models for Click-Through Rate Prediction
2008.13535 (2020-08)
DCN V2: Improved Deep & Cross Network and Practical Lessons for Web-scale Learning to Rank Systems
2106.03760 (2021-06)
DSelect-k: Differentiable Selection in the Mixture of Experts with Applications to Multi-Task Learning
data_partition 2 other papers
2 dated earlier
1904.06690 (2019-04)
BERT4Rec: Sequential Recommendation with Bidirectional Encoder Representations from Transformer
2003.11235 (2020-03)
AutoFIS: Automatic Feature Interaction Selection in Factorization Models for Click-Through Rate Prediction
printable_text 2 other papers
2 dated earlier
1810.04805 (2018-10)
BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding
2003.11235 (2020-03)
AutoFIS: Automatic Feature Interaction Selection in Factorization Models for Click-Through Rate Prediction
create_NETFLIX_data_timesplit 1 other paper
1 dated earlier
2003.11235 (2020-03)
AutoFIS: Automatic Feature Interaction Selection in Factorization Models for Click-Through Rate Prediction

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

Repositories linked to this paper

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

Abstract

Accurate estimation of post-click conversion rate is critical for building recommender systems, which has long been confronted with sample selection bias and data sparsity issues. Methods in the Entire Space Multi-task Model (ESMM) family leverage the sequential pattern of user actions, i.e. $impression\rightarrow click \rightarrow conversion$ to address data sparsity issue. However, they still fail to ensure the unbiasedness of CVR estimates. In this paper, we theoretically demonstrate that ESMM suffers from the following two problems: (1) Inherent Estimation Bias (IEB), where the estimated CVR of ESMM is inherently higher than the ground truth; (2) Potential Independence Priority (PIP) for CTCVR estimation, where there is a risk that the ESMM overlooks the causality from click to conversion. To this end, we devise a principled approach named Entire Space Counterfactual Multi-task Modelling (ESCM$^2$), which employs a counterfactual risk miminizer as a regularizer in ESMM to address both IEB and PIP issues simultaneously. Extensive experiments on offline datasets and online environments demonstrate that our proposed ESCM$^2$ can largely mitigate the inherent IEB and PIP issues and achieve better performance than baseline models.

For agents

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

get_harvested_code_for_paper("2204.05125")
get_code_for_paper("2204.05125")
have("2204.05125")

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

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

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

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

Connect an agent — have() is free.