An AI-powered Python library for generating, refining, scoring, translating, and exporting prompts using the CRAFT framework.
Project description
Prompt Generator
An AI-powered Python library for generating, refining, scoring, translating, and exporting high-quality prompts using the CRAFT Prompt Engineering Framework.
โจ Features
- AI-powered prompt generation
- CRAFT framework-based prompt creation
- Prompt quality scoring using AI
- Prompt refinement for improved clarity and effectiveness
- Prompt translation into multiple languages
- Export prompts as UTF-8 text files
- Clean and beginner-friendly API
- Modular and scalable architecture
๐ Version
Current Version: v1.0.0
Included Features
- Generate Prompt
- Score Prompt
- Refine Prompt
- Translate Prompt
- Export Prompt (.txt)
๐ฆ Installation
Clone the repository
git clone https://github.com/SatejGujar25/prompt-generator.git
Move into the project directory SOFTWARE.
cd prompt-generator
Install the required packages
pip install -r requirements.txt
โ๏ธ Requirements
- Python 3.10+
- Groq API Key
๐ Project Structure
AI_Prompt/
โ
โโโ prompt_generator/
โ โโโ __init__.py
โ โโโ generator.py
โ โโโ llm.py
โ โโโ craft.py
โ โโโ scorer.py
โ โโโ refiner.py
โ โโโ translator.py
โ โโโ exporter.py
โ
โโโ examples/
โ
โโโ README.md
โโโ LICENSE
โโโ requirements.txt
โโโ pyproject.toml
๐ API
PromptGenerator
| Method | Description |
|---|---|
gen_prompt(n) |
Generates one or more prompts |
Score() |
Evaluates prompt quality |
Refine_prompt() |
Improves an existing prompt |
Translate(language) |
Translates the prompt |
Export(filename) |
Exports prompt to a UTF-8 text file |
๐ง Framework
Prompt Generator internally uses the CRAFT Prompt Engineering Framework.
- C โ Context
- R โ Role
- A โ Action
- F โ Format
- T โ Task
The generated prompt is returned as a natural paragraph while internally preserving all CRAFT components.
๐ Roadmap
โ Version 1.0
- Prompt Generation
- Prompt Scoring
- Prompt Refinement
- Prompt Translation
- TXT Export
๐ค Contributing
Contributions, suggestions, and improvements are always welcome.
Feel free to fork the repository and submit a pull request.
๐ License
This project is licensed under the MIT License.
๐จโ๐ป Author
Satej Gujar
โญ Support
If you find this project useful, consider giving it a โญ on GitHub.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file craft_prompt_generator-1.0.0.tar.gz.
File metadata
- Download URL: craft_prompt_generator-1.0.0.tar.gz
- Upload date:
- Size: 7.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
be16c5d11d2d9302d01256f04b696a63bb754ab7ee335451848e7734ffa20d10
|
|
| MD5 |
de12c2554202119aae4799def691a304
|
|
| BLAKE2b-256 |
20b7c1552c3590bf4067d7f35b4def37fd2e9bec92ff184d3c9083885d1caf6f
|
File details
Details for the file craft_prompt_generator-1.0.0-py3-none-any.whl.
File metadata
- Download URL: craft_prompt_generator-1.0.0-py3-none-any.whl
- Upload date:
- Size: 9.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7c14539ff91adf1e8f43c1f07ecb0d18f0fb38989751c5ec4267331b46ceb220
|
|
| MD5 |
d24ce50328c497f3f0e606d5bdc34298
|
|
| BLAKE2b-256 |
0b3c2d2add796e314a04ac60ab67c7b7d02b3341ab0d833ef35535b19a386f4c
|