This release is a pre-release and may not be stable for production use.
synth-containers
The task contract for Synth optimizers and evals — wrap any task as a small HTTP service that optimizers can target without touching your code.
PyPI · Optimizers · Cookbooks
A Synth container is a small HTTP service around a task. It owns the dataset, the
scoring/verifier logic, the mutable prompt or policy fields, and the policy-model
credential boundary. An optimizer like
synth-optimizers GEPA sees one URL
and a typed rollout contract — it never imports your task package or reads private
evaluator state. The same contract works whether the task is a classifier, a coding
agent, or a live game environment, and in Python, Rust, or TypeScript.
Install
pip install synth-containers
# or
uv add synth-containers
Local Synth development
Register the current checkout once after changing Containers or its package version:
./scripts/register-local-dev-build.sh
The command builds a wheel, installs it into an immutable machine-local directory, verifies the installed version, and atomically selects it for local Workshop builds. No launch flags or environment variables are required. Re-running it reuses an identical registered wheel.
Sibling Optimizers development remains editable through its checked-in uv source:
cd ../optimizers
uv sync --group dev
The contract
| Route | Method | Purpose |
|---|---|---|
/metadata |
GET | contract version + capabilities |
/program |
GET | mutable prompt fields + seed candidate |
/dataset |
GET | split names + row counts |
/dataset/rows |
POST | rows for a requested seed list |
/rollout |
POST | run a candidate on a row → reward + usage |
/health |
GET | liveness |
The Python SDK also provides Container, Container.serve(),
ContainerHandle, and ContainerConnection for URL-only optimizer handoff.
Use generic route hints and capability metadata here; optimizer-specific GEPA
settings belong in synth-optimizers.
Example
from fastapi import Body, FastAPI
from synth_containers import GEPA_OPTIMIZER_CONTRACT_VERSION
app = FastAPI()
@app.post("/rollout")
def rollout(payload: dict = Body(...)) -> dict:
candidate, row = payload["candidate"], payload["row"]
# run the task with the candidate's mutable fields, score it with a real verifier
return {"reward": ..., "usage": ...}
See the cookbooks for complete containers: Banking77, HotpotQA, MiniGrid, TBLite, and Crafter.
Links
- Optimizers — GEPA on this contract
- Cookbooks — runnable containers
- Agent skill — drop into a coding agent to build and debug containers
- Contract OpenAPI
License
MIT
Metadata
Release files for synth-containers 0.4.1.dev20260814
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| synth_containers-0.4.1.dev20260814.tar.gz | 518.9 kB | With provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| synth_containers-0.4.1.dev20260814-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 1.0 MB
Release files / synth_containers-0.4.1.dev20260814.tar.gz
| Download URL | synth_containers-0.4.1.dev20260814.tar.gz |
|---|---|
| Size | 518.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7122cc1d61f73a25e266a92d93ddd7a66bf075d2f5ca304c079588294e867ebf
|
|
BLAKE2b-256 checksum How to use checksums |
4b8247fa0f8e886376399667902e434dec527be1eaafc2714f6985e0fdc35c05
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 14, 2026.
Transparency logRelease files / synth_containers-0.4.1.dev20260814-py3-none-any.whl
| Download URL | synth_containers-0.4.1.dev20260814-py3-none-any.whl |
|---|---|
| Size | 516.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
518dcd5304edc245e74d1d5d2d5f76b32759716d48550ecb756be431d59d8fd3
|
|
BLAKE2b-256 checksum How to use checksums |
1e627ad5656a825db2c145afa14b8f16ef81132c14db48afd084c28fce22235d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 14, 2026.
Transparency logSecurity for synth-containers 0.4.1.dev20260814
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
All 2 files in this release have been uploaded with provenance metadata.
Attestation for synth_containers-0.4.1.dev20260814.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Aug 14, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.