Skip to content

promptic

A decorator-based Python library for LLM prompts

Visit official site

What promptic is

The library is described as a lightweight decorator-based Python library that simplifies LLM interaction through litellm in a few lines of code.

What you can do with it

  • Define prompts with decorators and docstrings
  • Insert function arguments automatically
  • Enforce output with Pydantic models

Application scenarios

  • Build a function that queries the US president
  • Return a country capital via a Pydantic model
  • Stream responses to generate a poem

Pros & cons

✓ What we like

  • stream=True gives real-time responses
  • litellm compatibility with many LLMs

! What to watch out for

  • Prompts rely on docstring placeholders
  • Structured output needs a defined schema

FAQ

What does it build on?

The material states it uses litellm.

Can responses stream?

The feature list says stream=True is supported.

Last reviewed: 2026-11-15

More AI coding tools tools

View all →

How we review