Aarnaburji commited on
Commit
472359a
·
verified ·
1 Parent(s): 2d6d7e0

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -5
app.py CHANGED
@@ -64,10 +64,10 @@ def find_relevant_segment(user_query, segments):
64
 
65
  def generate_response(user_query, relevant_segment):
66
  """
67
- Generate a response emphasizing the bot's capability in providing chess information.
68
  """
69
  try:
70
- user_message = f"Here's the information on chess: {relevant_segment}"
71
 
72
  # Append user's message to messages list
73
  messages.append({"role": "user", "content": user_message})
@@ -99,7 +99,7 @@ def query_model(question):
99
  Process a question, find relevant information, and generate a response.
100
  """
101
  if question == "":
102
- return "Welcome to ChessBot! Ask me anything about chess rules, strategies, and terminology."
103
  relevant_segment = find_relevant_segment(question, segments)
104
  if not relevant_segment:
105
  return "Could not find specific information. Please refine your question."
@@ -108,9 +108,9 @@ def query_model(question):
108
 
109
  # Define the welcome message and specific topics the chatbot can provide information about
110
  welcome_message = """
111
- # ♟️ Welcome to ChessBot!
112
 
113
- ## Your AI-driven assistant for all chess-related queries. Created by SCHOLAR1, SCHOLAR2, and SCHOLAR3 of the 2024 Kode With Klossy CITY Camp.
114
  """
115
 
116
  topics = """
 
64
 
65
  def generate_response(user_query, relevant_segment):
66
  """
67
+ Generate a response emphasizing the bot's capability in providing astronomical information.
68
  """
69
  try:
70
+ user_message = f"Here's the information on outer space: {relevant_segment}"
71
 
72
  # Append user's message to messages list
73
  messages.append({"role": "user", "content": user_message})
 
99
  Process a question, find relevant information, and generate a response.
100
  """
101
  if question == "":
102
+ return "Welcome to Starfinder! Ask me anything about outer space, stargazing, and upcoming astronomical events."
103
  relevant_segment = find_relevant_segment(question, segments)
104
  if not relevant_segment:
105
  return "Could not find specific information. Please refine your question."
 
108
 
109
  # Define the welcome message and specific topics the chatbot can provide information about
110
  welcome_message = """
111
+ # ♟️ Welcome to Starfinder!
112
 
113
+ ## Your AI-driven assistant for all astronomy-related queries. Created by Aarna, Aditi, and Anastasia of the 2024 Kode With Klossy SF Camp.
114
  """
115
 
116
  topics = """