Prompt Engineering: "I Don't Know" Is a Good Answer
Saying I do not know is a good answer when the facts are missing. A short honest answer beats a confident guess.
No permission to refuse
The question asks for a fact that is not in the data. Nothing tells the model it may refuse.
What is the discount code for first orders at ShopStack?Permission to refuse
The same question, with the discount facts in the prompt and an instruction to say so when the fact is missing.
ShopStack discount codes: one code per order. Codes cannot be combined.
If the answer is not in these facts, say you do not know.
What is the discount code for first orders at ShopStack?Example
ShopStack shipping: free over $35, otherwise $4.95. Delivery in 2 to 4 business days.
If the answer is not in these facts, say you do not know.
Do you ship to Canada?Key points
- Saying I do not know is a good answer when the facts are missing.
- A model that guesses fills the gap with invention. A wrong answer costs more than no answer.
- The prompt can allow the honest answer. Say you do not know if the facts are missing is an instruction.
- The check is the data. If the fact is not in the ShopStack data, the answer must say so.
- A good refusal points forward. It says what is missing and what to do next.
This example grounds the shipping question and allows a refusal. The facts say nothing about Canada. The honest answer says so and does not invent international shipping.
Note
I do not know is not a failure. It is the desk refusing to invent a fact.
Try it Yourself
Edit the code, then press Run.
Running is simulated · Rust Playground
Exercise
Why is I do not know a good answer when the facts are missing?