lypsoty112 / Prompt-builder

Prompt Builder is a small Python application that implements the principles outlined in the paper "Principled Instructions Are All You Need for Questioning LLaMA-1/2, GPT-3.5/4". It allows users to generate natural language prompts adhering to specific rules and guidelines defined in the paper.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Prompt-builder

Prompt Builder is a small Python application that generates natural language prompts based on documentation and best practices from OpenAI, Google (https://ai.google.dev/docs/prompt_best_practices & https://developers.google.com/machine-learning/resources/prompt-eng), Anthropic, Cohere, and other leading AI companies. It utilizes GPT-4 to generate prompts adhering to specific rules and guidelines.

Usage

Simply past the prompt you want to optimize in the text box and click the "Optimize" button. The application will then generate a prompt that adheres to the guidelines outlined in the paper.

Installation

Either use the online version, or go to the GitHub and download the repository.

Repository installation

Install the repository's packages using

pip install -r requirements.txt

(Optional): Set your API key in a .envfile as seen in the .env.template file.

Then, run the project using

streamlit run main.py

About

Prompt Builder is a small Python application that implements the principles outlined in the paper "Principled Instructions Are All You Need for Questioning LLaMA-1/2, GPT-3.5/4". It allows users to generate natural language prompts adhering to specific rules and guidelines defined in the paper.

License:MIT License


Languages

Language:Python 100.0%