Improving the prompt to get better results
If the main way you interact with LLMs is using ChatGPT or Microsoft Copilot, you may have the impression that you can use very short prompts to get the results you want. As explained in Chapter 1, these applications modify your submission and add a lot of instructions to your prompt. As a developer, you’ll have to do the same. Here are a few tips to improve your prompt and obtain better results:
- Provide context: Instead of simply asking for three must-see attractions, provide as much context as you can. Think about everything that you would ask someone who asked you the same question – for example, “How many days are you staying?,” “What kind of things do you like and dislike?,” or “How are you going to be getting around?”
- Be explicit about the format of the response: If you want the answer to come out in a specific format, make sure you tell the LLM this. You may even provide...