Skip to main content
transports logo, concentric circles with a line connecting them with points Move typed models across any wire as incremental patches.

Define a model once as a pydantic model, stdlib dataclass, or msgspec struct. Host it in Python, mutate it normally, and send only the patch needed to update a remote mirror. The same Rust core drives Python (PyO3) and JavaScript (wasm), so both sides use the same Value, diff, patch, and codec machinery.

Build Status codecov License PyPI

import transports
from pydantic import BaseModel

class Device(BaseModel):
    name: str
    on: bool = False

session = transports.Session()
lamp = Device(name="lamp")
model_id = session.host(lamp)

lamp.on = True
print(session.drain())
# [(1, {'rev': 1, 'ops': [{'Set': {'path': [{'Key': 'on'}], 'value': {'Bool': True}}}]})]

Install

pip install transports
pip install "transports[connections]"   # WebSocket server/client adapters
pip install "transports[sse]"           # Server-Sent Events adapter
pip install "transports[jupyter]"       # Jupyter comm adapter

Documentation

Tutorial

Quickstart builds one hosted model and mirrors it with the in-process server/client protocol.

How-to guides

Model bridges covers pydantic, dataclasses, msgspec, schemas, and plain JavaScript objects. Connections covers WebSocket, SSE, Jupyter comm, and anywidget adapters. Codecs covers JSON, MessagePack, and custom codecs. Multi-tenancy and sharing covers tenant isolation, shared models, and merge strategies. Pyodide covers building and loading transports in a browser. Benchmarks covers the server fan-out benchmark harness, its scaling knobs, and recording benchmark history with benched.

Reference

API reference lists the Python API. Wire protocol reference describes Value, patch operations, protocol messages, codecs, and model ids.

Explanation

Concepts explains why transports uses incremental patches, server-owned revisions, a shared Rust core, and transport-agnostic adapters.

[!NOTE] This library was generated using copier from the Base Python Project Template repository

Metadata

Release files for transports 0.8.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for transports 0.8.2
File Size Uploaded
transports-0.8.2.tar.gz 416.6 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for transports 0.8.2
File
transports-0.8.2-cp314-cp314-pyemscripten_2026_0_wasm32.whl CPython 3.14 CPython 3.14 PyEmscripten 2026.0+ WebAssembly Details
transports-0.8.2-cp311-abi3-win_amd64.whl CPython 3.11 abi3 Windows x86-64 Details
transports-0.8.2-cp311-abi3-manylinux_2_28_x86_64.whl CPython 3.11 abi3 Linux glibc 2.28+ x86-64 Details
transports-0.8.2-cp311-abi3-manylinux_2_28_aarch64.whl CPython 3.11 abi3 Linux glibc 2.28+ ARM64 Details
transports-0.8.2-cp311-abi3-macosx_11_0_arm64.whl CPython 3.11 abi3 macOS 11.0+ ARM64 Details

Total release size: 4.0 MB

Release files / transports-0.8.2.tar.gz

Download URL transports-0.8.2.tar.gz
Size 416.6 kB
Tags Source
SHA-256 checksum
How to use checksums
d89b5561ad41923c5704af6a655145e1d66f930d778efa51a51e4e02ee5b5eb3
BLAKE2b-256 checksum
How to use checksums
de06b0a46829aa53012a50f72bdbad84f2ea14c92b6b73cf1ac0349a6221519a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.13

Release files / transports-0.8.2-cp314-cp314-pyemscripten_2026_0_wasm32.whl

Download URL transports-0.8.2-cp314-cp314-pyemscripten_2026_0_wasm32.whl
Size 543.9 kB
Tags CPython 3.14 PyEmscripten 2026.0+ WebAssembly
SHA-256 checksum
How to use checksums
2ecee49b12ff9cf7602d618d12a77bbadd147b3b1fb8676111f7c3a2f26208c8
BLAKE2b-256 checksum
How to use checksums
4b3136f26648b093d1d38747b35fa0eb2de0b0580c322be831084f2db6dc3e50
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.13

Release files / transports-0.8.2-cp311-abi3-win_amd64.whl

Download URL transports-0.8.2-cp311-abi3-win_amd64.whl
Size 694.1 kB
Tags CPython 3.11 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
29783a5e22d0cce6953cc76c577c15dbfcf2e64ccc83104fb67934159b61ce55
BLAKE2b-256 checksum
How to use checksums
bb9626a60c42ec63c9e4daec5ee1f5ab7e5e042c2fd13ac4fcdf825cd2a04301
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.13

Release files / transports-0.8.2-cp311-abi3-manylinux_2_28_x86_64.whl

Download URL transports-0.8.2-cp311-abi3-manylinux_2_28_x86_64.whl
Size 820.6 kB
Tags CPython 3.11 Linux glibc 2.28+ x86-64 abi3
SHA-256 checksum
How to use checksums
ba999fb5f6aaf0343eac9f1c076e1ec6d88e306b0702086db597f6c32653cb27
BLAKE2b-256 checksum
How to use checksums
38c958fceeff98bd7357e35843b5f62ca171624070c17f788be4f8a7fdc423f5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.13

Release files / transports-0.8.2-cp311-abi3-manylinux_2_28_aarch64.whl

Download URL transports-0.8.2-cp311-abi3-manylinux_2_28_aarch64.whl
Size 792.3 kB
Tags CPython 3.11 Linux glibc 2.28+ ARM64 abi3
SHA-256 checksum
How to use checksums
62ce9e35fbec5563806defad69b3917a42459556411689412d05251dae96f958
BLAKE2b-256 checksum
How to use checksums
3e733b0082ee25663c4a6152df51c9f2bad6808fe437aecd279549bd1bc06098
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.13

Release files / transports-0.8.2-cp311-abi3-macosx_11_0_arm64.whl

Download URL transports-0.8.2-cp311-abi3-macosx_11_0_arm64.whl
Size 747.9 kB
Tags CPython 3.11 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
76d20ceeff9c55b9867c96d3e328fc7dbea66704f9e48be412828dced1814ea0
BLAKE2b-256 checksum
How to use checksums
5aae05ebd54cc43111fb27bb47cd92ba1c3e60ad5870dc096096bf17b6771c5d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.13

Release history Release notifications | RSS feed

0.10.0

6 release files

0.9.0

6 release files

0.8.6

6 release files

0.8.5

6 release files

0.8.4

6 release files

0.8.3

6 release files

This release

0.8.2 This release

6 release files

0.8.1

6 release files

0.8.0

5 release files

0.7.0

5 release files

0.6.0

4 release files

0.5.0

4 release files

0.4.0

4 release files

0.3.0

4 release files

0.1.2

5 release files

0.1.1

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page