Skip to main content

ZOON Python

ZOON - Zero Overhead Object Notation

A Python implementation of the ZOON format for LLM context optimization. Achieves ~60% token reduction compared to JSON while maintaining 100% data fidelity.

PyPI License

Installation

pip install zoon-format

Or with uv:

uv add zoon-format

Quick Start

import zoon

data = [
    {"id": 1, "name": "Alice", "role": "admin", "active": True},
    {"id": 2, "name": "Bob", "role": "user", "active": True},
    {"id": 3, "name": "Carol", "role": "user", "active": False},
]

encoded = zoon.encode(data)
print(encoded)
# # id:i+ name:s role=admin|user active:b
# Alice admin 1
# Bob user 1
# Carol user 0

decoded = zoon.decode(encoded)
assert decoded == data

Features

  • ~60% Token Reduction: Reduced LLM context usage vs JSON
  • 100% Lossless: Perfect round-trip encoding/decoding
  • Type-Safe: Preserves integers, floats, booleans, nulls, and strings
  • Auto-Increment IDs: i+ columns are omitted from data rows
  • Smart Enums: Automatic header-based typing for repeated values

API Reference

zoon.encode(data: Any) -> str

Encode Python data to ZOON format.

zoon.decode(zoon_string: str) -> Any

Decode ZOON string back to Python data.

License

MIT License. © 2025-PRESENT Carsen Klock

Metadata

Release files for zoon-format 1.0.3

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

Source distribution (sdist)

Source distribution for zoon-format 1.0.3
File Size Uploaded Provenance Actions
zoon_format-1.0.3.tar.gz 41.0 kB Without provenance Details for zoon_format-1.0.3.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for zoon-format 1.0.3
File Interpreter ABI Platform Actions
zoon_format-1.0.3-py3-none-any.whl Python 3 none any Details for zoon_format-1.0.3-py3-none-any.whl

Total release size: 49.9 kB

Release files / zoon_format-1.0.3.tar.gz

Download URL zoon_format-1.0.3.tar.gz
Size 41.0 kB
Tags Source
SHA-256 checksum
How to use checksums
bb68fb33ee42cb71e515c94dd9187bdeea82c454e4b8dfb8df64069795d30492
BLAKE2b-256 checksum
How to use checksums
06d13eb63044d3f6bc5a7a7ca735492bab26ca2aa9c3a34908c3f5d65b5c75e7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.8.22

Release files / zoon_format-1.0.3-py3-none-any.whl

Download URL zoon_format-1.0.3-py3-none-any.whl
Size 8.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
c6c03ef7a0408a6ed9e3e1ffd1ac48c39b073df005473a65b92990bae837ecd7
BLAKE2b-256 checksum
How to use checksums
204e70a55d77c79f26f0d0db7faaf469ed933def9a0f46947e73e5fef4b6f210
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.8.22

Security for zoon-format 1.0.3

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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

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