SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2004.06871 · EMNLP · 2020

TOD-BERT: Pre-trained Natural Language Understanding for Task-Oriented Dialogue

Chien-Sheng Wu, Richard Socher, Steven Hoi, Caiming Xiong

arXiv · PDF · Open in the Atlas

Code that ran

4 of 13 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 3 have no contract verdict; 1 failure of our instrument; 9 no recorded run), measured 2026-11-22; 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/2004.06871.json · badge: /api/ran/2004.06871.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
jasonwu0731/ToD-BERT canonical (classifier label)
classifier basis: census
4 ran · 9 no recorded run
FunctionStatusWhere it lives
cross_entropy Ran
ran on a synthesized input
jasonwu0731/ToD-BERT/utils/loss_function/masked_cross_entropy.py
pointer only (licence: BSD-2-Clause) · get_code("e155e413c186170f")
How it ran

The body of this sample is withheld: BSD-2-Clause, as GitHub detects it on this paper's repository, jasonwu0731/ToD-BERT, is in the permissive set, but a licence decision keeps the body a pointer: the reason for that decision is not recorded with it. 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_candidate_embeddings Ran
ran on a synthesized input
jasonwu0731/ToD-BERT/my_tod_pretraining.py
pointer only (licence: BSD-2-Clause) · get_code("d7133e89862027f1")
How it ran

The body of this sample is withheld: BSD-2-Clause, as GitHub detects it on this paper's repository, jasonwu0731/ToD-BERT, is in the permissive set, but a licence decision keeps the body a pointer: the reason for that decision is not recorded with it. 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.

mask_for_response_selection Ran
ran on a synthesized input
jasonwu0731/ToD-BERT/my_tod_pretraining.py
pointer only (licence: BSD-2-Clause) · get_code("62a820cce0f4f54a")
How it ran

The body of this sample is withheld: BSD-2-Clause, as GitHub detects it on this paper's repository, jasonwu0731/ToD-BERT, is in the permissive set, but a licence decision keeps the body a pointer: the reason for that decision is not recorded with it. 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.

sequence_mask Ran
ran; our contract draft was wrong, not the code
jasonwu0731/ToD-BERT/utils/loss_function/masked_cross_entropy.py
pointer only (licence: BSD-2-Clause) · get_code("45176015bba52028")
How it ran

The body of this sample is withheld: BSD-2-Clause, as GitHub detects it on this paper's repository, jasonwu0731/ToD-BERT, is in the permissive set, but a licence decision keeps the body a pointer: the reason for that decision is not recorded with it. 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.

collate_fn_dm_turn Not yet run
unverified (harvested, no recorded run)
jasonwu0731/ToD-BERT/utils/dataloader_dm.py
pointer only (licence: BSD-2-Clause) · get_code("1786a072383b7312")
How it ran

The body of this sample is withheld: BSD-2-Clause, as GitHub detects it on this paper's repository, jasonwu0731/ToD-BERT, is in the permissive set, but a licence decision keeps the body a pointer: the reason for that decision is not recorded with it. 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.

collate_fn_dst_dial Not yet run
unverified (harvested, no recorded run)
jasonwu0731/ToD-BERT/utils/dataloader_dst.py
pointer only (licence: BSD-2-Clause) · get_code("50ab5aef491ff1c6")
How it ran

The body of this sample is withheld: BSD-2-Clause, as GitHub detects it on this paper's repository, jasonwu0731/ToD-BERT, is in the permissive set, but a licence decision keeps the body a pointer: the reason for that decision is not recorded with it. 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.

collate_fn_dst_turn Not yet run
unverified (harvested, no recorded run)
jasonwu0731/ToD-BERT/utils/dataloader_dst.py
pointer only (licence: BSD-2-Clause) · get_code("7f7ea4638dd98813")
How it ran

The body of this sample is withheld: BSD-2-Clause, as GitHub detects it on this paper's repository, jasonwu0731/ToD-BERT, is in the permissive set, but a licence decision keeps the body a pointer: the reason for that decision is not recorded with it. 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.

collate_fn_nlg_turn Not yet run
unverified (harvested, no recorded run)
jasonwu0731/ToD-BERT/utils/dataloader_nlg.py
pointer only (licence: BSD-2-Clause) · get_code("35f90fdbc7b048f4")
How it ran

The body of this sample is withheld: BSD-2-Clause, as GitHub detects it on this paper's repository, jasonwu0731/ToD-BERT, is in the permissive set, but a licence decision keeps the body a pointer: the reason for that decision is not recorded with it. 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.

collate_fn_nlu_turn Not yet run
unverified (harvested, no recorded run)
jasonwu0731/ToD-BERT/utils/dataloader_nlu.py
pointer only (licence: BSD-2-Clause) · get_code("d8cb3aa9cb2984d6")
How it ran

The body of this sample is withheld: BSD-2-Clause, as GitHub detects it on this paper's repository, jasonwu0731/ToD-BERT, is in the permissive set, but a licence decision keeps the body a pointer: the reason for that decision is not recorded with it. 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.

collate_fn_usdl_dial Not yet run
unverified (harvested, no recorded run)
jasonwu0731/ToD-BERT/utils/dataloader_usdl.py
pointer only (licence: BSD-2-Clause) · get_code("793d288b1c25b8f7")
How it ran

The body of this sample is withheld: BSD-2-Clause, as GitHub detects it on this paper's repository, jasonwu0731/ToD-BERT, is in the permissive set, but a licence decision keeps the body a pointer: the reason for that decision is not recorded with it. 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.

collate_fn_usdl_dial_flat Not yet run
unverified (harvested, no recorded run)
jasonwu0731/ToD-BERT/utils/dataloader_usdl.py
pointer only (licence: BSD-2-Clause) · get_code("31070cc18d3734aa")
How it ran

The body of this sample is withheld: BSD-2-Clause, as GitHub detects it on this paper's repository, jasonwu0731/ToD-BERT, is in the permissive set, but a licence decision keeps the body a pointer: the reason for that decision is not recorded with it. 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.

collate_fn_usdl_turn Not yet run
unverified (harvested, no recorded run)
jasonwu0731/ToD-BERT/utils/dataloader_usdl.py
pointer only (licence: BSD-2-Clause) · get_code("174270cc38b29c53")
How it ran

The body of this sample is withheld: BSD-2-Clause, as GitHub detects it on this paper's repository, jasonwu0731/ToD-BERT, is in the permissive set, but a licence decision keeps the body a pointer: the reason for that decision is not recorded with it. 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.

masked_cross_entropy Not yet run
unverified (harvested, no recorded run)
jasonwu0731/ToD-BERT/utils/loss_function/masked_cross_entropy.py
pointer only (licence: BSD-2-Clause) · get_code("c43122df579b6d8b")
How it ran

The body of this sample is withheld: BSD-2-Clause, as GitHub detects it on this paper's repository, jasonwu0731/ToD-BERT, is in the permissive set, but a licence decision keeps the body a pointer: the reason for that decision is not recorded with it. 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 13 samples lifted from this paper's linked repositories, 13 carry a function identity and 0 do not. Of the 13 distinct functions with an identity, 3 are also present in other papers whose code we hold (3 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
sequence_mask 3 other papers
3 dated earlier
1804.08217 (2018-04)
Mem2Seq: Effectively Incorporating Knowledge Bases into End-to-End Task-Oriented Dialog Systems
1811.00239 (2018-11)
Progressive Memory Banks for Incremental Domain Adaptation
1901.04713 (2019-01)
Global-to-local Memory Pointer Networks for Task-Oriented Dialogue
cross_entropy 1 other paper
1 dated earlier
1901.04713 (2019-01)
Global-to-local Memory Pointer Networks for Task-Oriented Dialogue
masked_cross_entropy 1 other paper
1 dated earlier
1804.08217 (2018-04)
Mem2Seq: Effectively Incorporating Knowledge Bases into End-to-End Task-Oriented Dialog Systems

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

The underlying difference of linguistic patterns between general text and task-oriented dialogue makes existing pre-trained language models less useful in practice. In this work, we unify nine human-human and multi-turn task-oriented dialogue datasets for language modeling. To better model dialogue behavior during pre-training, we incorporate user and system tokens into the masked language modeling. We propose a contrastive objective function to simulate the response selection task. Our pre-trained task-oriented dialogue BERT (TOD-BERT) outperforms strong baselines like BERT on four downstream taskoriented dialogue applications, including intention recognition, dialogue state tracking, dialogue act prediction, and response selection. We also show that TOD-BERT has a stronger few-shot ability that can mitigate the data scarcity problem for task-oriented dialogue.

For agents

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

get_harvested_code_for_paper("2004.06871")
get_code_for_paper("2004.06871")
have("2004.06871")

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

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

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

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

Connect an agent — have() is free.