Skip to main content

An AI toolkit to supercharge your prompts.

Project description

Logo
Brings structure and reproducibility to prompt engineering
PyPI versionLicense: MITPython versions

A powerful CLI toolkit and Python SDK to secure, manage, and develop your LLM prompts like reusable code.



📑 Explore the full Documenentation here - Docs

(This README provides an overview. The full site contains detailed guides, API references, and advanced tutorials.)


[-- YOUR VIDEO DEMO WILL GO HERE --]

A brief video showcasing the core workflow from initialization to AI-powered improvement.


Why use it ?

Managing prompts across a team or a large project can be chaotic. Plain text files lack versioning, are prone to accidental changes, and have no built-in quality control. Prompt Lockbox brings the discipline of software engineering to your prompt development workflow.

Scattered Prompts

Problem: Your team’s best prompts are lost in a chaotic mess of text files, Slack messages, and Google Docs. No one knows where the “official” version is, leading to confusion and duplicated effort.

Solution: Prompt Lockbox creates a centralized and structured library, making it effortless for your entire team to find and use the correct prompt.

Untracked Versions

Problem: You tweak a great prompt and accidentally make it worse, with no way to go back to the version that worked.

Solution: Prompt Lockbox provides Git-like versioning for prompts. Safely create new versions and manage modifications with plb version, just like code.

Accidental Production Changes

Problem: A critical prompt is changed without approval, breaking your application and causing unpredictable outputs.

Solution: Prompt Lockbox lets you lock and secure key prompts with plb lock. The system instantly detects any unauthorized edits with plb verify, ensuring production reliability.

Reinventing the Wheel

Problem: Your team wastes time building prompts that already exist because they’re impossible to find.

Solution: Prompt Lockbox makes your entire library instantly searchable. Find what you need in seconds with powerful, context-aware search (fuzzy, hybrid, splade).

Poor Documentation

Problem: You write a brilliant prompt but have no time to document it, making it unusable for others (or your future self).

Solution: Prompt Lockbox uses AI to automate documentation. One command (plb prompt document) generates a clear description and search tags, turning your prompts into reusable assets.


Features

  • Integrity & Security: Lock prompts to generate a checksum. The plb verify command ensures that production prompts haven't been tampered with since they were last approved.

  • Version Control First: Automatically create new, semantically versioned prompt files with plb version, making it easy to iterate and experiment safely without breaking existing implementations.

  • AI features:

    • Auto-Documentation: plb prompt document uses an AI to analyze your prompt and generate a concise description and relevant search tags.
    • Auto-Improvement: plb prompt improve provides an expert critique and a suggested, improved version of your prompt template, showing you a diff of the changes.
    • Direct Execution: Execute prompts directly against your configured LLMs (OpenAI, Anthropic, Ollama, HuggingFace) right from the CLI.
  • Advanced Search: Don't just grep. Build a local search index (hybrid TF-IDF + FAISS or splade) to find the right prompt instantly using natural language queries.

  • Flexible Configuration: An interactive wizard (plb configure-ai) makes it trivial to set up any provider and model, securely storing API keys in a local .env file.

Installation

The base toolkit can be installed directly from PyPI:

pip install prompt-lockbox

To include support for specific AI providers or features, install the optional "extras". You can combine multiple extras in one command.

# To use OpenAI models
pip install 'prompt-lockbox[openai]'

# To use HuggingFace models (includes torch)
pip install 'prompt-lockbox[huggingface]'

# To use the advanced search features (includes faiss-cpu)
pip install 'prompt-lockbox[search]'

# To install everything
pip install 'prompt-lockbox[all]'

▶️ Quickstart: Your First 5 Minutes

This guide takes you from an empty directory to executing your first AI-powered prompt.

1. Initialize Your Project Create a directory and run init. This sets up the required file structure.

mkdir my-prompt-project && cd my-prompt-project
plb init

2. Configure Your AI Provider Run the interactive wizard to connect to your preferred LLM provider. It will securely save your API keys to a local .env file.

# This launches the interactive setup wizard
plb configure-ai

3. Create Your First Prompt The create command will guide you through making a new prompt file.

# This launches an interactive prompt creation wizard
plb create

Follow the steps to name your prompt (e.g., "email-formatter"). Now, open the new file at prompts/email-formatter.v1.0.0.yml and add your template logic.

4. Run and Execute Test your prompt by rendering it with variables, then execute it with the --execute flag to get a live AI response.

# Render the prompt template with a variable
plb run email-formatter --var user_request="draft a polite follow-up email"

# Send the rendered prompt to your configured AI for a response
plb run email-formatter --var user_request="draft a polite follow-up email" --execute

Full Documentation

This README is just the beginning. For detailed guides, the complete command reference, and SDK usage examples, please visit our Prompt Lockbox Documentation.

Contributing

We're thrilled you're interested in contributing to Prompt Lockbox! Contributions are what make the open-source community such an amazing place to learn, inspire, and create. Every contribution, from a typo fix to a new feature, is greatly appreciated.

To get started, please read our full Contributing Guide.

This guide contains detailed information on our code of conduct, development setup, and the process for submitting pull requests.

How You Can Help

Whether you're reporting a bug, suggesting a feature, improving the documentation, or submitting code, your help is welcome. The best place to start is by checking our GitHub Issues and Discussions.

License

This project is licensed under the MIT License. See the LICENSE file for details.

Project details


Download files

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

Source Distribution

prompt_lockbox-0.1.3.tar.gz (46.9 kB view details)

Uploaded Source

Built Distribution

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

prompt_lockbox-0.1.3-py3-none-any.whl (58.8 kB view details)

Uploaded Python 3

File details

Details for the file prompt_lockbox-0.1.3.tar.gz.

File metadata

  • Download URL: prompt_lockbox-0.1.3.tar.gz
  • Upload date:
  • Size: 46.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.3 CPython/3.11.5 Windows/10

File hashes

Hashes for prompt_lockbox-0.1.3.tar.gz
Algorithm Hash digest
SHA256 8697f579369929550fa82d16620d90dca487e9594cfd51ea2319939c95cab097
MD5 5798ff536e1c998d394336d41553ccb8
BLAKE2b-256 61f9501d20e8f170fa2f27931cc5514e28c1cb345e68a1dc0b173826683dfd0b

See more details on using hashes here.

File details

Details for the file prompt_lockbox-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: prompt_lockbox-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 58.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.3 CPython/3.11.5 Windows/10

File hashes

Hashes for prompt_lockbox-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 53b0842dfcff3edd81ee7a6e43b5e0a4e9123d5d4bfa9769f3f251792b4d7dcd
MD5 2633e79c6be6269f3cd93fcef6d8ec9d
BLAKE2b-256 fc7d53e909ebd14a0331c2e487bdb7dda729da281a7a449079b344522f066039

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