Tesseract Core¶
Universal, autodiff-native software components for Simulation Intelligence 📦
See also
Already convinced? 👉 See how to Get started instead.
The problem¶
Real-world scientific workflows span multiple tools, languages, and computing environments. You might have a mesh generator in C++, a solver in Julia, and post-processing in Python. Getting these to work together is painful. Getting gradients to flow through them for optimization is nearly impossible.
Existing autodiff frameworks work great within a single codebase, but fall short when your pipeline crosses framework boundaries or includes legacy or commercial tools.
The solution¶
Tesseract packages scientific software into self-contained, portable components that:
Run anywhere — Local machines, cloud, HPC clusters. Same container, same results.
Expose clean interfaces — CLI, REST API, and Python SDK. No more deciphering undocumented scripts.
Propagate gradients — Each component can expose derivatives, enabling end-to-end optimization across heterogeneous pipelines.
Self-document — Schemas, types, and API docs are generated automatically.
Who is this for?¶
Researchers interfacing with (differentiable) simulators or probabilistic models, or who need to combine tools from different ecosystems.
R&D engineers packaging research code for use by others, without spending weeks on DevOps.
Platform engineers deploying scientific workloads at scale with consistent interfaces and dependency isolation.
How it works¶
Internal and external interfaces of a Tesseract.¶
Every Tesseract has a primary entrypoint, apply, which wraps a software functionality of your choice. All other endpoints relate to this entrypoint: abstract_eval returns output structure, jacobian computes derivatives, and so on.
There are several ways to interact with Tesseracts:
Define entrypoints in
tesseract_api.pyBuild a container with
tesseract buildServe via HTTP with
tesseract serveInvoke via CLI, HTTP, or the Python SDK
Features and restrictions¶
Self-documenting – Tesseracts announce their interfaces, so that users can inspect them without needing to read the source code, and perform static validation without running the code.
Auto-validating – When data reaches a Tesseract, it is automatically validated against the schema, so that internal logic can be sure that the data is in the expected format.
Autodiff-native – Tesseracts support Differentiable Programming, meaning that they can be used in gradient-based optimization algorithms – or not, since exposing derivatives is strictly optional.
Batteries included – Tesseracts ship with a containerized runtime, which can be run on a variety of platforms, and exposes the Tesseract’s functionality via a command line interface (CLI) and a REST API.
Python first – Although Tesseracts may use any software under the hood, Tesseracts always use Python as glue between the Tesseract runtime and the wrapped functionality. This also means that support for working with Python projects is more mature than other languages.
Single entrypoint – Tesseracts have a single entrypoint,
apply, which wraps a software functionality of the Tesseract creator’s choice. When exposing N entrypoints of a software, users need to create N distinct Tesseracts.Context-free – Tesseracts are not aware of outer-loop orchestration or runtime details.
Runtime overhead – Tesseracts are primarily designed for compute kernels and data transformations that run at least several seconds, so they may not be the best choice for workloads with very low latency requirements.
Why Tesseracts?¶
Tesseracts help you manage diversity in scientific computing:
Diversity of roles — The software creator’s job ends when code is packaged as a Tesseract. Pipeline builders focus on high-level logic. Team members can inspect interfaces and schemas without diving into implementations.
Diversity of software — Components can use any framework or language: PyTorch, JAX, C++, Fortran, Julia, or shell scripts. A thin Python wrapper (
tesseract_api.py) connects everything.Diversity of hardware — Components don’t need to run on the same machine. Distribute work across GPUs, CPUs, and clusters while maintaining end-to-end differentiability.
Diversity of differentiation strategies — Mix automatic differentiation, analytic adjoints, and finite differences in the same pipeline. Each component chooses its own approach.
If you’re a single developer working with a single software stack in a single environment, you might not need Tesseracts. Everyone else, read on!
The Ecosystem¶
Tesseract Core is the foundation of the Tesseract ecosystem. Additional packages extend its capabilities:
Tesseract Core — CLI, Python SDK, and runtime.
Tesseract-JAX — Embed Tesseracts as JAX primitives into end-to-end differentiable programs.
Tesseract-Streamlit — Auto-generate interactive Streamlit web apps from running Tesseracts. Instantly create UIs for your components without writing frontend code.
Citing Tesseract¶
If you use Tesseract in your research, please cite:
@article{TesseractCore,
doi = {10.21105/joss.08385},
url = {https://doi.org/10.21105/joss.08385},
year = {2025},
publisher = {The Open Journal},
volume = {10},
number = {111},
pages = {8385},
author = {Häfner, Dion and Lavin, Alexander},
title = {Tesseract Core: Universal, autodiff-native software components for Simulation Intelligence},
journal = {Journal of Open Source Software}
}