Skip to main content

A collection of prompts

Project description

bartste-prompts

A command-line tool to generate AI prompts for code modifications.

Overview

This tool generates prompts for:

  • docstrings: Add Google-style docstrings.
  • typehints: Enhance code with proper type hints.
  • refactor: Refactor code following best practices.
  • fix: Fix issues in the code.
  • unittests: Generate unit tests for your code.

The prompts can be passed directly to external tools such as aider to executed them using an LLM.

Installation

To install bartste-prompts, you can either:

  • Install via pip:
pip install git+https://github.com/bartste/bartste-prompts.git
  • Or clone the repository and install it directly:
pip install .

Usage

Run the following to get info about the cli:

prompts --help

Examples

  • Generate a prompt that describes a refactor the myfile.py file.

    prompts refactor -f python myfile.py
    
  • Send a prompt for writing docstrings to aider.

    prompts docstrings --filetype python --action aider myfile.py
    

    As is shown, a prompt can be redirected to an external tool using the --action option. Currently, json and aider are supported.

Contributing

See CONTRIBUTING.md for guidelines on contributing.

License

See LICENSE for licensing 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

bartste_prompts-0.2.0.tar.gz (13.2 kB view details)

Uploaded Source

Built Distribution

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

bartste_prompts-0.2.0-py3-none-any.whl (16.8 kB view details)

Uploaded Python 3

File details

Details for the file bartste_prompts-0.2.0.tar.gz.

File metadata

  • Download URL: bartste_prompts-0.2.0.tar.gz
  • Upload date:
  • Size: 13.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for bartste_prompts-0.2.0.tar.gz
Algorithm Hash digest
SHA256 4a4789239b63390a0e1767f13afe2fa2436651e2ce06bc58433f830404b41181
MD5 96c976b3e311f43f0527340d27e7ead1
BLAKE2b-256 b74f414935d483317f6c1c3fbe32d5a27695b3851d6b0c15f0915a3fa9f2a6f9

See more details on using hashes here.

Provenance

The following attestation bundles were made for bartste_prompts-0.2.0.tar.gz:

Publisher: release.yml on BartSte/bartste-prompts

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file bartste_prompts-0.2.0-py3-none-any.whl.

File metadata

File hashes

Hashes for bartste_prompts-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 cb9f5a5d46e465bfdab1e8bc998c66b25283b68813768c1801bd4d808b68a9c6
MD5 6e198511f0785d5049c11d0be7213d4f
BLAKE2b-256 48a5ddc1c7ea2c4e75b78edb7685a1af02b1bcb92dd8716606148c2790b3e004

See more details on using hashes here.

Provenance

The following attestation bundles were made for bartste_prompts-0.2.0-py3-none-any.whl:

Publisher: release.yml on BartSte/bartste-prompts

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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