Skip to main content

mprompt is a CLI tool that generates prompts for your projects

Project description

mprompt

mprompt is a CLI tool that helps you generate high-quality, structured prompts for your projects. Instead of writing prompts from scratch, you have a short conversation with an AI assistant that asks the right questions and turns your ideas into a ready-to-use prompt—then copies it to your clipboard.

What it does

  • Guided conversation: You describe what you want to prompt for (e.g. “I need a prompt that makes the AI act like a senior DevOps engineer and write deployment runbooks”). The assistant asks clarifying questions about role, audience, task, constraints, and output format.
  • Structured output: When it has enough information, it produces a structured prompt with:
    • Persona — the role or identity the AI should adopt
    • Context — background, audience, or relevant history
    • Task — the main goal or mission
    • Examples — optional few-shot examples (invented by the assistant when appropriate)
    • Constraints — rules, limits, or things to avoid
    • Output format — structure and tone of the output (e.g. Markdown, JSON, formal email)
  • Clipboard: The final prompt is copied to your clipboard so you can paste it into your IDE, docs, or another tool.

Requirements

  • Python 3.12+
  • Google API key: Set the GOOGLE_API_KEY environment variable. The tool uses Google’s Gemini model (via pydantic-ai).

Installation

From the project root:

pip install .

Or install in development mode:

pip install -e .

Usage

  1. Set your API key:

    export GOOGLE_API_KEY="your-api-key-here"
    

    On Windows (PowerShell):

    $env:GOOGLE_API_KEY = "your-api-key-here"
    
  2. Run the CLI:

    mprompt
    
  3. Answer the assistant’s questions. When it has enough information, it will show you the generated prompt and ask if you’re okay with it. Reply y to accept (and copy to clipboard), or describe what you’d like to change for another round.

  4. Paste the prompt wherever you need it (Cursor, ChatGPT, your app, etc.).

Example flow

> Agent: Hello, I'm a meta-prompting assistant. I'll help you generate a high-quality prompt for your project. Please describe what you would like to prompt.

> You: I want a prompt for writing Git commit messages in conventional commits style.

> Agent: Who will be using this—solo devs or a team? Any project conventions?

> You: Small team, Python project, we use feat/fix/docs etc.

… (a few more exchanges) …

> Agent: [shows structured prompt]

> Are you okay with this output? (y for yes, or describe what you would like to change): y

> Copied to clipboard.

License

MIT. See the project metadata for author and 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

mprompt-0.1.1.tar.gz (143.6 kB view details)

Uploaded Source

Built Distribution

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

mprompt-0.1.1-py3-none-any.whl (6.5 kB view details)

Uploaded Python 3

File details

Details for the file mprompt-0.1.1.tar.gz.

File metadata

  • Download URL: mprompt-0.1.1.tar.gz
  • Upload date:
  • Size: 143.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.11 {"installer":{"name":"uv","version":"0.10.11","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for mprompt-0.1.1.tar.gz
Algorithm Hash digest
SHA256 38764cc98343aebc07a0275652ff7f8f2c4fa4cf335b46f416f29fc8fa88943a
MD5 e55378658375c3093000627a7327f11a
BLAKE2b-256 595ad33f1672bbf041bd8e6a7ecfadfe5469ac9370081b76aca49306374786ee

See more details on using hashes here.

File details

Details for the file mprompt-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: mprompt-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 6.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.11 {"installer":{"name":"uv","version":"0.10.11","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for mprompt-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 5c72c0cc24a571baacc117bac65afc372ee252f590d1eeaf8289585cb00c02a9
MD5 3ef75296461113e986996ba9ff56d096
BLAKE2b-256 2888e6b3e7420025a64ab1e6b307c38729a8814ef84adb9bcb8f4ac2b128e86b

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