Prompts#

This module provides utilities for loading and rendering Jinja2-based markdown prompt templates from directories or files.

Prompt Template Loading and Rendering#

The module supports recursive loading of all markdown templates in a directory and rendering individual templates with custom arguments.

Note

  • Templates must use the .md extension and be compatible with Jinja2 syntax.

Functions#

load_all

Recursively load all markdown prompt templates from a directory into a dictionary.

load_prompt

Load and render a single prompt template from a file.