Skip to main content

prompting-press

A typed, variant-aware prompt-template library. It turns typed inputs and a template into rendered text plus content-addressed provenance — nothing else (no I/O, no LLM calls, no request assembly). Rust, Python, and TypeScript all bind one compiled Rust engine, so rendered output is byte-identical across every language.

This is the Python distribution: a Pydantic-friendly PyO3 binding to that engine. Import name prompting_press; distribution name prompting-press.

Install

pip install prompting-press
uv add prompting-press          # in a uv project
uv pip install prompting-press  # uv's pip interface

Quick start

from prompting_press import Prompt
from pydantic import BaseModel

class Vars(BaseModel):
    company: str
    max_words: int

assistant = Prompt.from_yaml("""
name: assistant
role: system
body: "You are a support assistant for {{ company }}. Keep your replies under {{ max_words }} words."
variables:
  company: { type: string, trusted: true }
  max_words: { type: integer, trusted: true }
""")

result = assistant.render(Vars, data={"company": "Acme Robotics", "max_words": 50})
result.text           # "You are a support assistant for Acme Robotics. Keep your replies under 50 words."
result.template_hash  # 64-char SHA-256 of the template source
result.render_hash    # 64-char SHA-256 of the rendered output

Documentation

Full docs — getting started, API reference, template features, guides, and the CI agreement lint — are at https://prompting-press.github.io/.

License

Apache-2.0.

Download files

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

Source Distribution

prompting_press-0.3.0.tar.gz (196.6 kB view details)

Uploaded Source

Built Distributions

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

prompting_press-0.3.0-cp312-abi3-win_amd64.whl (1.2 MB view details)

Uploaded CPython 3.12+Windows x86-64

prompting_press-0.3.0-cp312-abi3-musllinux_1_2_x86_64.whl (1.7 MB view details)

Uploaded CPython 3.12+musllinux: musl 1.2+ x86-64

prompting_press-0.3.0-cp312-abi3-musllinux_1_2_aarch64.whl (1.6 MB view details)

Uploaded CPython 3.12+musllinux: musl 1.2+ ARM64

prompting_press-0.3.0-cp312-abi3-manylinux_2_28_x86_64.whl (1.5 MB view details)

Uploaded CPython 3.12+manylinux: glibc 2.28+ x86-64

prompting_press-0.3.0-cp312-abi3-manylinux_2_28_aarch64.whl (1.4 MB view details)

Uploaded CPython 3.12+manylinux: glibc 2.28+ ARM64

prompting_press-0.3.0-cp312-abi3-macosx_11_0_arm64.whl (1.3 MB view details)

Uploaded CPython 3.12+macOS 11.0+ ARM64

File details

Details for the file prompting_press-0.3.0.tar.gz.

File metadata

  • Download URL: prompting_press-0.3.0.tar.gz
  • Upload date:
  • Size: 196.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for prompting_press-0.3.0.tar.gz
Algorithm Hash digest
SHA256 866a55acbddcffb97b2f1b7e63300eb8b57c2c4c50911b7285de6baeb7647009
MD5 8c7cbbbb6de92fea4500b9828cc904c5
BLAKE2b-256 a3b6e2da06e3bb242fbcb9ff1fd985ca184da4e252c6877906bf853f3baabc1b

See more details on using hashes here.

Provenance

The following attestation bundles were made for prompting_press-0.3.0.tar.gz:

Publisher: release.yml on prompting-press/prompting-press

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

File details

Details for the file prompting_press-0.3.0-cp312-abi3-win_amd64.whl.

File metadata

File hashes

Hashes for prompting_press-0.3.0-cp312-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 016794d82e661f9f78a72e9f45111bc2e604fbf11b9ce4aa2dc51cc21b5810e0
MD5 f1fc1ca55e1c2e0aaf2aeb21efc55bbf
BLAKE2b-256 d00371b6cdeb86d4cd65bfc250adcca11365d5099d9fb22c3cc1fdccfb25d7e1

See more details on using hashes here.

Provenance

The following attestation bundles were made for prompting_press-0.3.0-cp312-abi3-win_amd64.whl:

Publisher: release.yml on prompting-press/prompting-press

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

File details

Details for the file prompting_press-0.3.0-cp312-abi3-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for prompting_press-0.3.0-cp312-abi3-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 f4071fbbde8502cd0d1066b12f646f212a70b52d89dce5ce886c408c3b5fd941
MD5 c551440b9d2a2deb84138ae5a3c6f815
BLAKE2b-256 72191485967f2e393fac9555dea7bba6688987ddf3a9558942f975c2127420f6

See more details on using hashes here.

Provenance

The following attestation bundles were made for prompting_press-0.3.0-cp312-abi3-musllinux_1_2_x86_64.whl:

Publisher: release.yml on prompting-press/prompting-press

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

File details

Details for the file prompting_press-0.3.0-cp312-abi3-musllinux_1_2_aarch64.whl.

File metadata

File hashes

Hashes for prompting_press-0.3.0-cp312-abi3-musllinux_1_2_aarch64.whl
Algorithm Hash digest
SHA256 3e93f82c23c399ac3d4af20c2a34351d69e121188f3b56e3360582b832e680db
MD5 f22a731fbaf8aadc52cab4a143826cd8
BLAKE2b-256 bac0ceee891fcec887bd2f7744305a7fbd86b574406ea917e4a452d236c0efcc

See more details on using hashes here.

Provenance

The following attestation bundles were made for prompting_press-0.3.0-cp312-abi3-musllinux_1_2_aarch64.whl:

Publisher: release.yml on prompting-press/prompting-press

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

File details

Details for the file prompting_press-0.3.0-cp312-abi3-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for prompting_press-0.3.0-cp312-abi3-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 78c92f3354fb842bccb718de2173294bd566e8facd676cb74ae8f12f833d7078
MD5 460d42f5c229a335a34565d8329b6bdb
BLAKE2b-256 b334e5aa8f8a7f97401d06f3a068f7efdf7e973cd92b14bec2897908c5cda3f3

See more details on using hashes here.

Provenance

The following attestation bundles were made for prompting_press-0.3.0-cp312-abi3-manylinux_2_28_x86_64.whl:

Publisher: release.yml on prompting-press/prompting-press

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

File details

Details for the file prompting_press-0.3.0-cp312-abi3-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for prompting_press-0.3.0-cp312-abi3-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 01bf1c72040ca418554b58a33c64b5c6eadf4103616f8127a4a93b83f4a3636a
MD5 fbbd4d4388b9d330b02f433cf22237f9
BLAKE2b-256 dfd7ba258323bb1112382a2641e48806bc5dea389fa11a159fa613e59644436b

See more details on using hashes here.

Provenance

The following attestation bundles were made for prompting_press-0.3.0-cp312-abi3-manylinux_2_28_aarch64.whl:

Publisher: release.yml on prompting-press/prompting-press

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

File details

Details for the file prompting_press-0.3.0-cp312-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for prompting_press-0.3.0-cp312-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 eac107eb1433be2e3ee1ce6bf53881580882b555985e5f01202baa6535fd6dd7
MD5 263e58b0ec222a465ce0df46bd65a76c
BLAKE2b-256 6a024dbc23ef1c920b3dc3058bdedc15c6333b25c7c961780b9058c934db7cd6

See more details on using hashes here.

Provenance

The following attestation bundles were made for prompting_press-0.3.0-cp312-abi3-macosx_11_0_arm64.whl:

Publisher: release.yml on prompting-press/prompting-press

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

Release history Release notifications | RSS feed

0.5.0

7 files

0.3.2

7 files

0.3.1

7 files

This release

0.3.0 This release

7 files

0.2.0

7 files

Supported by

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