alibicer's picture
Update prompts/main_prompt.py
a4d9997 verified
raw
history blame
4.32 kB
MAIN_PROMPT = """
### **Module 4: Proportional Thinking with Percentages**
"Welcome to this module on proportional reasoning with percentages!
Your goal is to solve a real-world problem using different representations:
1๏ธโƒฃ **Bar Model**
2๏ธโƒฃ **Double Number Line**
3๏ธโƒฃ **Equation-Based Approach**
๐Ÿš€ **Hereโ€™s the problem:**
Orrin and Damen decided to invest money in a local ice cream shop. Orrin invests $1,500, which is 60% of their total investment. How much do Orrin and Damen invest together?
๐Ÿ“Œ **Steps to follow:**
โœ… **Step 1:** Choose a method.
โœ… **Step 2:** **Explain your reasoning before receiving guidance.**
โœ… **Step 3:** AI will provide **feedback on your explanation** before offering hints or solutions.
๐Ÿš€ **Which method would you like to use first?**
(Type 'Bar Model,' 'Double Number Line,' or 'Equation' to proceed.)
"""
# Function to handle method selection and ensure AI first asks for teacher input
def get_prompt_for_method(method):
if method.lower() == "bar model":
return """
### **Bar Model Approach**
Great choice! The Bar Model is a useful way to visualize proportions and percentages.
๐Ÿ“Œ **Now, please apply the Bar Model and explain your approach.**
- How would you represent the total investment in the bar model?
- How would you use it to find the unknown amount?
โœ๏ธ **Go ahead and describe your approach first. I will provide feedback after hearing your reasoning.**
"""
elif method.lower() == "double number line":
return """
### **Double Number Line Approach**
Great choice! The Double Number Line helps align percentage values with real-world quantities.
๐Ÿ“Œ **Now, please apply the Double Number Line and explain your approach.**
- What values would you place on each line?
- How would you determine the total investment using this method?
โœ๏ธ **Explain how you would use this approach first. I will provide feedback after hearing your reasoning.**
"""
elif method.lower() == "equation":
return """
### **Equation-Based Approach**
Great choice! Setting up an equation is a powerful way to solve proportional problems.
๐Ÿ“Œ **Now, please apply the Equation approach and explain your reasoning.**
- What proportion or equation would represent the situation?
- How would you solve for the total investment?
โœ๏ธ **Explain how you would approach it first. I will provide feedback after hearing your reasoning.**
"""
return "I didnโ€™t understand your choice. Please type 'Bar Model,' 'Double Number Line,' or 'Equation' to proceed."
# Function to ensure AI first asks for an explanation before offering guidance
def get_feedback_for_method(method, teacher_response):
if not teacher_response.strip():
return "๐Ÿ›‘ **Before receiving guidance, please explain your thought process.** How are you approaching this problem using the selected method?"
if method.lower() == "bar model":
if "divide" in teacher_response.lower() and "60%" in teacher_response.lower():
return "โœ… Great start! You recognized that the bar should be divided into parts representing percentages. Now, can you calculate how much each part represents?"
return "๐Ÿ”น It looks like you might need some help. Try dividing the bar into 10 equal parts, with 6 parts representing Orrinโ€™s 60%. How much does one part represent?"
elif method.lower() == "double number line":
if "label" in teacher_response.lower() and "percentages" in teacher_response.lower():
return "โœ… Nice work! Youโ€™ve set up the number line correctly. Can you now align the percentage values with the corresponding dollar amounts?"
return "๐Ÿ”น No worries! Try labeling your number line with 0%, 60%, and 100% on one side and the corresponding dollar amounts on the other. How do the values align?"
elif method.lower() == "equation":
if "60/100" in teacher_response.lower() and "$1500/x" in teacher_response.lower():
return "โœ… You're on the right track! Now, how can you solve for x in your equation?"
return "๐Ÿ”น Try writing the proportion as (60/100) = (1500/x). What steps would you take to solve for x?"
return "Interesting approach! Could you clarify your reasoning a bit more?"