17 ms·
I recognize there's plenty of catnip here when it comes to calling this "engineering" or not, however, whatever you want to call it (prompt fiddling?), the tech
by valgaze 3y ago
I recognize there's plenty of catnip here when it comes to calling this "engineering" or not, however, whatever you want to call it (prompt fiddling?), the techniques are crucial if you want to achieve reasonably consistent output from current-state LLMs. As models improve concerns about context window limitations will be reduced and it will be easier to discern user intent.
These are good straight-to-the-point guides:
- Prompt Engineering by BrexHQ: https://github.com/brexhq/prompt-engineering https://github.com/brexhq/prompt-engineering
- OpenAI guidance: https://help.openai.com/en/articles/6654000-best-practices-for-prompt-engineering-with-openai-api https://help.openai.com/en/articles/6654000-best-practices-f...
- https://devblogs.microsoft.com/dotnet/gpt-prompt-engineering-openai-azure-dotnet/ https://devblogs.microsoft.com/dotnet/gpt-prompt-engineering...
- (great examples): https://www.deeplearning.ai/short-courses/chatgpt-prompt-engineering-for-developers/ https://www.deeplearning.ai/short-courses/chatgpt-prompt-eng...
- (~hr) Karpathy talk: https://www.youtube.com/watch?v=bZQun8Y4L2A https://www.youtube.com/watch?v=bZQun8Y4L2A
tl;dr:
- Begin with the best and most forgiving model available, optimizing it later if necessary.
- Write your prompts in a clear, specific, and detailed manner
- Be mindful, however, of the tradeoff between including more detail and increasing latency or cost.
- If you're doing any complex reasoning, ask the model to show its work, help "stretch out" computation over more tokens
- "Escape" any included or quoted text properly to avoid confusing the model.
- Keep track of your token budget, considering the context window in conversations and response length.
- Employ an iterative process of measuring, adjusting, and improving your prompt engineering techniques.
- oars 3y agoThanks for sharing this list! (parent comment)