Aranwer commited on
Commit
f728565
·
verified ·
1 Parent(s): 07e9b52

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -78,7 +78,7 @@ def generate_question(answers):
78
  prompt = "You are playing a game called Kasoti (20 Questions)...\n"
79
  for i, (q, a) in enumerate(answers, 1):
80
  prompt += f"{i}. Q: {q}\n A: {a}\n"
81
- prompt += "\nAsk ONLY the next best yes/no question."
82
  response = query_llm("GROQ", [{"role": "user", "content": prompt}])
83
  return response.strip() if response else "Is it something you can hold?"
84
 
@@ -108,7 +108,7 @@ def start_game():
108
  "current_question": "Is it a living thing?",
109
  "consult_mode": False
110
  })
111
- intro = "🎯 **Kasoti Started!**\nThink of something... I'll guess in 20 questions.\n\n➡️ First Question: **Is it a living thing?**"
112
  return intro, gr.update(interactive=True), gr.update(interactive=True), "🔕 Consult Mode: OFF", gr.update(visible=False)
113
 
114
  def process_answer(answer_text):
 
78
  prompt = "You are playing a game called Kasoti (20 Questions)...\n"
79
  for i, (q, a) in enumerate(answers, 1):
80
  prompt += f"{i}. Q: {q}\n A: {a}\n"
81
+ prompt += "\nAsk ONLY the next best yes/no question. When you are sure about the answer. End the question with is this correct?"
82
  response = query_llm("GROQ", [{"role": "user", "content": prompt}])
83
  return response.strip() if response else "Is it something you can hold?"
84
 
 
108
  "current_question": "Is it a living thing?",
109
  "consult_mode": False
110
  })
111
+ intro = "🎯 **Kasoti Started!**\nThink of something... I'll guess in 20 questions.\n\n➡️ First Question: Is it a living thing?"
112
  return intro, gr.update(interactive=True), gr.update(interactive=True), "🔕 Consult Mode: OFF", gr.update(visible=False)
113
 
114
  def process_answer(answer_text):