Here are a few impressive points from youtube (AI prompt engineering: A deep dive) where Anthropic engineers shared their prompt writing tips and experiences.
Impressive Prompt Writing Tips
- When the model makes a mistake, it can be helpful to ask why it was wrong and directly ask the model how to instruct it next time to avoid the mistake.
- When the model faces unexpected input or ambiguous situations, you should provide clear instructions on what to do (e.g., output an "UNCERTAIN" tag) to prevent it from giving a wrong answer.
- Inducing the model to explain its reasoning process before providing an answer (Chain of Thought) improves the model's accuracy.
- You can ask the model to "interview" you. When it's difficult to clearly grasp what you want, you can get help constructing the prompt by asking the model to ask you questions and elicit the necessary information.
Tips for Improving Prompt Engineering Skills
- Read many other people's prompts and model outputs: You can learn a lot by looking at great prompts, analyzing their structure and intent, and by carefully observing the model's outputs.
- Attempt many conversations with the model: You need to practice improving prompts by directly and repeatedly communicating with the model.
- Show your prompts to others: Showing a prompt you've written to someone without prior knowledge of the task can help you discover parts that are not clear.
- Test the model's limits: Trying the most difficult tasks you think the model cannot do and exploring its limits leads to the greatest learning.
인상 깊었던 프롬프트 작성 팁
- 모델이 실수를 했을 때, 왜 틀렸는지 묻고, 다음에는 어떻게 지시해야 틀리지 않을지 모델에게 직접 물어보는것이 도움이 될 수 있다.
- 모델이 예상치 못한 입력이나 모호한 상황에 직면했을 때 어떻게 해야 할지 (예: "불확실" 태그 출력) 명확한 지시를 제공하여 잘못된 답변을 내놓는 것을 방지해야 한다.
- 모델이 답변을 제공하기 전에 자신의 추론 과정을 설명하도록 유도하면(Chain of Thought) 모델의 정확도가 향상된다.
- 모델에게 자신을 "인터뷰"하도록 요청할 수 있다. 자신이 원하는 바를 명확히 파악하기 어려울 때, 모델한테 나에게 필요한 정보를 질문하고 이끌어내도록 요청하여 프롬프트를 구성하는 데 도움을 받을 수 있다.
프롬프트 엔지니어링 기술 향상 팁
- 다른 사람의 프롬프트와 모델 출력 많이 읽기: 훌륭한 프롬프트를 보고 그 구조와 의도를 분석하며, 모델의 출력을 면밀히 관찰하면 많은 것을 배울 수 있다.
- 모델과 많은 대화 시도: 직접 모델과 반복적으로 소통하면서 프롬프트를 개선하는 연습을 해야 한다.
- 타인에게 프롬프트 보여주기: 자신이 작성한 프롬프트를 그 작업에 대한 사전 지식이 없는 다른 사람에게 보여주면, 명확하지 않은 부분을 발견하는 데 도움이 된다.
- 모델의 한계 시험: 모델이 할 수 없을 것이라고 생각하는 가장 어려운 작업을 시도하며 모델의 한계를 탐색하는 것이 가장 큰 학습으로 이어진다.
Top comments (0)