prompty
Prompty is a new asset class and format for LLM prompts that aims to provide observability, understandability, and portability for developers. It includes spec, tooling, and a runtime. This Prompty runtime supports Python
What it is and what it does
Prompty is a Python runtime that executes LLM prompts stored in a standardized `.prompty` file format. The format combines YAML metadata (model configuration, sample inputs, authors) with prompt templates written in Jinja2, allowing you to define and version control prompts separately from application code. The runtime loads these files, interpolates variables, and routes execution to the appropriate LLM API (Azure OpenAI, OpenAI, or serverless models via Azure AI Inference).
The package is designed to accelerate prompt engineering workflows by providing observability through a pluggable tracing system—built-in tracers write execution details to console or JSON files, and you can integrate OpenTelemetry or custom hooks. It includes a CLI tool for running prompts directly from the command line and a VS Code extension for interactive prompt development. Dependencies are minimal: pyyaml for config parsing, jinja2 for templating, python-dotenv for environment variables, click for CLI, and aiofiles for async file operations.
Use it for:
- Run and iterate on LLM prompts defined in `.prompty` files without embedding them in Python code, enabling non-developers to edit prompts via VS Code.
- Trace and debug LLM API calls and prompt execution with built-in console or JSON output, or integrate with OpenTelemetry for centralized observability.
- Execute prompts from the command line with environment variable injection, useful for CI/CD pipelines or batch prompt testing.
- Switch between Azure OpenAI, OpenAI, and serverless model endpoints by changing configuration in the `.prompty` file without code changes.
- Build reusable prompt libraries with version control, sample inputs, and metadata for team collaboration on prompt engineering.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Prompty is a Python runtime for executing LLM prompts defined in a language-agnostic `.prompty` file format, with built-in support for Azure OpenAI, OpenAI, and serverless model invokers, plus tracing and CLI tooling.
Yes, with conditions. Install if you need a structured, version-controlled way to manage and execute LLM prompts across multiple endpoints (Azure, OpenAI, serverless) with built-in tracing and CLI support. The low install friction and active maintenance are favorable. However, verify the status of the two known vulnerabilities (GHSA-wxhm-2mq7-7697, PYSEC-2026-3538) before deploying to production, and confirm whether optional invoker dependencies require explicit extras installation.
Install
prompty on PyPI
pip
pip install promptyuv
uv add promptypoetry
poetry add promptyInstalling prompty
Before you install
Low install friction with a pure-Python wheel and five lightweight runtime dependencies. The package is actively maintained with recent commits and a steady release cadence since July 2024.
License in practice
MIT license permits unrestricted use, modification, and distribution with minimal restrictions, making it suitable for commercial and open-source projects alike.
Quickstart
pip install prompty
import prompty
import prompty.azure
response = prompty.execute("path/to/prompt.prompty")
print(response)
Requires Python >= 3.9. To use Azure OpenAI invoker, install with: pip install "prompty[azure]". Prompty files must reference a valid LLM endpoint via environment variables or configuration.
Verify before relying
- Whether the two known vulnerabilities (GHSA-wxhm-2mq7-7697, PYSEC-2026-3538) affect the current version or have been patched.
- Whether optional dependencies (e.g., for Azure or OpenAI invokers) are automatically installed or require explicit extras installation.
- Performance characteristics and latency overhead of the tracing mechanism in production workloads.
Package facts
| License | MIT (permissive) |
| Python support | supports the current Python release (>=3.9) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 5 — pyyaml, jinja2, python-dotenv, click, aiofiles |
| Maintenance | actively maintained — 499 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 508,343/month — #6,279 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | 2 — GHSA-wxhm-2mq7-7697, PYSEC-2026-3538 |
Evidence: prompty-0.1.50-py3-none-any.whl
Tags
More Artificial Intelligence packages
LiteLLM provides a unified Python interface to…
permissive · top 100 on PyPI
huggingface-hubClient library and CLI tool for downloading,…
permissive · top 100 on PyPI
langchainLangChain provides a framework for building…
permissive · top 1,000 on PyPI
hf-xethf-xet provides chunk-based deduplication and…
permissive · top 1,000 on PyPI
tokenizersTokenizers converts raw text into token…
permissive · top 1,000 on PyPI
transformersTransformers provides a unified framework for…
permissive · top 1,000 on PyPI
promptflowPrompt flow is a development suite for…
permissive · top 15,000 on PyPI
prompthub-pyFetches prompt templates from Prompt Hub or…
permissive · top 15,000 on PyPI
promptlayerPromptLayer is a Python SDK for managing,…
permissive · top 15,000 on PyPI
pdd-cliPDD is a CLI tool that treats natural-language…
permissive · top 15,000 on PyPI
ell-aiell-ai is a functional prompt engineering…
permissive · top 15,000 on PyPI
banksBanks is a template language and prompt…
permissive · top 5,000 on PyPI
promptflow-tracingCaptures and visualizes the internal execution…
permissive · top 15,000 on PyPI
llmLLM is a CLI tool and Python library for…
permissive · top 15,000 on PyPI
promptflow-devkitProvides a development toolkit for building,…
permissive · top 15,000 on PyPI
opentelemetry-instrumentation-openaiCaptures traces of OpenAI API calls (prompts,…
permissive · top 5,000 on PyPI