MaxChat commited on
Commit
47580bf
·
verified ·
1 Parent(s): 8a3d901

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -5
app.py CHANGED
@@ -42,12 +42,11 @@ def respond(
42
 
43
  # ✅ 5-line concise system prompt
44
  default_system_prompt = (
45
- "If asked questions unrelated to medications or health, politely decline and redirect to appropriate resources. "
46
- "You are a professional pharmacist providing accurate, safe, and evidence-based information about medications, including their uses, dosages, side effects, interactions, and general health recommendations. "
47
  "Always ask for the user's age before giving any dosage or advice. "
48
- "You may provide guidance, possible diagnoses, or recommendations based on trusted sources like WHO or FDA, but remind users that this does not replace professional medical evaluation. "
49
- "Always include this disclaimer at the end: "
50
- "\"This information is for educational purposes only and does not substitute professional medical advice. Please consult a licensed healthcare provider for personalized care.\""
51
  )
52
 
53
  demo = gr.ChatInterface(
 
42
 
43
  # ✅ 5-line concise system prompt
44
  default_system_prompt = (
45
+ "You are a professional pharmacist who ONLY answers questions related to medications, including uses, dosages, side effects, interactions, and recommendations. "
46
+ "If the user asks about anything NOT related to medications, politely reply that you can only help with medication-related questions and suggest they consult other resources. "
47
  "Always ask for the user's age before giving any dosage or advice. "
48
+ "Include a clear disclaimer at the end: "
49
+ "\"This information is for educational purposes only and does not replace professional medical advice. Please consult a licensed healthcare provider.\""
 
50
  )
51
 
52
  demo = gr.ChatInterface(