Skip to main content

taut-shape (Python)

pip install taut-shape → import taut_shape.

A pure-Python implementation of the Taut atom, log, stream, and value delivery shapes. No Rust, no PyO3, no native extension. The engine is a synchronous mailbox endpoint (LogNode.handle(msg) -> [outputs]); the only concurrency is an optional asyncio shell layered on top (not yet built).

This is a clean-room implementation: written against the shared plan (taut-shape/dev-docs/TautClientImplPlan.md, D1–D19) and the behavioral oracle (taut-shape/corpus/log.v0.json) only — it does not mirror taut-shape-rs. A hand-written engine that still reproduces every oracle vector is the evidence that the oracle, not shared source, is the contract.

Status

  • Phase 0 — scaffold + vendored generated message types. ✓
  • Phase 1 — the LogNode mailbox engine (pure, sync). ✓
  • Phase 2 — oracle conformance (tests/test_oracle.py, whole-transcript ==). ✓
  • Phase 4 — the taut-shape-tool CLI (node/client modes over stdin/stdout framing, python3 -m taut_shape.tool; see src/taut_shape/tool/main.py). ✓
  • Phase 5 — interop matrix participation (taut-shape/matrix/driver.py runs this tool as the py language). ✓
  • Phase 3 (an asyncio shell) — not built; the engine has no built-in concurrency layer beyond the CLI's synchronous read/handle/write loop.

Layout

src/taut_shape/log/
  _generated.py   # tautc-generated message/value types (vendored, do NOT edit)
  messages.py     # InMsg/OutMsg unions + re-exports
  _window.py      # store core: bounded window, head/floor, evict (internal)
  _sessions.py    # session table: held reads, timers, watermarks (internal)
  engine.py       # LogNode.handle + read-only accessors
src/taut_shape/value/
  _generated.py   # tautc-generated value messages (vendored, do NOT edit)
  engine.py       # attributed LWW ValueNode
src/taut_shape/atom/
  _generated.py   # tautc-generated atom messages (vendored, do NOT edit)
  engine.py       # latest-state AtomNode
src/taut_shape/stream/
  _generated.py   # tautc-generated stream messages (vendored, do NOT edit)
  engine.py       # bounded live-only StreamNode

Tool (node / client)

Run the framing CLI as a module. Both modes accept exact --shape <NAME> selection and default to log; the implemented registry contains atom, log, stream, and value.

PYTHONPATH=../taut/src:src python3 -m taut_shape.tool node --shape log
PYTHONPATH=../taut/src:src python3 -m taut_shape.tool client --shape log \
  --stream-id s1 --from 0
PYTHONPATH=../taut/src:src python3 -m taut_shape.tool client --shape value \
  --value-id value-A --stream-id s1 --reads 1
PYTHONPATH=../taut/src:src python3 -m taut_shape.tool client --shape atom \
  --atom-id atom-A --stream-id s1 --from 0
PYTHONPATH=../taut/src:src python3 -m taut_shape.tool client --shape stream \
  --stream-id live-metrics

An unsupported name exits 2 with TAUT_SHAPE_UNSUPPORTED_SHAPE before stdin is read or a client request is written.

Running the tests

The taut codec is a workspace sibling; point PYTHONPATH at it:

PYTHONPATH=../taut/src:src pytest

Metadata

Release files for taut-shape 0.12.0

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

Source distribution (sdist)

Source distribution for taut-shape 0.12.0
File Size Uploaded Provenance Actions
taut_shape-0.12.0.tar.gz 106.5 kB With provenance Details for taut_shape-0.12.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for taut-shape 0.12.0
File Interpreter ABI Platform Actions
taut_shape-0.12.0-py3-none-any.whl Python 3 none any Details for taut_shape-0.12.0-py3-none-any.whl

Total release size: 200.0 kB

Release files / taut_shape-0.12.0.tar.gz

Download URL taut_shape-0.12.0.tar.gz
Size 106.5 kB
Tags Source
SHA-256 checksum
How to use checksums
e5c75bd55ab8d8fddec9921bddc46776a54ee84673e4fa76d89df69193b521a7
BLAKE2b-256 checksum
How to use checksums
9e62be37b84cc0a97460c7336f5ba3fa2484257751ceb4257f043d3e6d2e81ee
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Nov 16, 2026.

Transparency log

Release files / taut_shape-0.12.0-py3-none-any.whl

Download URL taut_shape-0.12.0-py3-none-any.whl
Size 93.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f5d53bc5d09608c8564ca6f092f5ae277423ebbb6a145020c84a1020e23c23cf
BLAKE2b-256 checksum
How to use checksums
1bde7d2b576e3b39b091f4802a153aab8406711e56903d8f8bad4d41bbcd8af7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Nov 16, 2026.

Transparency log

Security for taut-shape 0.12.0

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

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for taut_shape-0.12.0.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 Nov 16, 2026.

Transparency log

A 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.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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