-1
Daily
9,681
stars
673
forks
81
watchers
16
prs
30
issues
0
releases
README
gpt-prompt-engineer
Be the first to know when I publish new AI builds + demos!
Overview
Prompt engineering is kind of like alchemy. There's no clear way to predict what will work best. It's all about experimenting until you find the right prompt. gpt-prompt-engineer is a tool that takes this experimentation to a whole new level.
Simply input a description of your task and some test cases, and the system will generate, test, and rank a multitude of prompts to find the ones that perform the best.
New 3/20/24: The Claude 3 Opus Version
I've added a new version of gpt-prompt-engineer that takes full advantage of Anthropic's Claude 3 Opus model. This version auto-generates test cases and allows for the user to define multiple input variables, making it even more powerful and flexible. Try it out with the claude-prompt-engineer.ipynb notebook in the repo!
New 3/20/24: Claude 3 Opus - Haiku Conversion Version
This notebook enables you to build lightning-fast, performant AI systems at a fraction of the typical cost. By using Claude 3 Opus to establish the latent space and Claude 3 Haiku for the actual generation, you can achieve amazing results. The process works by leveraging Opus to produce a collection of top-notch examples, which are then used to guide Haiku in generating output of comparable quality while dramatically reducing both latency and cost per generation. Try it out with the opus-to-haiku-conversion.ipynb notebook in the repo!
Features
- Prompt Generation: Using GPT-4, GPT-3.5-Turbo, or Claude 3 Opus, gpt-prompt-engineer can generate a variety of possible prompts based on a provided use-case and test cases.
- Prompt Testing: The real magic happens after the generation. The system tests each prompt against all the test cases, comparing their performance and ranking them using an ELO rating system.
- ELO Rating System: Each prompt starts with an ELO rating of 1200. As they compete against each other in generating responses to the test cases, their ELO ratings change based on their performance. This way, you can easily see which prompts are the most effective.
- Classification Version: The gpt-prompt-engineer -- Classification Version notebook is designed to handle classification tasks. It evaluates the correctness of a test case by matching it to the expected output ('true' or 'false') and provides a table with scores for each prompt.
- Claude 3 Version: The claude-prompt-engineer notebook is designed to work with Anthropic's Claude 3 Opus model. It auto-generates test cases and allows for multiple input variables, making it even more powerful and flexible.
- Claude 3 Opus - Haiku Conversion Version: Designed to preserve Opus' quality for your use-case while getting the speed + cost benefits of using Haiku.
- Weights & Biases Logging: Optional logging to Weights & Biases of your configs such as temperature and max tokens, the system and user prompts for each part, the test cases used and the final ranked ELO rating for Top issues
#8What are "test_cases"?6 comments · 2023-07-06#25JSONDecodeError4 comments · 2024-03-20#18Is it possible to reduce the computational complexity?4 comments · 2023-07-19#6Thoughts on why this tool is useful4 comments · 2023-07-06#14Does set logit_bias to 100 lead the model choice between 'A' and 'B' essentially random?2 comments · 2023-07-13#3NameError: name 'wandb' is not defined2 comments · 2023-07-04#38Getting KeyError: 'content' at Step 41 comments · 2024-04-08#32是因为我的claude api key 没权限吗1 comments · 2024-03-23