SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2605.08696 · 2026

Structured Recurrent Mixers for Massively Parallelized Sequence Generation

Benjamin Badger

arXiv · PDF · Open in the Atlas

Code that ran

8 of 11 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (8 of them constructed an object rather than computing a result; 0 honoured the contract we drafted, 0 violated it and 8 have no contract verdict; 0 failures of our instrument; 3 no recorded run), measured 2026-11-22; 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/2605.08696.json · badge: /api/ran/2605.08696.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
blbadger/lm-evaluation-harness community
Papers with Code archive
8 ran · 3 no recorded run
FunctionStatusWhere it lives
ColRepeatCausalLinear Ran
ran on a synthesized input · constructed an object; no result was computed
blbadger/lm-evaluation-harness/lm_eval/models/srm_model.py
code served (permissive licence) · get_code("bacb928cb85a8d51")
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 an instance of its own class, ColRepeatCausalLinear: the run constructed the object and did not call it, so no result was computed. 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 torch.nn as nn

torch.manual_seed(0)

class ColRepeatCausalLinear(nn.Module):

    def __init__(self, dim: int, decay=False, decay_constant=1):
        super().__init__()
        self.weight = nn.Parameter(torch.randn(1, dim))
        self.bias = nn.Parameter(torch.zeros(dim))
        if decay:
            self.decay_value = nn.Parameter(torch.ones(1))
            self.decay_constant = decay_constant
        else:
            self.decay_value = None

    def vector_to_matrix(self, v: torch.Tensor) -> torch.Tensor:
        """
        [ a  b  c  d ]
        [ 0  b  c  d ]
        [ 0  0  c  d ]
        [ 0  0  0  d ]
        """
        v = v.reshape(-1)
        m = v.shape[0]
        i, j = torch.meshgrid(torch.arange(m, device=v.device), torch.arange(m, device=v.device), indexing='ij')
        if self.decay_value is not None:
            M = torch.where(j >= i, v[j] * torch.clip(self.decay_value, min=0.9, max=1) ** ((j - i) / self.decay_constant), torch.zeros(m, m, device=v.device, dtype=v.dtype))
        else:
            M = torch.where(j >= i, v[j], torch.zeros(m, m, device=v.device, dtype=v.dtype))
        return M

    def forward(self, x: torch.Tensor) -> torch.Tensor:
        B, E, S = x.shape
        W = self.vector_to_matrix(self.weight).to(x.dtype)
        x_reshaped = x.reshape(B * E, S)
        out = x_reshaped @ W
        out = out + self.bias.to(x.dtype)
        out = out.view(B, E, S)
        return out


# Create test input: (batch=2, embedding_dim=3, sequence_length=4)
x = torch.randn(2, 3, 4)

ARGS = {
    "dim": 4,
    "decay": False,
    "decay_constant": 1,
}
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 ColRepeatCausalLinear — the run constructed an instance of its own class and did not call it; no shape is stated — the instrument coerces any output to an array; for a ColRepeatCausalLinear 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
CombinedRepeatCausalLinear Ran
ran on a synthesized input · constructed an object; no result was computed
blbadger/lm-evaluation-harness/lm_eval/models/srm_model.py
code served (permissive licence) · get_code("1c796bd7904ae352")
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 an instance of its own class, CombinedRepeatCausalLinear: the run constructed the object and did not call it, so no result was computed. 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 torch.nn as nn

torch.manual_seed(0)

# Create a simple instance of CombinedRepeatCausalLinear
dim = 4

# Test without decay
model_no_decay = nn.Module()

# Test with decay
model_with_decay = nn.Module()

# Create input tensor: (batch=2, embedding_dim=3, sequence_length=4)
x = torch.randn(2, 3, 4)

ARGS = {
    'dim': 4,
    'decay': None,
    'decay_constant': 1
}
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 CombinedRepeatCausalLinear — the run constructed an instance of its own class and did not call it; no shape is stated — the instrument coerces any output to an array; for a CombinedRepeatCausalLinear 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
HeadedRepeatCausalLinear Ran
ran on a synthesized input · constructed an object; no result was computed
blbadger/lm-evaluation-harness/lm_eval/models/srm_model.py
code served (permissive licence) · get_code("a08b8b9498759559")
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 an instance of its own class, HeadedRepeatCausalLinear: the run constructed the object and did not call it, so no result was computed. 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 torch.nn as nn

torch.manual_seed(0)

# Analyze the function to determine required arguments
# __init__ parameters: dim, heads, decay, decay_constant
# The forward method uses:
# - self.weight: shape (heads, dim)
# - self.bias: shape (heads, dim)
# - self.decay_value: shape (2, 1) if decay=True
# - vector_to_matrix expects input of shape (k, m) where m = dim
# - forward expects x of shape (batch, seq_len, dim) where batch is divisible by heads

# Setting up parameters
dim = 4
heads = 2
decay = True
decay_constant = 1

ARGS = {
    "dim": dim,
    "heads": heads,
    "decay": decay,
    "decay_constant": decay_constant,
}
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 HeadedRepeatCausalLinear — the run constructed an instance of its own class and did not call it; no shape is stated — the instrument coerces any output to an array; for a HeadedRepeatCausalLinear 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
KernelRepeatLinear Ran
ran on a synthesized input · constructed an object; no result was computed
blbadger/lm-evaluation-harness/lm_eval/models/srm_model.py
code served (permissive licence) · get_code("1e043f786bcb9c3c")
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 an instance of its own class, KernelRepeatLinear: the run constructed the object and did not call it, so no result was computed. 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 torch.nn as nn

torch.manual_seed(0)

# Set device to CPU
device = torch.device('cpu')

# Create a small input tensor for forward pass
# Shape: (batch=2, embedding_dim=4, sequence_length=3)
x = torch.randn(2, 4, 3)

# Define ARGS dict with all parameters for KernelRepeatLinear.__init__
ARGS = {
    'dim': 4,
    'kernel': 3,
    'decay': False,
    'decay_constant': 1
}
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 KernelRepeatLinear — the run constructed an instance of its own class and did not call it; no shape is stated — the instrument coerces any output to an array; for a KernelRepeatLinear 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
MixedRepeatHeads Ran
ran on a synthesized input · constructed an object; no result was computed
blbadger/lm-evaluation-harness/lm_eval/models/srm_model.py
code served (permissive licence) · get_code("af46e67d9ada1a52")
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 an instance of its own class, MixedRepeatHeads: the run constructed the object and did not call it, so no result was computed. 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 torch.nn as nn

torch.manual_seed(0)

# Small stand-in parameters
dim = 4
seq_len = 8
hidden_dim = 3
n_heads = 4
expanded_convs = False
decay = False
use_projections = True

ARGS = {
    "dim": dim,
    "seq_len": seq_len,
    "hidden_dim": hidden_dim,
    "n_heads": n_heads,
    "expanded_convs": expanded_convs,
    "decay": decay,
    "use_projections": use_projections,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
einops, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type MixedRepeatHeads — the run constructed an instance of its own class and did not call it; no shape is stated — the instrument coerces any output to an array; for a MixedRepeatHeads 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
ParallelRepeatHeads Ran
ran on a synthesized input · constructed an object; no result was computed
blbadger/lm-evaluation-harness/lm_eval/models/srm_model.py
code served (permissive licence) · get_code("b677012c85ad1913")
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 an instance of its own class, ParallelRepeatHeads: the run constructed the object and did not call it, so no result was computed. 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 torch.nn as nn

torch.manual_seed(0)

# Define ARGS dict with all parameters for ParallelRepeatHeads
ARGS = {
    'dim': 4,
    'seq_len': 8,
    'hidden_dim': 16,
    'n_heads': 2,
    'use_projections': True,
    'decay': False,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
einops, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ParallelRepeatHeads — the run constructed an instance of its own class and did not call it; no shape is stated — the instrument coerces any output to an array; for a ParallelRepeatHeads 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
RepeatCausalLinear Ran
ran on a synthesized input · constructed an object; no result was computed
blbadger/lm-evaluation-harness/lm_eval/models/srm_model.py
code served (permissive licence) · get_code("90b0ed5842d1a6a8")
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 an instance of its own class, RepeatCausalLinear: the run constructed the object and did not call it, so no result was computed. 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 torch.nn as nn

torch.manual_seed(0)

class RepeatCausalLinear(nn.Module):

    def __init__(self, dim: int, heads: int):
        super().__init__()
        self.weight = nn.Parameter(torch.randn(heads, dim))
        self.bias = nn.Parameter(torch.zeros(heads, dim))
        self.heads = heads

    def vector_to_matrix(self, v: torch.Tensor) -> torch.Tensor:
        """
        [ a  b  c  d]
        [ 0  b  c  d]
        [ 0  0  c  d]
        [ 0  0  0  d]
        """
        m = v.shape[-1]
        i, j = torch.meshgrid(torch.arange(m, device=v.device), torch.arange(m, device=v.device), indexing='ij')
        M = torch.where(j >= i, v[..., j], torch.zeros(m, m, device=v.device, dtype=v.dtype))
        return M

    def forward(self, x: torch.Tensor) -> torch.Tensor:
        W = self.vector_to_matrix(self.weight).repeat(x.shape[0] // self.heads, 1, 1)
        output = torch.bmm(x, W)
        repeated_bias = self.bias.repeat(x.shape[0] // self.heads, 1)
        repeated_bias = repeated_bias.unsqueeze(1).repeat(1, x.shape[1], 1)
        output += repeated_bias
        return output

ARGS = {
    "dim": 4,
    "heads": 2,
}
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 RepeatCausalLinear — the run constructed an instance of its own class and did not call it; no shape is stated — the instrument coerces any output to an array; for a RepeatCausalLinear 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
RowRepeatCausalLinear Ran
ran on a synthesized input · constructed an object; no result was computed
blbadger/lm-evaluation-harness/lm_eval/models/srm_model.py
code served (permissive licence) · get_code("67e0fe4c73bec386")
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 an instance of its own class, RowRepeatCausalLinear: the run constructed the object and did not call it, so no result was computed. 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 torch.nn as nn

torch.manual_seed(0)

class RowRepeatCausalLinear(nn.Module):

    def __init__(self, dim: int, decay=False, decay_constant=1):
        super().__init__()
        self.weight = nn.Parameter(torch.randn(1, dim))
        self.bias = nn.Parameter(torch.zeros(dim))
        if decay:
            self.decay_value = nn.Parameter(torch.ones(1))
            self.decay_constant = decay_constant
        else:
            self.decay_value = None

    def vector_to_matrix(self, v: torch.Tensor) -> torch.Tensor:
        """
        [ a  a  a  a ]
        [ 0  b  b  b ]
        [ 0  0  c  d ]
        [ 0  0  0  d ]
        """
        v = v.reshape(-1)
        m = v.shape[0]
        i, j = torch.meshgrid(torch.arange(m, device=v.device), torch.arange(m, device=v.device), indexing='ij')
        if self.decay_value is not None:
            M = torch.where(j >= i, v[i] * torch.clip(self.decay_value, min=0.9, max=1) ** ((j - i) / self.decay_constant), torch.zeros(m, m, device=v.device, dtype=v.dtype))
        else:
            M = torch.where(j >= i, v[i], torch.zeros(m, m, device=v.device, dtype=v.dtype))
        return M

    def forward(self, x: torch.Tensor) -> torch.Tensor:
        B, E, S = x.shape
        W = self.vector_to_matrix(self.weight).to(x.dtype)
        x_reshaped = x.reshape(B * E, S)
        out = x_reshaped @ W
        out = out + self.bias.to(x.dtype)
        out = out.view(B, E, S)
        return out


ARGS = {
    'dim': 4,
    'decay': False,
    'decay_constant': 1
}
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 RowRepeatCausalLinear — the run constructed an instance of its own class and did not call it; no shape is stated — the instrument coerces any output to an array; for a RowRepeatCausalLinear 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
MLPMixer Not yet run
unverified (harvested, no recorded run)
blbadger/lm-evaluation-harness/lm_eval/models/srm_model.py
code served (permissive licence) · get_code("af3cfa3cd6c4d580")
How it ran

no invocation recorded.

MixerBlock Not yet run
unverified (harvested, no recorded run)
blbadger/lm-evaluation-harness/lm_eval/models/srm_model.py
code served (permissive licence) · get_code("82f552f2e51345d1")
How it ran

no invocation recorded.

RepeatHeads Not yet run
unverified (harvested, no recorded run)
blbadger/lm-evaluation-harness/lm_eval/models/srm_model.py
code served (permissive licence) · get_code("5b043b13bb1d8051")
How it ran

no invocation recorded.

Also present in other papers' code

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

Over the last two decades, language modeling has experienced a shift from the use of predominantly recurrent architectures that process tokens sequentially during training and inference to non-recurrent models that process sequence elements in parallel during training, which results in greater training efficiency and stability at the expense of lower inference throughput. Here we introduce the Structured Recurrent Mixer, an architecture that allows for algebraic conversion between a sequence parallel representation at train time and a recurrent representation at inference, notably without the need for specialized kernels or device-specific memory management. We show experimentally that this dual representation allows for greater training efficiency, higher input information capacity, and larger inference throughput and concurrency when compared to other linear complexity models. We postulate that recurrent models are poorly suited to extended sequence length scaling for information-rich inputs typical of language, but are well suited to scaling in the sample (batch) dimension due to their constant memory per sample. We provide Mojo/MAX inference implementations of SRMs exhibiting 12x the throughput and 170x the concurrency of similarly powerful Transformers inferenced on vLLM, increases characteristic of Pytorch implementations resulting in a 30% increase in compute-constant GSM8k Pass@k. We conclude by demonstrating that SRMs are effective reinforcement learning training candidates due to this large throughput.

For agents

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

get_harvested_code_for_paper("2605.08696")
get_code_for_paper("2605.08696")
have("2605.08696")

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

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

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

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

Connect an agent — have() is free.