SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2105.04663 · 2021

GSPMD: General and Scalable Parallelization for ML Computation Graphs

arXiv · PDF · Open in the Atlas

Code that ran

4 of 4 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 4 have no contract verdict; 0 failures of our instrument; 0 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/2105.04663.json · badge: /api/ran/2105.04663.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
openxla/shardy community (classifier label)
classifier basis not recorded on the link
4 ran · 0 no recorded run
FunctionStatusWhere it lives
build_schedule_rules_from_predicate Ran
ran on a synthesized input
openxla/shardy/shardy/integrations/python/jax/mpmd/pipeline.py
code served (permissive licence) · get_code("1d8b8306239cac7c")
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 dataclasses
import enum
from typing import Callable, Sequence

# Define the enums and dataclasses as given
class SplitFragmentType(enum.Enum):
    KEEP_TRANSFERRED = enum.auto()
    DROP_TRANSFERRED = enum.auto()

@dataclasses.dataclass(frozen=True)
class FragmentOrigin:
    computation_name: str
    transpose_count: int = 0

@dataclasses.dataclass(frozen=True)
class FragmentInfo:
    origins: tuple[FragmentOrigin, ...]
    stage_id: int | None = None
    call_counter: int | None = None
    split_type: SplitFragmentType | None = None
    mesh_name: str = ''

@dataclasses.dataclass(frozen=True)
class PipelineContext:
    num_meshes: int

# Create sample FragmentInfo objects
origin1 = FragmentOrigin(computation_name="comp1", transpose_count=0)
origin2 = FragmentOrigin(computation_name="comp2", transpose_count=1)
origin3 = FragmentOrigin(computation_name="comp3", transpose_count=0)

fragment_a = FragmentInfo(
    origins=(origin1,),
    stage_id=0,
    call_counter=1,
    split_type=SplitFragmentType.KEEP_TRANSFERRED,
    mesh_name="mesh0"
)

fragment_b = FragmentInfo(
    origins=(origin2,),
    stage_id=1,
    call_counter=2,
    split_type=SplitFragmentType.DROP_TRANSFERRED,
    mesh_name="mesh0"
)

fragment_c = FragmentInfo(
    origins=(origin3,),
    stage_id=2,
    call_counter=3,
    split_type=SplitFragmentType.KEEP_TRANSFERRED,
    mesh_name="mesh0"
)

fragment_infos = [fragment_a, fragment_b, fragment_c]

context = PipelineContext(num_meshes=2)

# Define a predicate that returns True if fragment a should be scheduled before b
def before_predicate(a: FragmentInfo, b: FragmentInfo, ctx: PipelineContext) -> bool:
    # Simple predicate: schedule based on stage_id if available
    if a.stage_id is not None and b.stage_id is not None:
        return a.stage_id < b.stage_id
    return False

ARGS = {
    "fragment_infos": fragment_infos,
    "context": context,
    "before_pred": before_predicate
}
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 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
fragment_origins_contain Ran
ran on a synthesized input
openxla/shardy/shardy/integrations/python/jax/mpmd/pipeline.py
code served (permissive licence) · get_code("6d7aee7b763cd773")
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 dataclasses
import enum

@dataclasses.dataclass(frozen=True)
class FragmentOrigin:
    """The origin of a fragment."""
    computation_name: str
    transpose_count: int = 0

@enum.unique
class SplitFragmentType(enum.Enum):
    """Fragment split behavior for transferred data.

  These values indicate how fragment portions handle transferred data from
  the original fragment if the fragment is split during compilation:
    - KEEP_TRANSFERRED: Fragment portion retains transferred data
    - DROP_TRANSFERRED: Fragment portion drops transferred data
    """
    KEEP_TRANSFERRED = enum.auto()
    DROP_TRANSFERRED = enum.auto()

@dataclasses.dataclass(frozen=True)
class FragmentInfo:
    """A fragment of a computation."""
    origins: tuple[FragmentOrigin, ...]
    stage_id: int | None = None
    call_counter: int | None = None
    split_type: SplitFragmentType | None = None
    mesh_name: str = ''

def fragment_origins_contain(fragment: FragmentInfo, substring: str) -> bool:
    """Checks if any computation name in fragment origins contains the substring."""
    return any((substring in origin.computation_name for origin in fragment.origins))

# Create test data
origin1 = FragmentOrigin(computation_name="matrix_multiply_op", transpose_count=0)
origin2 = FragmentOrigin(computation_name="reduce_sum_op", transpose_count=1)

fragment = FragmentInfo(
    origins=(origin1, origin2),
    stage_id=0,
    call_counter=5,
    split_type=SplitFragmentType.KEEP_TRANSFERRED,
    mesh_name="mesh_0"
)

substring = "multiply"

ARGS = {
    "fragment": fragment,
    "substring": substring
}
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
named_tensor Ran
ran on a synthesized input
openxla/shardy/shardy/integrations/python/jax/mpmd/ops.py
code served (permissive licence) · get_code("94d5543b59d9df3c")
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 ArrayImpl, 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 jax
import jax.numpy as jnp

# Create a small JAX array (tensor)
tensor = jnp.array([[1.0, 2.0, 3.0, 4.0],
                     [5.0, 6.0, 7.0, 8.0]])

# Define the name for the tensor
name = "my_named_tensor"

# Construct the arguments dictionary
ARGS = {
    "tensor": tensor,
    "name": name,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
jax — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ArrayImpl, 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
union_fragment_origins Ran
ran on a synthesized input
openxla/shardy/shardy/integrations/python/jax/mpmd/pipeline.py
code served (permissive licence) · get_code("84f1d8cb14142278")
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 dataclasses
import enum
from collections.abc import Sequence

@dataclasses.dataclass(frozen=True)
class FragmentOrigin:
    """The origin of a fragment."""
    computation_name: str
    transpose_count: int = 0

@enum.unique
class SplitFragmentType(enum.Enum):
    """Fragment split behavior for transferred data.

  These values indicate how fragment portions handle transferred data from
  the original fragment if the fragment is split during compilation:
  - KEEP_TRANSFERRED: Fragment portion retains transferred data
  - DROP_TRANSFERRED: Fragment portion drops transferred data
  """
    KEEP_TRANSFERRED = enum.auto()
    DROP_TRANSFERRED = enum.auto()

@dataclasses.dataclass(frozen=True)
class FragmentInfo:
    """A fragment of a computation."""
    origins: tuple[FragmentOrigin, ...]
    stage_id: int | None = None
    call_counter: int | None = None
    split_type: SplitFragmentType | None = None
    mesh_name: str = ''

# Create sample FragmentOrigin instances
origin_1 = FragmentOrigin(computation_name="comp_a", transpose_count=0)
origin_2 = FragmentOrigin(computation_name="comp_b", transpose_count=1)
origin_3 = FragmentOrigin(computation_name="comp_a", transpose_count=0)  # duplicate
origin_4 = FragmentOrigin(computation_name="comp_c", transpose_count=2)

# Create sample FragmentInfo instances with different origin combinations
fragment_1 = FragmentInfo(
    origins=(origin_1, origin_2),
    stage_id=0,
    call_counter=1,
    split_type=SplitFragmentType.KEEP_TRANSFERRED,
    mesh_name="mesh_0"
)

fragment_2 = FragmentInfo(
    origins=(origin_3, origin_4),
    stage_id=1,
    call_counter=2,
    split_type=SplitFragmentType.DROP_TRANSFERRED,
    mesh_name="mesh_1"
)

fragment_3 = FragmentInfo(
    origins=(origin_1,),
    stage_id=None,
    call_counter=None,
    split_type=None,
    mesh_name=""
)

# Create sequence of fragments
source_fragments = [fragment_1, fragment_2, fragment_3]

ARGS = {
    "source_fragments": source_fragments
}
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 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

Also present in other papers' code

Of 4 samples lifted from this paper's linked repositories, 4 carry a function identity and 0 do not. Of the 4 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 4 are only here among the 52,977 papers whose code Syntology holds (as of 2026-09-26).

Only here means: among the 52,977 papers whose code Syntology holds (51,887 with lifted samples, 1,090 through their assemblies only), as of 2026-09-26, no other paper's lifted samples or current assembly bricks contain an identical function body after normalisation.

Presence, not direction: an identical function body in two papers' repositories does not say who wrote it, which came from which, or that either paper's method rests on it. Matching is exact after normalisation, so a renamed or edited function is not matched. Dates are when papers appeared, not when code was written. Only .py files the harvester lifted are covered; notebooks are not read. A new-style arXiv id YYMM.NNNN dates a paper to the month 20YY-MM; otherwise Paper.year dates it to the year; otherwise it is undated. Dates are when the paper appeared, not when the code was written. Read 2026-11-22.

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

We present GSPMD, an automatic, compiler-based parallelization system for common machine learning computations. It allows users to write programs in the same way as for a single device, then give hints through a few annotations on how to distribute tensors, based on which GSPMD will parallelize the computation. Its representation of partitioning is simple yet general, allowing it to express different or mixed paradigms of parallelism on a wide variety of models. GSPMD infers the partitioning for every operator based on limited user annotations, making it convenient to scale existing single-device programs. It solves several technical challenges for production usage, allowing GSPMD to achieve 50% to 62% compute utilization on up to 2048 Cloud TPUv3 cores for models with up to one trillion parameters.

For agents

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

get_harvested_code_for_paper("2105.04663")
get_code_for_paper("2105.04663")
have("2105.04663")

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

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

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

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

Connect an agent — have() is free.