SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2205.09224 · 2022

Entailment Tree Explanations via Iterative Retrieval-Generation Reasoner

arXiv · PDF · Open in the Atlas

Code that ran

17 of 19 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; 2 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/2205.09224.json · badge: /api/ran/2205.09224.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
amazon-research/irgr canonical (classifier label)
classifier basis not recorded on the link
17 ran · 2 no recorded run
FunctionStatusWhere it lives
convert_datapoint_to_sent_to_text Ran
ran on a synthesized input
amazon-research/irgr/src/retrieval_utils.py
code served (permissive licence) · get_code("74453f96447f48f6")
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 re
from collections import Counter

# Construct a valid datapoint with context containing sentences
datapoint = {
    'context': 'sent1: leo is a kind of constellation sent2: it is located in the northern hemisphere sent3: many stars make up this pattern'
}

ARGS = {
    'datapoint': datapoint
}
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
count_phrase_matches Ran
ran on a synthesized input
amazon-research/irgr/src/entailment_bank/utils/entail_trees_utils.py
code served (permissive licence) · get_code("44b66cb0347665db")
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 int, ndim 0, dtype family int, 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 re

def count_phrase_matches(phrase, reference):
    regex = '(\\b|(?!\\w))' + re.escape(phrase) + '((?<!\\w)|\\b)'
    return len(re.findall(regex, reference))

# Setup valid arguments
phrase = "hello"
reference = "hello world, hello there! hello-friend and hello_user"

ARGS = {
    "phrase": phrase,
    "reference": reference
}
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 int, ndim 0, dtype family int, 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
create_sentence_uuid_map_from_corpus Ran
ran on a synthesized input
amazon-research/irgr/src/retrieval_utils.py
code served (permissive licence) · get_code("42c325aaed66dd65")
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.

import json
import tempfile
import os

# Create a temporary file with valid JSON content for the world_tree_file
temp_file = tempfile.NamedTemporaryFile(mode='w', delete=False, suffix='.json')
temp_file_path = temp_file.name

# Create sample data: a dictionary mapping UUIDs to sentences
sample_uuid_to_sent = {
    "uuid-001": "The quick brown fox jumps over the lazy dog",
    "uuid-002": "Hello world, this is a test sentence!",
    "uuid-003": "Python programming is fun and useful"
}

# Write the JSON data to the temporary file
json.dump(sample_uuid_to_sent, temp_file)
temp_file.close()

ARGS = {
    'world_tree_file': temp_file_path
}
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
get_results_file_path Ran
ran on a synthesized input
amazon-research/irgr/src/base_utils.py
code served (permissive licence) · get_code("cf21a7d00a46e668")
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
import numpy as np
from collections import namedtuple

class ParamsStandIn:
    def __init__(self):
        self.results_file_path = 'results/{model_name}_{task_name}_{dataset_name}_{approach_name}{suffix}.{extension}'
        self.model_name = 'bert'
        self.task_name = 'classification'
        self.dataset_name = 'mnist'
        self.approach_name = 'baseline'

params = ParamsStandIn()

ARGS = {
    'params': params,
    'test_split': False,
    'result_only': False,
    'temp': False,
    'uuid': 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 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
load_jsonl Ran
ran on a synthesized input
amazon-research/irgr/src/entailment_bank/utils/angle_utils.py
code served (permissive licence) · get_code("c30d329a797e15bd")
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.

import json
import tempfile
import os

# Create a temporary JSONL file with valid test data
temp_dir = tempfile.mkdtemp()
test_file = os.path.join(temp_dir, "test.jsonl")

# Write some valid JSONL data
test_data = [
    {"id": 1, "text": "hello world"},
    {"id": 2, "text": "foo bar"},
    {"id": 3, "name": "test", "value": 42}
]

with open(test_file, 'w') as f:
    for item in test_data:
        f.write(json.dumps(item) + '\n')

ARGS = {
    "file_name": test_file
}
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_slot_data_by_id Ran
ran on a synthesized input
amazon-research/irgr/src/entailment_bank/utils/eval_utils.py
code served (permissive licence) · get_code("51014481762b0d1b")
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 json
import tempfile
import os

# Create a temporary file with JSON lines containing slot data
temp_file = tempfile.NamedTemporaryFile(mode='w', delete=False, suffix='.jsonl')
try:
    # Write some sample slot data
    slot_data = [
        {'id': 'slot_1', 'name': 'slot_a', 'value': 100},
        {'id': 'slot_2', 'name': 'slot_b', 'value': 200},
        {'id': 'slot_3', 'name': 'slot_c', 'value': 300},
    ]
    for item in slot_data:
        temp_file.write(json.dumps(item) + '\n')
    temp_file.close()
    
    slot_file_path = temp_file.name
    
    ARGS = {
        'slot_file': slot_file_path
    }
finally:
    # Note: temp file will persist for the function to read
    pass
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
parse_lisp Ran
ran on a synthesized input
amazon-research/irgr/src/entailment_bank/utils/proof_utils.py
code served (permissive licence) · get_code("970c22892bfbf76b")
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 re

def parse_lisp(input_string, token_map=None):
    token_regex = re.compile('(->|[a-zA-Z0-9%@^]+|\\S)')
    tokens = token_regex.findall(input_string)
    if token_map is not None:
        tokens = [token_map.get(x, x) for x in tokens]
    return parse_lisp_tokens(tokens)

def parse_lisp_tokens(tokens):
    res = []
    i = 0
    while i < len(tokens):
        symbol = tokens[i]
        if symbol == '(':
            sub_list = []
            depth = 1
            while depth > 0:
                i += 1
                if i >= len(tokens):
                    raise ValueError('Invalid input: Unmatched open parenthesis.')
                symbol = tokens[i]
                if symbol == '(':
                    depth += 1
                elif symbol == ')':
                    depth -= 1
                if depth > 0:
                    sub_list.append(symbol)
            res.append(parse_lisp_tokens(sub_list))
        elif symbol == ')':
            raise ValueError('Invalid input: Unmatched close parenthesis.')
        else:
            res.append(symbol)
        i += 1
    return res

# Test case 1: Simple string with nested parentheses
input_string_1 = "(+ 1 2)"
token_map_1 = None

# Test case 2: String with token mapping
input_string_2 = "(func a b)"
token_map_2 = {"func": "->", "a": "x", "b": "y"}

# Test case 3: More complex nested structure
input_string_3 = "(+ (* 2 3) (- 5 1))"
token_map_3 = None

ARGS = {
    "input_string": "(+ 1 2)",
    "token_map": 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 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
parse_lisp_tokens Ran
ran on a synthesized input
amazon-research/irgr/src/entailment_bank/utils/proof_utils.py
code served (permissive licence) · get_code("af3e6075f5840574")
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.

# Setup code for parse_lisp_tokens

ARGS = {
    'tokens': ['(', 'define', 'x', '5', ')', 'y', '(', '+', '1', '2', ')']
}
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
recursive_polish_notation Ran
ran on a synthesized input
amazon-research/irgr/src/entailment_bank/utils/proof_utils.py
code served (permissive licence) · get_code("b015b685dfa43094")
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.

# Setup code for recursive_polish_notation function

SYMBOL_DICT = {'->': '#', 'and': '&'}

def dedupe(data):
    res = []
    for d in data:
        if d not in res:
            res.append(d)
    return res

def recursive_polish_notation(proof_list):
    res = []
    if isinstance(proof_list, str):
        res.append(proof_list)
        return res
    if len(proof_list) == 3 and proof_list[1] == '->':
        res.append(SYMBOL_DICT['->'])
        res += recursive_polish_notation(proof_list[2])
        res += recursive_polish_notation(proof_list[0])
        return res
    proof_list = dedupe(proof_list)
    if len(proof_list) == 1:
        res += recursive_polish_notation(proof_list[0])
    elif len(proof_list) == 2:
        res.append(SYMBOL_DICT['and'])
        res += recursive_polish_notation(proof_list[0])
        res += recursive_polish_notation(proof_list[1])
    elif len(proof_list) > 2:
        res.append(SYMBOL_DICT['and'])
        res += recursive_polish_notation(proof_list[0])
        res += recursive_polish_notation(proof_list[1:])
    else:
        raise ValueError('Empty list found')
    return res

# Test case 1: Simple string input
test_input_1 = "A"

# Test case 2: Implication structure [A, '->', B]
test_input_2 = ["A", "->", "B"]

# Test case 3: List with multiple elements (and structure)
test_input_3 = ["A", "B", "C"]

# Test case 4: Nested structure with implication
test_input_4 = [["A", "->", "B"], "->", "C"]

# Test case 5: List with duplicates that will be deduplicated
test_input_5 = ["A", "B", "A"]

ARGS = {
    'proof_list': test_input_2
}
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
replace_punctuation Ran
ran; our contract draft was wrong, not the code
amazon-research/irgr/src/entailment_bank/utils/eval_utils.py
code served (permissive licence) · get_code("d2166ef001a9e416")
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 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
import numpy as np

torch.manual_seed(0)

ARGS = {
    "str": 'Hello "world" and \'test\' string'
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
numpy, 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
score_string_similarity Ran
ran on a synthesized input
amazon-research/irgr/src/entailment_bank/utils/eval_utils.py
code served (permissive licence) · get_code("00139853f0c3a89e")
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 float, 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 re

T5_GOOD_CHARS = [32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 93, 95, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 124, 163, 171, 173, 174, 176, 187, 201, 206, 220, 223, 224, 225, 226, 228, 231, 232, 233, 234, 238, 243, 244, 246, 249, 251, 252, 259, 351, 355, 537, 539, 1072, 1074, 1076, 1077, 1080, 1082, 1083, 1084, 1085, 1086, 1088, 1089, 1090, 1091, 8211, 8212, 8216, 8217, 8220, 8221, 8222, 8226, 8242, 8364, 9601]

T5_BAD_REGEX = re.compile('[^' + re.escape('.'.join([chr(x) for x in T5_GOOD_CHARS])) + ']')

def fix_t5_unk_characters(str):
    return re.sub(' {2,}', ' ', re.sub(T5_BAD_REGEX, ' ', str))

def score_string_similarity(str1, str2):
    if str1 == str2:
        return 3.0
    str1 = fix_t5_unk_characters(str1)
    str2 = fix_t5_unk_characters(str2)
    if str1 == str2:
        return 2.0
    str1 = str1.lower()
    str2 = str2.lower()
    if str1 == str2:
        return 1.5
    if ' ' in str1 or ' ' in str2:
        str1_split = str1.split(' ')
        str2_split = str2.split(' ')
        overlap = list(set(str1_split) & set(str2_split))
        return len(overlap) / max(len(str1_split), len(str2_split))
    else:
        return 0.0

ARGS = {
    "str1": "Hello world test",
    "str2": "Hello world example"
}
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 float, 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
sent_text_as_counter Ran
ran on a synthesized input
amazon-research/irgr/src/retrieval_utils.py
code served (permissive licence) · get_code("68ef7c2586529325")
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 Counter. 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
from collections import Counter

ARGS = {
    "text": "Hello world! This is a test. How are you? I'm doing great."
}
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 Counter — a Counter output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Counter 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
sentence_index Ran
ran on a synthesized input
amazon-research/irgr/src/entailment_bank/utils/entail_trees_utils.py
code served (permissive licence) · get_code("8f025f3f4d630f9a")
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 int, ndim 0, dtype family int, 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)

def sentence_index(sentence_id):
    return int(sentence_id.replace('sent', ''))

ARGS = {
    'sentence_id': 'sent42'
}
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 int, ndim 0, dtype family int, 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
sort_sentence_ids_match Ran
ran on a synthesized input
amazon-research/irgr/src/entailment_bank/utils/entail_trees_utils.py
code served (permissive licence) · get_code("bc66cae80c3a0886")
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

class MockMatch:
    def __init__(self, text):
        self.text = text
    
    def group(self, index):
        return self.text

ARGS = {
    'match': MockMatch('sent3 & sent1 & sent2')
}
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
split_info_sentences Ran
ran on a synthesized input
amazon-research/irgr/src/entailment_bank/eval/run_scorer.py
code served (permissive licence) · get_code("110b38cab88d9900")
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 re

def split_info_sentences(context):
    words_list = context.split(' ')
    sentence_ids = re.findall('[\\w\\.]+[0-9]+:', context)
    sentence_dict = dict()
    prev_sid = ''
    prev_sentence_parts = []
    for word in words_list:
        if word in sentence_ids:
            if prev_sid:
                sentence_dict[prev_sid] = ' '.join(prev_sentence_parts)
                prev_sentence_parts = []
            prev_sid = word
        else:
            prev_sentence_parts.append(word)
    if prev_sid:
        sentence_dict[prev_sid] = ' '.join(prev_sentence_parts)
    return sentence_dict


# The function takes a context string and parses it
# It looks for sentence IDs (pattern: word characters/dots followed by digits and colon)
# and groups subsequent words into those sentence IDs

context = "sent1: this is the first sentence sent2: this is the second sentence"

ARGS = {
    "context": context
}
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
str_replace_single_pass Ran
ran on a synthesized input
amazon-research/irgr/src/base_utils.py
code served (permissive licence) · get_code("fff8963152d95bfe")
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 str_replace_single_pass(string, substitutions):
    """
    A Python function that does multiple string replace ops in a single pass.
    E.g. substitutions = {"foo": "FOO", "bar": "BAR"}
    """
    substrings = sorted(substitutions, key=len, reverse=True)
    regex = re.compile('|'.join(map(re.escape, substrings)))
    return regex.sub(lambda match: substitutions[match.group(0)], string)


ARGS = {
    "string": "hello world foo bar",
    "substitutions": {"foo": "FOO", "bar": "BAR", "hello": "HELLO"}
}
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
trim_batch Ran
ran; our contract draft was wrong, not the code
amazon-research/irgr/src/entailment_bank/utils/angle_utils.py
pointer only (licence: Apache-2.0); the stored copy get_code serves, from Sahandfer/CEM, is pointer only (licence: NONE) · get_code("eeb8dc60c6ef1fa4")
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 Sahandfer/CEM, 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.

encode_line Not yet run
unverified (harvested, no recorded run)
amazon-research/irgr/src/entailment_bank/utils/angle_utils.py
code served (permissive licence) · get_code("ab5d9464aeabf9fd")
How it ran

no invocation recorded.

run_funtion_redirect_stdout Not yet run
unverified (harvested, no recorded run)
amazon-research/irgr/src/base_utils.py
code served (permissive licence) · get_code("de7e75f07bfecdb0")
How it ran

no invocation recorded.

Also present in other papers' code

Of 19 samples lifted from this paper's linked repositories, 19 carry a function identity and 0 do not. Of the 19 distinct functions with an identity, 13 are also present in other papers whose code we hold (13 with at least one paper dated earlier, 0 the same month, 2 later) and 6 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
trim_batch 9 other papers
5 dated earlier, 4 later
2005.01107 (2020-05)
Simplifying Paragraph-level Question Generation via Transformer Language Models
2104.08661 (2021-04)
Explaining Answers with Entailment Trees
2108.02866 (2021-08)
Dual Reader-Parser on Hybrid Textual and Tabular Evidence for Open Domain Question Answering
and 6 more not named here
encode_line 4 other papers
2 dated earlier, 2 later
2104.08661 (2021-04)
Explaining Answers with Entailment Trees
2109.12595 (2021-09)
MultiDoc2Dial: Modeling Dialogues Grounded in Multiple Documents
2023.findings-acl.743 (2023 (year only))
KORC: Knowledge oriented Reading Comprehension Benchmark for Deep Text Understanding
and 1 more not named here
replace_punctuation 3 other papers
3 dated earlier
2104.08661 (2021-04)
Explaining Answers with Entailment Trees
2202.12359 (2022-02)
UnifiedQA-v2: Stronger Generalization via Broader Cross-Format Training
2203.07540 (2022-03)
SCIENCEWORLD: Is your Agent Smarter than a 5 th Grader?
load_jsonl 2 other papers
2 dated earlier
2104.08661 (2021-04)
Explaining Answers with Entailment Trees
2203.07540 (2022-03)
SCIENCEWORLD: Is your Agent Smarter than a 5 th Grader?
score_string_similarity 2 other papers
2 dated earlier
2104.08661 (2021-04)
Explaining Answers with Entailment Trees
2203.07540 (2022-03)
SCIENCEWORLD: Is your Agent Smarter than a 5 th Grader?
count_phrase_matches 1 other paper
1 dated earlier
2104.08661 (2021-04)
Explaining Answers with Entailment Trees
load_slot_data_by_id 1 other paper
1 dated earlier
2104.08661 (2021-04)
Explaining Answers with Entailment Trees
parse_lisp 1 other paper
1 dated earlier
2104.08661 (2021-04)
Explaining Answers with Entailment Trees
parse_lisp_tokens 1 other paper
1 dated earlier
2104.08661 (2021-04)
Explaining Answers with Entailment Trees
recursive_polish_notation 1 other paper
1 dated earlier
2104.08661 (2021-04)
Explaining Answers with Entailment Trees
sentence_index 1 other paper
1 dated earlier
2104.08661 (2021-04)
Explaining Answers with Entailment Trees
sort_sentence_ids_match 1 other paper
1 dated earlier
2104.08661 (2021-04)
Explaining Answers with Entailment Trees
split_info_sentences 1 other paper
1 dated earlier
2104.08661 (2021-04)
Explaining Answers with Entailment Trees

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

Large language models have achieved high performance on various question answering (QA) benchmarks, but the explainability of their output remains elusive. Structured explanations, called entailment trees, were recently suggested as a way to explain and inspect a QA system's answer. In order to better generate such entailment trees, we propose an architecture called Iterative Retrieval-Generation Reasoner (IRGR). Our model is able to explain a given hypothesis by systematically generating a step-by-step explanation from textual premises. The IRGR model iteratively searches for suitable premises, constructing a single entailment step at a time. Contrary to previous approaches, our method combines generation steps and retrieval of premises, allowing the model to leverage intermediate conclusions, and mitigating the input size limit of baseline encoder-decoder models. We conduct experiments using the EntailmentBank dataset, where we outperform existing benchmarks on premise retrieval and entailment tree generation, with around 300% gain in overall correctness.

For agents

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

get_harvested_code_for_paper("2205.09224")
get_code_for_paper("2205.09224")
have("2205.09224")

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

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

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

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

Connect an agent — have() is free.