What is Prompt Engineering?

Prompt Engineering is the practice of optimizing a prompt to get the best response from a language model.

Tips

Reference: Behind the prompt: Prompting tips for Claude.ai

  1. Describe your task
  2. Use XML tags to mark different parts of your prompt
    1. <text> </text>
    2. <example> </example>
  3. Give examples
  4. Make use of the long context
    1. Upload files to project
  5. Let Claude think
    1. Use thinking tags
      1. “When you reply, first plan how you should answer within <thinking> </thinking> XML tags.”