Skip to main content

A small simple prompt manager for LLM prompts

Project description

Prompt Manager

A small simple prompt manager for LLM prompts.

Usage

from prompt_manager.prompt_manager import get_prompt, render_prompt

prompt = get_prompt("my-prompt.md")
print(prompt)

prompt = render_prompt(prompt, {"name": "John"})
print(prompt)

Features

  • Flexible variable substitution with render_prompt()

  • Include files from the prompts directory, or from a url with get_prompt()

  • Combine files, e.g. roleplay-prompt.txt + output-format-prompt.js

  • Handle not-quite-json output from LLMs with parse_json()

Contributing

Contributions are welcome! Please submit a pull request or open an issue for any bugs or feature requests.

License

This project is licensed under the MIT License.

Contact

For questions or comments, please contact the project maintainer, Daniel Winterstein.

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

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

ai_prompt_manager-0.1.0-py3-none-any.whl (5.6 kB view details)

Uploaded Python 3

File details

Details for the file ai_prompt_manager-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for ai_prompt_manager-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b60c3df3d25cf1a609a92bd443b028a9dbde34de006e615d9ce87c4ce95d0dd2
MD5 d9d39b3197f760a16cccce005a187db7
BLAKE2b-256 af3bef6b7453081e6c1a13800623ac21d450aa90d2b49170083d47833eeb4b51

See more details on using hashes here.

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