SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 1504.00548 · 2015

Learning to Understand Phrases by Embedding the Dictionary

arXiv · PDF · Open in the Atlas

Code that ran

5 of 6 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (0 of them constructed an object rather than computing a result; 0 honoured the contract we drafted, 0 violated it and 5 have no contract verdict; 0 failures of our instrument; 1 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/1504.00548.json · badge: /api/ran/1504.00548.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
thunlp/MultiRD canonical (classifier label)
classifier basis: census
5 ran · 1 no recorded run
FunctionStatusWhere it lives
build_sentence_numpy Ran
ran on a synthesized input
thunlp/MultiRD/ChineseReverseDictionary/code/data.py
code served (permissive licence) · get_code("189bc681f75922bb")
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 ndarray, ndim 2, dtype family int, shape (3, 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 numpy as np

# Build valid arguments for build_sentence_numpy
# The function expects a list of sentences where each sentence is a list/array of integers
# It will pad them to the max length

sentence1 = [1, 2, 3]
sentence2 = [4, 5]
sentence3 = [6, 7, 8, 9]

sentences = [sentence1, sentence2, sentence3]

ARGS = {
    "sentences": sentences
}
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 ndarray, ndim 2, dtype family int, shape (3, 4) — shape (3, 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
evaluate Ran
ran on a synthesized input
thunlp/MultiRD/ChineseReverseDictionary/code/evaluate.py
code served (permissive licence) · get_code("097ad2cea688e3d9")
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)

# Analyzing the function:
# - ground_truth: list/sequence where each element is checked with 'in' operator
# - prediction: list/sequence where each element is indexable (supports [:100], [:10], [0])
#   and supports 'in' operator for membership checking
# - Both have same length

# ground_truth[i] appears to be a single element (compared with ==)
# prediction[i] appears to be a sequence/list that can be sliced and checked for membership

# Create minimal test data
ground_truth = ["apple", "banana", "cherry"]
prediction = [
    ["apple", "grape", "orange", "kiwi", "mango"],  # apple is in this list
    ["banana", "peach", "plum"],  # banana is at index 0
    ["date", "fig", "cherry", "cherry"]  # cherry is in this list but not at [0]
]

ARGS = {
    "ground_truth": ground_truth,
    "prediction": prediction
}
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
evaluate_test Ran
ran on a synthesized input
thunlp/MultiRD/ChineseReverseDictionary/code/evaluate.py
code served (permissive licence) · get_code("f4ccf34f650ff227")
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

# Analyze the function:
# - ground_truth: a list/sequence where each element can be compared with ==
# - prediction: a list/sequence where each element is indexable (has [:] notation)
#   and supports .index() method, suggesting it's a list of lists
# - The function checks if ground_truth[i] is in prediction[i][:100], [:10], [0]
# - It calls .index() on prediction[i][:], which returns an integer rank

# Create sample data
ground_truth = ['apple', 'banana', 'cherry', 'date']

# prediction should be a list of lists, where each inner list contains
# ranked predictions (strings that match the ground_truth items)
prediction = [
    ['apple', 'banana', 'orange', 'grape', 'kiwi'],  # ground_truth[0]='apple' is at index 0
    ['pear', 'banana', 'cherry', 'date'],             # ground_truth[1]='banana' is at index 1
    ['cherry', 'apple', 'banana', 'mango'],           # ground_truth[2]='cherry' is at index 0
    ['date', 'fig', 'grape', 'honeydew'],             # ground_truth[3]='date' is at index 0
]

ARGS = {
    'ground_truth': ground_truth,
    'prediction': prediction
}
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
label_multihot Ran
ran on a synthesized input
thunlp/MultiRD/ChineseReverseDictionary/code/data.py
code served (permissive licence) · get_code("fb19e15c86dfad22")
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 ndarray, 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 numpy as np

# Construct arguments for label_multihot function
# The function takes:
# - labels: list of lists/iterables of label indices
# - num: integer specifying the number of classes (width of output matrix)

# Create a small example with batch size 2, num classes 4
labels = [
    [0, 2],      # First sample has labels at indices 0 and 2
    [1, 3, 2]    # Second sample has labels at indices 1, 3, and 2
]

num = 4

ARGS = {
    "labels": labels,
    "num": num
}
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 ndarray, 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
load_filterlist Ran
ran on a synthesized input
thunlp/MultiRD/PrepareYourOwnDataset/get_wordnet_500sample.py
code served (permissive licence) · get_code("26f1ce7a3aef5a8e")
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 tempfile
import os

# Create a temporary file with filter data
temp_dir = tempfile.mkdtemp()
temp_file = os.path.join(temp_dir, "filterlist.txt")

# Write sample filter data to the file
filter_data = ["filter1", "filter2", "filter3", "duplicate_filter", "another_filter"]
with open(temp_file, 'w') as f:
    f.write('\n'.join(filter_data))

ARGS = {
    "path": temp_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 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_data Not yet run
unverified (harvested, no recorded run)
thunlp/MultiRD/ChineseReverseDictionary/code/data.py
code served (permissive licence) · get_code("938c2f50b779ab0f")
How it ran

no invocation recorded.

Also present in other papers' code

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

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

Distributional models that learn rich semantic word representations are a success story of recent NLP research. However, developing models that learn useful representations of phrases and sentences has proved far harder. We propose using the definitions found in everyday dictionaries as a means of bridging this gap between lexical and phrasal semantics. Neural language embedding models can be effectively trained to map dictionary definitions (phrases) to (lexical) representations of the words defined by those definitions. We present two applications of these architectures: "reverse dictionaries" that return the name of a concept given a definition or description and general-knowledge crossword question answerers. On both tasks, neural language embedding models trained on definitions from a handful of freely-available lexical resources perform as well or better than existing commercial systems that rely on significant task-specific engineering. The results highlight the effectiveness of both neural embedding architectures and definition-based training for developing models that understand phrases and sentences.

For agents

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

get_harvested_code_for_paper("1504.00548")
get_code_for_paper("1504.00548")
have("1504.00548")

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

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

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

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

Connect an agent — have() is free.