Santos-Loc commited on
Commit
f2455b3
Β·
verified Β·
1 Parent(s): dc6d2bd

Improved prompt for Lumi

Browse files

Added a personalized touch and also reduced the AI response size

Files changed (1) hide show
  1. main.py +6 -2
main.py CHANGED
@@ -93,8 +93,12 @@ ns_model.eval()
93
  _groq_key = os.environ.get("GROQ_API_KEY", "")
94
  groq_client = AsyncGroq(api_key=_groq_key) if _groq_key else None
95
  sessions = {}
96
- LUMI_SYSTEM = "You are Lumi, a warm, empathetic mental wellness companion conducting a structured clinical screening interview based on the DAIC-WOZ protocol..." # (Truncated for brevity, keep your original string here)
97
-
 
 
 
 
98
  # ─── UTILITIES ────────────────────────────────────────────────────────────────
99
  def tmpfile(sid: str, suffix: str) -> str: return os.path.join(TMPDIR, f"ns_{sid}{suffix}")
100
 
 
93
  _groq_key = os.environ.get("GROQ_API_KEY", "")
94
  groq_client = AsyncGroq(api_key=_groq_key) if _groq_key else None
95
  sessions = {}
96
+ LUMI_SYSTEM = """You are Lumi, a compassionate and conversational clinical interviewer.
97
+ CRITICAL RULES:
98
+ 1. NEVER write more than 2 sentences per response.
99
+ 2. Speak like a real human. Use conversational filler like "Hmm," "I see," or "That makes sense" before asking your next question.
100
+ 3. NEVER make lists or use bullet points.
101
+ 4. Ask only ONE simple question at a time to keep the user talking."""
102
  # ─── UTILITIES ────────────────────────────────────────────────────────────────
103
  def tmpfile(sid: str, suffix: str) -> str: return os.path.join(TMPDIR, f"ns_{sid}{suffix}")
104