SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2004.14923 · EMNLP · 2020

Bridging Linguistic Typology and Multilingual Machine Translation with Multi-View Language Representations

Barry Haddow, Alexandra Birch, Arturo Oncevay

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/2004.14923.json · badge: /api/ran/2004.14923.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
aoncevay/multiview-langrep canonical (classifier label)
classifier basis: census
5 ran · 1 no recorded run
FunctionStatusWhere it lives
generate_list Ran
ran on a synthesized input
aoncevay/multiview-langrep/clustering_analysis.py
code served (permissive licence) · get_code("aea10d9dbc1f11ab")
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

torch.manual_seed(0)

ARGS = {
    'ths': [0.5, 0.7, 0.3]
}
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 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
inertia_score Ran
ran on a synthesized input
aoncevay/multiview-langrep/src/utils.py
code served (permissive licence) · get_code("02e371816992267d")
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 float64, ndim 0, 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 dataset
np.random.seed(0)
X = np.random.randn(6, 4)  # 6 samples, 4 features

# Create cluster assignments (predictions)
# 3 samples assigned to cluster 0, 2 to cluster 1, 1 to cluster 2
a = np.array([0, 0, 0, 1, 1, 2])

ARGS = {
    'X': X,
    'a': a,
    'metric': 'euclidean'
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, sklearn — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type float64, ndim 0, dtype family float — no output shape is stated: observe_signature.py recorded float ndim 0, which disagrees with the fixture run
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
linkage_matrix Ran
ran on a synthesized input
aoncevay/multiview-langrep/src/utils.py
code served (permissive licence) · get_code("36b1c1d2f1220a50")
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. 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 numpy as np

# Set random seed for reproducibility
np.random.seed(0)

# Create a small sample data matrix X
# Shape: (5, 3) - 5 samples, 3 features
X = np.array([
    [0.1, 0.2, 0.3],
    [0.15, 0.25, 0.35],
    [5.0, 5.1, 5.2],
    [5.05, 5.15, 5.25],
    [10.0, 10.1, 10.2]
], dtype=np.float64)

ARGS = {
    'X': X,
    'method': 'ward',
    'metric': 'euclidean'
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, scipy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple — a tuple 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
multiview_langrep Ran
ran on a synthesized input
aoncevay/multiview-langrep/multiview_langrep.py
code served (permissive licence) · get_code("543dd32919b6af87")
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 numpy as np
from unittest.mock import Mock, MagicMock, patch

# Mock the src modules since they're not available
class MockLangSpaceSingle:
    def __init__(self, space_name=None, source_name=None):
        self.space_name = space_name
        self.source_name = source_name
    
    def get_X_dict(self, list_langs, svd_th=None):
        # Return a dict with language embeddings
        if list_langs is None:
            return {'eng': np.random.rand(10, 8), 'spa': np.random.rand(10, 8)}
        else:
            return {lang: np.random.rand(10, 8) for lang in list_langs}
    
    def getSourceName(self):
        return self.source_name

class MockLangSpaceMulti:
    def __init__(self, name=None, space_1=None, space_2=None):
        self.name = name
        self.space_1 = space_1
        self.space_2 = space_2
    
    def get_X_cca_any(self, list_langs, svd_th=None, candidates=None):
        # Return a dict with CCA embeddings
        if list_langs is None:
            return {'eng': np.random.rand(10, 8), 'spa': np.random.rand(10, 8)}
        else:
            return {lang: np.random.rand(10, 8) for lang in list_langs}

# Patch the imports
import sys
mock_src = MagicMock()
mock_src.LangSpaceMulti = MockLangSpaceMulti
mock_src.LangSpaceSingle = MockLangSpaceSingle
sys.modules['src'] = mock_src
sys.modules['src.LangSpaceMulti'] = mock_src
sys.modules['src.LangSpaceSingle'] = mock_src

ARGS = {
    'list_langs': 'eng,spa,fra',
    'source_uriel': 'syntax_knn',
    'source_learn': 'ted53',
    'path_learn': None,
    'ths': [0.65, 0.6],
    'out_name': None
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, src — 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
svd_transform Ran
ran on a synthesized input
aoncevay/multiview-langrep/src/utils.py
code served (permissive licence) · get_code("02f8621ce672ab5b")
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. 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 numpy as np
from sklearn.decomposition import TruncatedSVD, PCA

# Create a small sample matrix for X
# Shape: (2, 4) - 2 samples, 4 features
# n_components will be n = X.shape[1] - 1 = 3
X = np.random.randn(2, 4).astype(np.float32)

ARGS = {
    'X': X,
    'mode': 'truncated'
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, sklearn — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple — a tuple 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
compose_feats_matrix Not yet run
unverified (harvested, no recorded run)
aoncevay/multiview-langrep/src/compose_matrix.py
code served (permissive licence) · get_code("35d992b5a786d6c3")
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

Sparse language vectors from linguistic typology databases and learned embeddings from tasks like multilingual machine translation have been investigated in isolation, without analysing how they could benefit from each other's language characterisation. We propose to fuse both views using singular vector canonical correlation analysis and study what kind of information is induced from each source. By inferring typological features and language phylogenies, we observe that our representations embed typology and strengthen correlations with language relationships. We then take advantage of our multi-view language vector space for multilingual machine translation, where we achieve competitive overall translation accuracy in tasks that require information about language similarities, such as language clustering and ranking candidates for multilingual transfer. With our method, which is also released as a tool, we can easily project and assess new languages without expensive retraining of massive multilingual or ranking models, which are major disadvantages of related approaches.

For agents

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

get_harvested_code_for_paper("2004.14923")
get_code_for_paper("2004.14923")
have("2004.14923")

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

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

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

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

Connect an agent — have() is free.