SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 1809.02079 · 2018

Adversarial Over-Sensitivity and Over-Stability Strategies for Dialogue Models

arXiv · PDF · Open in the Atlas

Code that ran

5 of 7 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 5 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/1809.02079.json · badge: /api/ran/1809.02079.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
WolfNiu/AdversarialDialogue canonical (classifier label)
classifier basis: census
5 ran · 2 no recorded run
FunctionStatusWhere it lives
build_dict Ran
ran on a synthesized input
WolfNiu/AdversarialDialogue/src/basic/util.py
code served (permissive licence) · get_code("e878ba003537ff17")
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
import numpy as np

torch.manual_seed(0)

# Test case 1: Single list - creates index-to-value mapping
lst1_single = ['apple', 'banana', 'cherry']
args_single = {
    'lst1': lst1_single,
    'lst2': []
}

# Test case 2: Two lists of same length
lst1_pair = ['key1', 'key2', 'key3']
lst2_pair = ['value1', 'value2', 'value3']
args_pair = {
    'lst1': lst1_pair,
    'lst2': lst2_pair
}

# Use the single list case as primary example
ARGS = {
    'lst1': ['apple', 'banana', 'cherry'],
    'lst2': []
}
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 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
build_index2token Ran
ran on a synthesized input
WolfNiu/AdversarialDialogue/src/basic/util.py
code served (permissive licence) · get_code("1463fb622dd5abde")
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
import numpy as np

torch.manual_seed(0)

# The function takes a list and an optional reverse boolean flag
# It creates a dictionary mapping either index->value or value->index

# Create a simple list of tokens/values
token_list = ["hello", "world", "foo", "bar", "baz"]

ARGS = {
    "lst": token_list,
    "reverse": False
}
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 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
double Ran
ran on a synthesized input
WolfNiu/AdversarialDialogue/src/model/util.py
code served (permissive licence) · get_code("1d29567f1b72bfd6")
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 EagerTensor, ndim 2, dtype family float, shape (4, 4) as a later run recorded it. The image it ran in was 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 tensorflow as tf
import numpy as np

# Create a small TensorFlow tensor
t = tf.constant(np.random.randn(2, 4).astype(np.float32))

ARGS = {
    "t": t
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type EagerTensor, ndim 2, dtype family float, shape (4, 4) — shape (4, 4) 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
split_lst Ran
ran on a synthesized input
WolfNiu/AdversarialDialogue/src/basic/util.py
code served (permissive licence) · get_code("bfb118ac1dd2775b")
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. 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 itertools

def append(sents, token_index):
    assert [] not in sents
    assert isinstance(sents[0], list)
    appended = [sent + [token_index] for sent in sents]
    return appended

def split_lst(lst, delimiter, keep_delimiter=True):
    """
    Split list into sublists based on a delimiter
    """
    if keep_delimiter:
        append = [delimiter]
    else:
        append = []
    sublists = [list(y) + append for x, y in itertools.groupby(lst, lambda z: z == delimiter) if not x]
    return sublists

# Setup code to construct valid arguments
lst = [1, 2, 3, 0, 4, 5, 0, 6, 7]
delimiter = 0
keep_delimiter = True

ARGS = {
    "lst": lst,
    "delimiter": delimiter,
    "keep_delimiter": keep_delimiter
}
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 — a list output has no array shape of its own; none is 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
to_str Ran
ran on a synthesized input
WolfNiu/AdversarialDialogue/src/basic/ubuntu_data_generator.py
code served (permissive licence) · get_code("ca020336382cc115")
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 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 torch
import numpy as np

torch.manual_seed(0)

# Analyzing the function:
# - batch_examples is iterated as a list of examples
# - Each example is iterated to get turns
# - Each turn is iterated to get tokens
# - Each token is converted to string
# The function expects a nested list structure: batch -> examples -> turns -> tokens

# Constructing valid arguments
batch_examples = [
    # First example with 2 turns
    [
        [1, 2, 3],           # turn 1: 3 tokens
        [4, 5]               # turn 2: 2 tokens
    ],
    # Second example with 2 turns
    [
        [6, 7, 8, 9],        # turn 1: 4 tokens
        [10, 11, 12]         # turn 2: 3 tokens
    ]
]

ARGS = {
    'batch_examples': batch_examples
}
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 2, 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
convert_to_number Not yet run
unverified (harvested, no recorded run)
WolfNiu/AdversarialDialogue/src/model/util.py
code served (permissive licence) · get_code("950f8b6375fa3b09")
How it ran

no invocation recorded.

sequence_loss Not yet run
unverified (harvested, no recorded run)
WolfNiu/AdversarialDialogue/src/model/util.py
code served (permissive licence) · get_code("f678595b260df788")
How it ran

no invocation recorded.

Also present in other papers' code

Of 7 samples lifted from this paper's linked repositories, 7 carry a function identity and 0 do not. Of the 7 distinct functions with an identity, 0 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 0 later) and 7 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.

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

We present two categories of model-agnostic adversarial strategies that reveal the weaknesses of several generative, task-oriented dialogue models: Should-Not-Change strategies that evaluate over-sensitivity to small and semantics-preserving edits, as well as Should-Change strategies that test if a model is over-stable against subtle yet semantics-changing modifications. We next perform adversarial training with each strategy, employing a max-margin approach for negative generative examples. This not only makes the target dialogue model more robust to the adversarial inputs, but also helps it perform significantly better on the original inputs. Moreover, training on all strategies combined achieves further improvements, achieving a new state-of-the-art performance on the original task (also verified via human evaluation). In addition to adversarial training, we also address the robustness task at the model-level, by feeding it subword units as both inputs and outputs, and show that the resulting model is equally competitive, requires only 1/4 of the original vocabulary size, and is robust to one of the adversarial strategies (to which the original model is vulnerable) even without adversarial training.

For agents

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

get_harvested_code_for_paper("1809.02079")
get_code_for_paper("1809.02079")
have("1809.02079")

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

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

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

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

Connect an agent — have() is free.