Update prompts/main_prompt.py
Browse files- prompts/main_prompt.py +23 -14
prompts/main_prompt.py
CHANGED
@@ -14,49 +14,58 @@ Orrin and Damen decided to invest money in a local ice cream shop. Orrin invests
|
|
14 |
(Type 'Bar Model,' 'Double Number Line,' or 'Equation' to proceed.)"
|
15 |
"""
|
16 |
|
17 |
-
# Function to prompt
|
18 |
def get_prompt_for_method(method):
|
19 |
if method.lower() == "bar model":
|
20 |
return """
|
21 |
### **Bar Model Approach**
|
22 |
Great choice! The Bar Model is a useful way to visualize proportions and percentages.
|
23 |
-
💡 **Now, apply the Bar Model and explain your process.**
|
24 |
-
|
|
|
|
|
25 |
"""
|
26 |
|
27 |
elif method.lower() == "double number line":
|
28 |
return """
|
29 |
### **Double Number Line Approach**
|
30 |
Great choice! The Double Number Line helps align percentage values with real-world quantities.
|
31 |
-
💡 **Now, apply the Double Number Line and explain your process.**
|
32 |
-
|
|
|
|
|
33 |
"""
|
34 |
|
35 |
elif method.lower() == "equation":
|
36 |
return """
|
37 |
### **Equation-Based Approach**
|
38 |
Great choice! Setting up an equation is a powerful way to represent proportional relationships.
|
39 |
-
💡 **Now, apply the equation method and explain your process.**
|
40 |
-
|
|
|
|
|
41 |
"""
|
42 |
|
43 |
return "I didn’t understand your choice. Please type 'Bar Model,' 'Double Number Line,' or 'Equation' to proceed."
|
44 |
|
45 |
-
# Function to
|
46 |
def get_feedback_for_method(method, teacher_response):
|
|
|
|
|
|
|
47 |
if method.lower() == "bar model":
|
48 |
if "divide" in teacher_response.lower() and "60%" in teacher_response.lower():
|
49 |
-
return "Great start! You recognized that the bar should be divided into parts representing percentages. Now, can you calculate how much each part represents?"
|
50 |
-
return "It looks like you might need some help.
|
51 |
|
52 |
elif method.lower() == "double number line":
|
53 |
if "label" in teacher_response.lower() and "percentages" in teacher_response.lower():
|
54 |
-
return "Nice work! You’ve set up the number line correctly. Can you now align the percentage values with the corresponding dollar amounts?"
|
55 |
-
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?"
|
56 |
|
57 |
elif method.lower() == "equation":
|
58 |
if "60/100" in teacher_response.lower() and "$1500/x" in teacher_response.lower():
|
59 |
-
return "You're on the right track! Now, how can you solve for x in your equation?"
|
60 |
-
return "Try writing the proportion as (60/100) = (1500/x). What steps would you take to solve for x?"
|
61 |
|
62 |
return "Interesting approach! Could you clarify your reasoning a bit more?"
|
|
|
14 |
(Type 'Bar Model,' 'Double Number Line,' or 'Equation' to proceed.)"
|
15 |
"""
|
16 |
|
17 |
+
# Function to prompt the teacher based on their method choice **without giving away the solution**
|
18 |
def get_prompt_for_method(method):
|
19 |
if method.lower() == "bar model":
|
20 |
return """
|
21 |
### **Bar Model Approach**
|
22 |
Great choice! The Bar Model is a useful way to visualize proportions and percentages.
|
23 |
+
💡 **Now, apply the Bar Model and explain your process.**
|
24 |
+
✏️ **How would you draw the model and set up the problem?**
|
25 |
+
✏️ **What steps would you take to find the total investment?**
|
26 |
+
🛑 **The AI will wait for your explanation before providing any feedback.**
|
27 |
"""
|
28 |
|
29 |
elif method.lower() == "double number line":
|
30 |
return """
|
31 |
### **Double Number Line Approach**
|
32 |
Great choice! The Double Number Line helps align percentage values with real-world quantities.
|
33 |
+
💡 **Now, apply the Double Number Line and explain your process.**
|
34 |
+
✏️ **How would you draw and label the number line?**
|
35 |
+
✏️ **What values would you place at each interval?**
|
36 |
+
🛑 **The AI will wait for your explanation before providing any feedback.**
|
37 |
"""
|
38 |
|
39 |
elif method.lower() == "equation":
|
40 |
return """
|
41 |
### **Equation-Based Approach**
|
42 |
Great choice! Setting up an equation is a powerful way to represent proportional relationships.
|
43 |
+
💡 **Now, apply the equation method and explain your process.**
|
44 |
+
✏️ **How would you set up an equation to represent the given percentages?**
|
45 |
+
✏️ **What steps would you take to solve for the total investment?**
|
46 |
+
🛑 **The AI will wait for your explanation before providing any feedback.**
|
47 |
"""
|
48 |
|
49 |
return "I didn’t understand your choice. Please type 'Bar Model,' 'Double Number Line,' or 'Equation' to proceed."
|
50 |
|
51 |
+
# Function to **wait for teacher response** before giving feedback
|
52 |
def get_feedback_for_method(method, teacher_response):
|
53 |
+
if not teacher_response.strip():
|
54 |
+
return "🛑 **Please explain your thought process first before receiving guidance!**"
|
55 |
+
|
56 |
if method.lower() == "bar model":
|
57 |
if "divide" in teacher_response.lower() and "60%" in teacher_response.lower():
|
58 |
+
return "✅ Great start! You recognized that the bar should be divided into parts representing percentages. Now, can you calculate how much each part represents?"
|
59 |
+
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?"
|
60 |
|
61 |
elif method.lower() == "double number line":
|
62 |
if "label" in teacher_response.lower() and "percentages" in teacher_response.lower():
|
63 |
+
return "✅ Nice work! You’ve set up the number line correctly. Can you now align the percentage values with the corresponding dollar amounts?"
|
64 |
+
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?"
|
65 |
|
66 |
elif method.lower() == "equation":
|
67 |
if "60/100" in teacher_response.lower() and "$1500/x" in teacher_response.lower():
|
68 |
+
return "✅ You're on the right track! Now, how can you solve for x in your equation?"
|
69 |
+
return "🔹 Try writing the proportion as (60/100) = (1500/x). What steps would you take to solve for x?"
|
70 |
|
71 |
return "Interesting approach! Could you clarify your reasoning a bit more?"
|