How do I write deterministic prompts for reliable rule matching?
For rules to work consistently, it's important to write prompts that produce predictable, consistent responses. Here are best practices:
Specify exact response formats: Ask the AI to respond with only specific words or phrases
Analyze this email and respond with ONLY ONE of these exact words: "sales", "support", or "billing"
Use forced-choice questions: Frame your prompt as a choice between specific options
Is this email urgent? Or does it contains deadlines? Respond with ONLY "YES" or "NO".
Avoid open-ended questions: Instead of "What is this email about?", use "Does this email contain urgent information?"
Test your prompts: Use the "Log prompt result in conversations" option to see exactly what responses your prompts generate