Skip to main content

Python bindings for Quillmark - format-first Markdown rendering

Project description

Quillmark — Python bindings

Python bindings for Quillmark's format-first Markdown rendering engine.

Maintained by TTQ.

Installation

pip install quillmark

Quick Start

from quillmark import Quillmark, Document, OutputFormat

engine = Quillmark()
quill = engine.quill_from_path("path/to/quill")

markdown = """---
QUILL: my_quill
title: Hello World
---

# Hello
"""

parsed = Document.from_markdown(markdown)
result = quill.render(parsed, OutputFormat.PDF)
result.artifacts[0].save("output.pdf")

# Round-trip: mutate, emit, re-parse
parsed.set_field("title", "Updated")
emitted = parsed.to_markdown()
reparsed = Document.from_markdown(emitted)
assert reparsed.frontmatter["title"] == "Updated"

API Overview

Quillmark

engine = Quillmark()
engine.registered_backends()      # ['typst']
quill = engine.quill_from_path("path/to/quill")

Quill

quill = engine.quill_from_path("path")
result = quill.render(parsed, OutputFormat.PDF)
session = quill.open(parsed)
quill.dry_run(parsed)

Document

doc = Document.from_markdown(markdown)
emitted = doc.to_markdown()          # canonical Quillmark Markdown

# Versioned storage DTO — use this to persist a document across a
# process restart or crate upgrade. The wire format is frozen per
# schema version, whereas Markdown syntax evolves.
stored = doc.to_json()               # JSON string carrying a schema version
restored = Document.from_json(stored)
assert restored.to_markdown() == doc.to_markdown()

from_json raises ParseError on malformed JSON or an unknown schema tag. A DTO-reconstructed document has no parse-time warnings.

Development

uv venv
uv pip install -e ".[dev]"
uv run pytest

License

Apache-2.0

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

quillmark-0.81.0.tar.gz (3.2 MB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

quillmark-0.81.0-cp310-abi3-win_amd64.whl (14.0 MB view details)

Uploaded CPython 3.10+Windows x86-64

quillmark-0.81.0-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (15.1 MB view details)

Uploaded CPython 3.10+manylinux: glibc 2.17+ x86-64

quillmark-0.81.0-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (14.7 MB view details)

Uploaded CPython 3.10+manylinux: glibc 2.17+ ARM64

quillmark-0.81.0-cp310-abi3-macosx_11_0_arm64.whl (13.8 MB view details)

Uploaded CPython 3.10+macOS 11.0+ ARM64

File details

Details for the file quillmark-0.81.0.tar.gz.

File metadata

  • Download URL: quillmark-0.81.0.tar.gz
  • Upload date:
  • Size: 3.2 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for quillmark-0.81.0.tar.gz
Algorithm Hash digest
SHA256 61f7d65f513c3b5358af0698da36a835ede50d71dc09fa26f45aa826b9711cbf
MD5 66425f8f3fa07918336108291272013c
BLAKE2b-256 b4319f97d64d785013bb8f15d4d75a892d7926c2c32cf871ef6c164aed96ba7e

See more details on using hashes here.

Provenance

The following attestation bundles were made for quillmark-0.81.0.tar.gz:

Publisher: release.yml on quillmark-org/quillmark

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file quillmark-0.81.0-cp310-abi3-win_amd64.whl.

File metadata

  • Download URL: quillmark-0.81.0-cp310-abi3-win_amd64.whl
  • Upload date:
  • Size: 14.0 MB
  • Tags: CPython 3.10+, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for quillmark-0.81.0-cp310-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 ef68365a3e24bed7fc7f991a52969b9639808b8c01b28d7f1c6d399d5f7ada9f
MD5 017bd89f62e71c1c3db456441c6b2dbb
BLAKE2b-256 ace75808de390813df7f2f9f3fcc68618fb6ca5f1c6f0726f0f1ca5eaf46b52b

See more details on using hashes here.

Provenance

The following attestation bundles were made for quillmark-0.81.0-cp310-abi3-win_amd64.whl:

Publisher: release.yml on quillmark-org/quillmark

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file quillmark-0.81.0-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for quillmark-0.81.0-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 6b92b3a4e46a4e6d5a931bb1034f000305463765b44f67707dfb0bf3305ae3f7
MD5 6c06191ccb43b5327533fa0bb2585f20
BLAKE2b-256 ad62333ddc7a9c1468514b158ca8aa259462d59b2878751a81eb5171907ee2bc

See more details on using hashes here.

Provenance

The following attestation bundles were made for quillmark-0.81.0-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: release.yml on quillmark-org/quillmark

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file quillmark-0.81.0-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for quillmark-0.81.0-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 051605a32a76ccb389a1129775f75bc9a3ef466ccb6c123a00fbf06854910af0
MD5 ff9d5f8d5c5cdef3541e1c7cd6fa531d
BLAKE2b-256 a09bd5a65b621e5ea3eae71cc5d28d466b68b24d3f109ecc2cd816157aea2fb1

See more details on using hashes here.

Provenance

The following attestation bundles were made for quillmark-0.81.0-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl:

Publisher: release.yml on quillmark-org/quillmark

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file quillmark-0.81.0-cp310-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for quillmark-0.81.0-cp310-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 07e8059d4d53d4cc9d4833b40e1e771900997844f2eb0f5147e8e1c45a26aabe
MD5 1f7348c5b8481feb105aae828280123c
BLAKE2b-256 8c7b2a7a3468f85791cc46704a6e81a7db4d47206895d821153a84849040f81e

See more details on using hashes here.

Provenance

The following attestation bundles were made for quillmark-0.81.0-cp310-abi3-macosx_11_0_arm64.whl:

Publisher: release.yml on quillmark-org/quillmark

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page