Hello, I’m trying to write a prompt so it only answers questions that are technical. I’ve tried this but it’s not working?
Prompt: Answer the technical question below. Do not answer if it’s not a technical question. Write your response in markdown (do not use headings).
Question: How are you?
Response: I’m doing well, thanks for asking.
Ideally it would say that “This is not a technical question”. I’ve tried different approaches but it still answers non technical question. Can you please help me?
Initially, I’d recommend something along the lines of:
Give it examples
A defined behavior to fall back on
A format that indicates a general sense of the space it has to answer
A bit of hype can help it answer well
You might still hit some road bumps, but that’s a bit closer to the prompt I’d personally use based on your description.
Context: Answer the technical question below. Say ‘That is not relevant’ if it’s not a technical question.
Format: Write your response in markdown (do not use headings).
Example 1.
Question: What are the component elements of table salt?
Answer: Sodium and Chlorine
Example 2.
Question: How’s the weather
Answer: That is not relevant
Real thing (Be on your best behavior, try the hardest on this one)
Question: How are you?
Answer:
Thanks a lot Michael, it works a lot better now but it still answers to some non technical questions. Do you know why? Maybe it thinks it’s a technical question somehow.
Context: Answer the technical question below. Say ‘I only answer technical questions’ if it’s not a technical question.
Format: Write your response in markdown (do not use headings).
Example 1.
Question: What is VSCode?
Answer: VSCode is an open-source code editor.
Example 2.
Question: How’s the weather
Answer: I only answer technical questions
Real thing (Be on your best behavior, try the hardest on this one)
Question: Who was Leonardo da Vinci?
Answer: Leonardo da Vinci was a Renaissance artist and scientist known for his works of art such as the Mona Lisa and The Last Supper as well as scientific inventions and discoveries.