SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2606.24039 · 2026

TurboMPC: Fast, Scalable, and Differentiable Model Predictive Control on the GPU

Gabriel Bravo-Palacios, Jianghan Zhang, Zachary Pestrikov, Brian Plancher, Thomas Lew

arXiv · PDF · Open in the Atlas

Code that ran

7 of 7 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, 2 violated it and 0 have no contract verdict; 5 failures of our instrument; 0 no recorded run), measured 2026-11-23; 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/2606.24039.json · badge: /api/ran/2606.24039.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
ToyotaResearchInstitute/turbompc canonical (classifier label)
classifier basis: census
7 ran · 0 no recorded run
FunctionStatusWhere it lives
S Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
ToyotaResearchInstitute/turbompc/turbompc/dynamics/quadrotor_dynamics.py
code served (permissive licence) · get_code("d0cb2be32e42ae1d")
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 (3, 3) 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.numpy as jnp
import numpy as np

# The function S takes a single parameter `u` which should be an array-like object
# that supports indexing with [0], [1], [2] and has at least 3 elements.
# The function constructs a 3x3 skew-symmetric matrix from the input vector u.

# Create a small input vector with 3 elements (can have more, but only first 3 are used)
u = jnp.array([1.0, 2.0, 3.0])

ARGS = {
    "u": u
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
jax, numpy — 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 (3, 3) — shape (3, 3) 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
absolute_l2_error Ran
ran, violated the contract we drafted
ToyotaResearchInstitute/turbompc/benchmarking/linear-system/benchmark_turbompc_gradient_accuracy.py
code served (permissive licence) · get_code("89ca4821e2b54e17")
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 numpy as np

# Create two sample gradient arrays with different shapes to make the L2 norm non-trivial
g_ad = np.array([[1.0, 2.0, 3.0, 4.0],
                  [5.0, 6.0, 7.0, 8.0]])

g_fd = np.array([[1.1, 2.1, 2.9, 3.9],
                 [5.2, 5.8, 7.1, 7.9]])

ARGS = {
    "g_ad": g_ad,
    "g_fd": g_fd
}
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 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
cosine_similarity Ran
ran; our contract draft was wrong, not the code
ToyotaResearchInstitute/turbompc/benchmarking/linear-system/benchmark_turbompc_gradient_accuracy.py
code served (permissive licence) · get_code("35574ac34802affb")
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 numpy as np

# Create two small flat arrays for testing cosine similarity
a = np.array([1.0, 2.0, 3.0, 4.0], dtype=np.float64)
b = np.array([5.0, 6.0, 7.0, 8.0], dtype=np.float64)

ARGS = {
    "a": a,
    "b": b,
    "eps": 1e-12
}
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 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
make_slack_problem Ran
ran; our contract draft was wrong, not the code
ToyotaResearchInstitute/turbompc/turbompc/problems/optimal_control_problem.py
code served (permissive licence) · get_code("385e9bf32b44c394")
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 type. 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 jax.numpy as jnp
import jax
from typing import Any, Dict, Tuple

# Create a minimal base class that implements the required methods
class MinimalProblem:
    def __init__(self, params: Dict[str, Any]):
        self.params = params
    
    def cost(self, states: jnp.ndarray, controls: jnp.ndarray, params: Dict[str, Any]) -> jnp.ndarray:
        """Return a scalar cost value."""
        return jnp.sum(states ** 2) + jnp.sum(controls ** 2)
    
    def inequality_constraints(self, states: jnp.ndarray, controls: jnp.ndarray, params: Dict[str, Any]) -> Tuple[jnp.ndarray, jnp.ndarray, jnp.ndarray]:
        """Return g, l, u for inequality constraints l <= g(x,u) <= u."""
        # Return g (constraint values), l (lower bounds), u (upper bounds)
        g = jnp.array([0.5, -0.3, 0.2])
        l = jnp.array([-1.0, -1.0, -1.0])
        u = jnp.array([1.0, 1.0, 1.0])
        return g, l, u

# Define parameters for the SlackProblemAdapter
params = {
    'use_slack_variables': True,
    'slack_penalization_weight': 0.1
}

# Create the base class instance for testing
base_cls = MinimalProblem

# Define ARGS - the only parameter is base_cls
ARGS = {
    'base_cls': base_cls
}
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 type — a type output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a type 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
q_conj Ran
ran, violated the contract we drafted
ToyotaResearchInstitute/turbompc/turbompc/dynamics/quadrotor_dynamics.py
code served (permissive licence) · get_code("c2803c56082c12e5")
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 1, dtype family float, shape (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.numpy as jnp

# The function q_conj takes a quaternion q and returns its conjugate
# q is expected to be a JAX array where:
# - q[:1] is the scalar part (real part)
# - q[1:] are the vector parts (imaginary parts)
# The conjugate keeps the scalar part and negates the vector parts

# Create a simple quaternion as a JAX array
# Shape: (4,) - standard quaternion representation [w, x, y, z]
q = jnp.array([1.0, 0.5, 0.3, 0.2])

ARGS = {
    "q": q
}
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 1, dtype family float, shape (4,) — shape (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
q_left Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
ToyotaResearchInstitute/turbompc/turbompc/dynamics/quadrotor_dynamics.py
code served (permissive licence) · get_code("40de89e05c3e981b")
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 (4, 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.numpy as jnp

# q_left expects a quaternion represented as a JAX array
# The function accesses q[0] (scalar part) and q[1:] (vector part)
# So we need a 4-element array: [qw, qx, qy, qz]

q = jnp.array([1.0, 0.5, 0.3, 0.2])

ARGS = {
    "q": q
}
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 (4, 4) — shape (4, 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
relative_l2_error Ran
ran; our contract draft was wrong, not the code
ToyotaResearchInstitute/turbompc/benchmarking/linear-system/benchmark_turbompc_gradient_accuracy.py
code served (permissive licence) · get_code("c76f95466a6b0b38")
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 numpy as np

# Create two small gradient arrays for comparison
np.random.seed(0)

# g_ad: autodiff gradients
g_ad = np.random.randn(4, 3)

# g_fd: finite difference gradients
g_fd = np.random.randn(4, 3)

# eps: small constant for numerical stability
eps = 1e-12

ARGS = {
    "g_ad": g_ad,
    "g_fd": g_fd,
    "eps": eps
}
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 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

Also present in other papers' code

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

Repositories linked to this paper

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

Abstract

Fig. 1. TurboMPC is a differentiable MPC solver that runs entirely on the GPU. It supports realistic problem formulations that enable deployment on challenging robotics applications such as minimum-time racing. Thanks to its differentiability and GPU support, it can be used in learning pipelines such as auto-tuning via reinforcement learning (RL), imitation learning (IL), and Bayesian optimization (BO).

For agents

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

get_harvested_code_for_paper("2606.24039")
get_code_for_paper("2606.24039")
have("2606.24039")

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

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

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

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

Connect an agent — have() is free.