SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 1912.10824 · 2019

Differentiable Reasoning on Large Knowledge Bases and Natural Language

arXiv · PDF · Open in the Atlas

Code that ran

15 of 26 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 15 have no contract verdict; 0 failures of our instrument; 11 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/1912.10824.json · badge: /api/ran/1912.10824.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
uclnlp/ntp canonical (classifier label)
classifier basis: census
9 ran · 7 no recorded run
uclnlp/gntp canonical (classifier label)
classifier basis: census
6 ran · 4 no recorded run
FunctionStatusWhere it lives
atom2string Ran
ran on a synthesized input
uclnlp/ntp/ntp/tp.py
code served (permissive licence) · get_code("842678021f43c382")
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.

class Atom:
    def __init__(self, predicate, arguments):
        self.predicate = predicate
        self.arguments = arguments

atom = Atom(
    predicate="likes",
    arguments=["alice", "bob", "charlie"]
)

ARGS = {
    "atom": atom
}
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 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
attention Ran
ran on a synthesized input
uclnlp/gntp/gntp/attention.py
code served (permissive licence) · get_code("8ff6535b5f8688aa")
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 (2, 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 small test tensors
# logits: shape (r, e) - used in einsum 'cr,re->ce'
# mask: shape (c, r) - used in einsum after softmax

# Set dimensions to be distinct:
# c = 2 (clauses)
# r = 3 (rows/attention positions)
# e = 4 (embedding dimension)

logits = tf.constant([
    [1.0, 2.0, 3.0, 4.0],
    [5.0, 6.0, 7.0, 8.0],
    [9.0, 10.0, 11.0, 12.0]
], dtype=tf.float32)  # shape (3, 4) = (r, e)

mask = tf.constant([
    [0.1, 0.5, 0.4],
    [0.2, 0.3, 0.5]
], dtype=tf.float32)  # shape (2, 3) = (c, r)

ARGS = {
    "logits": logits,
    "mask": mask
}
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 (2, 4) — shape (2, 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
check_checkpoint_finished Ran
ran on a synthesized input
uclnlp/gntp/bin/gntp-cli.py
code served (permissive licence) · get_code("6ff9dbea90d5710f")
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 bool, ndim 0, dtype family float, shape () 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 os
import tempfile
import shutil

# Create a temporary directory to serve as the checkpoint path
temp_dir = tempfile.mkdtemp()

# Test case 1: checkpoint with 'finished' file (should return True)
checkpoint_path_with_finished = temp_dir
finished_file_path = os.path.join(checkpoint_path_with_finished, 'finished')
open(finished_file_path, 'w').close()

ARGS = {
    '_checkpoint_path': checkpoint_path_with_finished
}
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 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
clip Ran
ran on a synthesized input
uclnlp/gntp/gntp/losses.py
code served (permissive licence) · get_code("504b918b060a4ed7")
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 SymbolicTensor. 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 tensorflow as tf
import numpy as np

# Create a small TensorFlow tensor with values between 0 and 2
# to test clipping behavior (will be clipped to [epsilon, 1.0])
x = tf.constant([[0.0, 0.5, 1.5, 2.0],
                 [0.1, 0.8, 1.2, 0.3]], dtype=tf.float32)

epsilon = 1e-10

ARGS = {
    "x": x,
    "epsilon": epsilon,
}
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 SymbolicTensor — a SymbolicTensor 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
create_mask Ran
ran on a synthesized input
uclnlp/gntp/gntp/masking.py
code served (permissive licence) · get_code("bd0230f569a312c8")
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 (30, 10) 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

# Test case 1: Basic 2D mask with some positive indices
mask_indices_1 = tf.constant([6, -1, -1, 22, -1, -1, 3, -1, -1, 7], dtype=tf.int32)
mask_shape_1 = tf.TensorShape([30, 10])

# Test case 2: 3D mask with positive indices
mask_indices_2 = tf.constant([5, -1, 8, -1, 2], dtype=tf.int32)
mask_shape_2 = tf.TensorShape([15, 4, 5])

# Test case 3: Using indices parameter for _create_mask2
mask_indices_3 = tf.constant([2, -1, 3, -1], dtype=tf.int32)
mask_shape_3 = tf.TensorShape([6, 4])
indices_3 = tf.constant([[2, 5], [1, 3], [0, 4], [3, 2]], dtype=tf.int32)

ARGS = {
    "mask_indices": mask_indices_1,
    "mask_shape": mask_shape_1,
    "indices": None
}
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 (30, 10) — shape (30, 10) 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
diff_k_max Ran
ran on a synthesized input
uclnlp/ntp/ntp/kmax.py
code served (permissive licence) · get_code("137ebc202f3a3a6e")
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 3, 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

# Create a small scores matrix [N x M] where N=4, M=3
scores = np.array([
    [0.5, 0.2, 0.9],
    [0.3, 0.8, 0.1],
    [0.7, 0.4, 0.6],
    [0.2, 0.9, 0.3]
], dtype=np.float32)

# k should be less than N
k = 2

ARGS = {
    "scores": scores,
    "k": k
}
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 3, 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
get_buckets Ran
ran on a synthesized input
uclnlp/ntp/ntp/jtr/preprocess/batch.py
code served (permissive licence) · get_code("b6dbe45fcd29ec5e")
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 numpy as np

# Read the function: it accesses data[order[i]][id] and calls len() on those values
# order is a tuple of keys from data
# structure is a tuple with same length as order, each element is int or list of ints
# The function iterates through data instances by index and checks lengths of nested sequences

ARGS = {
    'data': {
        'sentences1': [
            [1, 2, 3],           # id=0, length 3
            [1, 2],              # id=1, length 2
            [1, 2, 3, 4],        # id=2, length 4
            [1],                 # id=3, length 1
        ],
        'sentences2': [
            [5, 6],              # id=0, length 2
            [5, 6, 7, 8, 9],     # id=1, length 5
            [5],                 # id=2, length 1
            [5, 6, 7],           # id=3, length 3
        ],
        'targets': [0, 1, 0, 1],
    },
    'order': ('sentences1', 'sentences2'),
    'structure': (2, [3]),
}
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 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
is_atom Ran
ran on a synthesized input
uclnlp/ntp/ntp/util.py
code served (permissive licence) · get_code("08da9620aade33aa")
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 bool, ndim 0, dtype family float, shape () 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 collections
import torch

Atom = collections.namedtuple('Atom', ['predicate', 'arguments'])

def is_atom(arg):
    return isinstance(arg, Atom)

# Test case 1: Valid Atom instance
atom_instance = Atom(predicate='loves', arguments=['alice', 'bob'])

# Test case 2: Non-Atom object (string)
non_atom_string = "not an atom"

# Test case 3: Non-Atom object (dict)
non_atom_dict = {'predicate': 'loves', 'arguments': ['alice', 'bob']}

# Test case 4: Non-Atom object (None)
non_atom_none = None

# Test case 5: Non-Atom object (tensor)
torch.manual_seed(0)
non_atom_tensor = torch.randn(2, 4)

ARGS = {
    'arg': atom_instance
}
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 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
is_tensor Ran
ran on a synthesized input
uclnlp/ntp/ntp/prover.py
code served (permissive licence) · get_code("86a13149d6073483")
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 bool, ndim 0, dtype family float, shape () 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

# The function is_tensor checks if an argument is an instance of tf.Tensor
# It has one parameter: arg
# We need to provide a value that will be checked

# Create a simple TensorFlow tensor
tensor_arg = tf.constant([[1.0, 2.0, 3.0, 4.0],
                          [5.0, 6.0, 7.0, 8.0]])

ARGS = {
    "arg": tensor_arg
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
tensorflow — 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
is_variable Ran
ran on a synthesized input
uclnlp/ntp/ntp/tp.py
code served (permissive licence) · get_code("35f3db77164bbce5")
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 bool, ndim 0, dtype family float, shape () 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 torch
import numpy as np

torch.manual_seed(0)

ARGS = {
    'arg': 'UPPERCASE_STRING'
}
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 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
kb_ids2known_facts Ran
ran on a synthesized input
uclnlp/ntp/ntp/experiments/recover.py
code served (permissive licence) · get_code("7aff3f773673f361")
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 set. 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)

# Analyze the function:
# - kb_ids is a dict where:
#   - keys are struct names (arbitrary strings)
#   - values are tuples/lists where first element [0] is "arrays"
#   - arrays is a list of array-like objects
#   - each array has length num_facts
#   - we iterate through num_facts and collect x[i] for each x in arrays

# Create a valid kb_ids structure
kb_ids = {
    "struct_1": (
        [
            np.array([1, 2, 3]),           # first array: 3 facts
            np.array([10, 20, 30]),        # second array: 3 facts
            np.array([100, 200, 300])      # third array: 3 facts
        ],
    ),
    "struct_2": (
        [
            np.array([4, 5]),              # first array: 2 facts
            np.array([40, 50]),            # second array: 2 facts
        ],
    )
}

ARGS = {
    "kb_ids": kb_ids
}
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 set — a set output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a set 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
load_random_state Ran
ran on a synthesized input
uclnlp/gntp/bin/gntp-cli.py
code served (permissive licence) · get_code("b0f8f95117e6f32b")
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 os
import sys
import pickle
import tempfile
import shutil

# Create a temporary directory to serve as checkpoint path
temp_dir = tempfile.mkdtemp()

# Create a valid random state pickle file
random_state = {
    'numpy_random': 42,
    'python_random': 123,
    'torch_random': 456
}
random_state_path = os.path.join(temp_dir, 'random_state.pickle')
with open(random_state_path, 'wb') as f:
    pickle.dump(random_state, f)

ARGS = {
    '_checkpoint_path': temp_dir
}
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
read_mentions Ran
ran on a synthesized input
uclnlp/gntp/gntp/io.py
code served (permissive licence) · get_code("fd3cdc689950a17a")
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 tempfile
import os

# Create a temporary file with test data in the expected format
temp_file = tempfile.NamedTemporaryFile(mode='w', delete=False, suffix='.txt')
temp_file.write("subject1\tmentions\tobject1\t5\n")
temp_file.write("subject2\tpredicate\tobject2\t10\n")
temp_file.write("subject3\trelation\tobject3\t3\n")
temp_file.close()

ARGS = {
    'path': 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 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
rep2string Ran
ran on a synthesized input
uclnlp/ntp/ntp/prover.py
code served (permissive licence) · get_code("1d05c029e1a88874")
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
from unittest.mock import Mock

torch.manual_seed(0)

# Create a mock tensor object with a get_shape() method
# The function calls tensor.get_shape() and accesses indices [0] and potentially iterates
mock_tensor = Mock()
mock_tensor.get_shape.return_value = [2, 4]

ARGS = {
    'tensor': mock_tensor,
    'color': 'magenta',
    'show_second_dim': False
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
termcolor, 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
trim Ran
ran on a synthesized input
uclnlp/ntp/ntp/util.py
code served (permissive licence) · get_code("b6b34a3aaa5bb4e9")
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 re

def trim(string):
    """
    :param string: an input string
    :return: the string without trailing whitespaces
    """
    return re.sub('\\A\\s+|\\s+\\Z', '', string)


ARGS = {
    'string': '   hello world   '
}
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 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
bilstm_nosupport_reader_model_with_cands Not yet run
unverified (harvested, no recorded run)
uclnlp/ntp/ntp/jtr/nn/models.py
code served (permissive licence) · get_code("9a713eefc8e66051")
How it ran

no invocation recorded.

bilstm_reader_model_with_cands Not yet run
unverified (harvested, no recorded run)
uclnlp/ntp/ntp/jtr/nn/models.py
code served (permissive licence) · get_code("19db131ea10b3837")
How it ran

no invocation recorded.

boe_nosupport_cands_reader_model Not yet run
unverified (harvested, no recorded run)
uclnlp/ntp/ntp/jtr/nn/models.py
code served (permissive licence) · get_code("a3b949dcebbfa464")
How it ran

no invocation recorded.

diff_k_max_grad Not yet run
unverified (harvested, no recorded run)
uclnlp/ntp/ntp/kmax.py
code served (permissive licence) · get_code("16b7fa57446bec19")
How it ran

no invocation recorded.

iopen Not yet run
unverified (harvested, no recorded run)
uclnlp/gntp/gntp/io.py
code served (permissive licence) · get_code("805c610d7342febb")
How it ran

no invocation recorded.

is_variables_list Not yet run
unverified (harvested, no recorded run)
uclnlp/ntp/ntp/prover.py
code served (permissive licence) · get_code("ebf7f09a2e38dd00")
How it ran

no invocation recorded.

logistic_loss Not yet run
unverified (harvested, no recorded run)
uclnlp/gntp/gntp/losses.py
code served (permissive licence) · get_code("23981ea194ca5abd")
How it ran

no invocation recorded.

my_py_func Not yet run
unverified (harvested, no recorded run)
uclnlp/ntp/ntp/kmax.py
code served (permissive licence) · get_code("8025ce61959161a4")
How it ran

no invocation recorded.

read_triples Not yet run
unverified (harvested, no recorded run)
uclnlp/gntp/gntp/io.py
code served (permissive licence) · get_code("e918b6b61c80d29b")
How it ran

no invocation recorded.

representation_match Not yet run
unverified (harvested, no recorded run)
uclnlp/ntp/ntp/nunify.py
code served (permissive licence) · get_code("68763b0b0695fd72")
How it ran

no invocation recorded.

sparse_softmax Not yet run
unverified (harvested, no recorded run)
uclnlp/gntp/gntp/attention.py
code served (permissive licence) · get_code("a1c7a129b1ccd13a")
How it ran

no invocation recorded.

Also present in other papers' code

Of 26 samples lifted from this paper's linked repositories, 26 carry a function identity and 0 do not. Of the 26 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 26 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-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

Reasoning with knowledge expressed in natural language and Knowledge Bases (KBs) is a major challenge for Artificial Intelligence, with applications in machine reading, dialogue, and question answering. General neural architectures that jointly learn representations and transformations of text are very data-inefficient, and it is hard to analyse their reasoning process. These issues are addressed by end-to-end differentiable reasoning systems such as Neural Theorem Provers (NTPs), although they can only be used with small-scale symbolic KBs. In this paper we first propose Greedy NTPs (GNTPs), an extension to NTPs addressing their complexity and scalability limitations, thus making them applicable to real-world datasets. This result is achieved by dynamically constructing the computation graph of NTPs and including only the most promising proof paths during inference, thus obtaining orders of magnitude more efficient models. Then, we propose a novel approach for jointly reasoning over KBs and textual mentions, by embedding logic facts and natural language sentences in a shared embedding space. We show that GNTPs perform on par with NTPs at a fraction of their cost while achieving competitive link prediction results on large datasets, providing explanations for predictions, and inducing interpretable models. Source code, datasets, and supplementary material are available online at https://github.com/uclnlp/gntp.

For agents

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

get_harvested_code_for_paper("1912.10824")
get_code_for_paper("1912.10824")
have("1912.10824")

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

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

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

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

Connect an agent — have() is free.