Update prompts/main_prompt.py
Browse files- prompts/main_prompt.py +21 -20
prompts/main_prompt.py
CHANGED
|
@@ -1,31 +1,31 @@
|
|
| 1 |
MAIN_PROMPT = """
|
| 2 |
### **Module 4: Proportional Thinking with Percentages**
|
| 3 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 4 |
|
| 5 |
๐ **Hereโs the problem:**
|
| 6 |
-
Orrin and Damen
|
| 7 |
-
Orrin contributed **$1,500**, which is **60%** of the total investment.
|
| 8 |
-
๐ก **How much do they invest together?**
|
| 9 |
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
|
| 15 |
-
**
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
(Type **"Bar Model"**, **"Double Number Line"**, or **"Equation"** to continue.)
|
| 19 |
"""
|
| 20 |
|
| 21 |
-
#
|
| 22 |
def get_prompt_for_method(method):
|
| 23 |
if method.lower() == "bar model":
|
| 24 |
return """
|
| 25 |
### **Bar Model Approach**
|
| 26 |
-
Great choice! The Bar Model is a
|
| 27 |
|
| 28 |
-
๐ **
|
| 29 |
- How would you represent the total investment in the bar model?
|
| 30 |
- How would you use it to find the unknown amount?
|
| 31 |
|
|
@@ -37,7 +37,7 @@ Great choice! The Bar Model is a helpful way to **visualize** proportions and pe
|
|
| 37 |
### **Double Number Line Approach**
|
| 38 |
Great choice! The Double Number Line helps align percentage values with real-world quantities.
|
| 39 |
|
| 40 |
-
๐ **
|
| 41 |
- What values would you place on each line?
|
| 42 |
- How would you determine the total investment using this method?
|
| 43 |
|
|
@@ -49,7 +49,7 @@ Great choice! The Double Number Line helps align percentage values with real-wor
|
|
| 49 |
### **Equation-Based Approach**
|
| 50 |
Great choice! Setting up an equation is a powerful way to solve proportional problems.
|
| 51 |
|
| 52 |
-
๐ **
|
| 53 |
- What proportion or equation would represent the situation?
|
| 54 |
- How would you solve for the total investment?
|
| 55 |
|
|
@@ -58,10 +58,11 @@ Great choice! Setting up an equation is a powerful way to solve proportional pro
|
|
| 58 |
|
| 59 |
return "I didnโt understand your choice. Please type 'Bar Model,' 'Double Number Line,' or 'Equation' to proceed."
|
| 60 |
|
| 61 |
-
|
|
|
|
| 62 |
def get_feedback_for_method(method, teacher_response):
|
| 63 |
if not teacher_response.strip():
|
| 64 |
-
return "๐ **
|
| 65 |
|
| 66 |
if method.lower() == "bar model":
|
| 67 |
if "divide" in teacher_response.lower() and "60%" in teacher_response.lower():
|
|
@@ -78,4 +79,4 @@ def get_feedback_for_method(method, teacher_response):
|
|
| 78 |
return "โ
You're on the right track! Now, how can you solve for x in your equation?"
|
| 79 |
return "๐น Try writing the proportion as (60/100) = (1500/x). What steps would you take to solve for x?"
|
| 80 |
|
| 81 |
-
return "Interesting approach! Could you clarify your reasoning a bit more?"
|
|
|
|
| 1 |
MAIN_PROMPT = """
|
| 2 |
### **Module 4: Proportional Thinking with Percentages**
|
| 3 |
+
"Welcome to this module on proportional reasoning with percentages!
|
| 4 |
+
Your goal is to solve a real-world problem using different representations:
|
| 5 |
+
1๏ธโฃ **Bar Model**
|
| 6 |
+
2๏ธโฃ **Double Number Line**
|
| 7 |
+
3๏ธโฃ **Equation-Based Approach**
|
| 8 |
|
| 9 |
๐ **Hereโs the problem:**
|
| 10 |
+
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?
|
|
|
|
|
|
|
| 11 |
|
| 12 |
+
๐ **Steps to follow:**
|
| 13 |
+
โ
**Step 1:** Choose a method.
|
| 14 |
+
โ
**Step 2:** **Explain your reasoning before receiving guidance.**
|
| 15 |
+
โ
**Step 3:** AI will provide **feedback on your explanation** before offering hints or solutions.
|
| 16 |
|
| 17 |
+
๐ **Which method would you like to use first?**
|
| 18 |
+
(Type 'Bar Model,' 'Double Number Line,' or 'Equation' to proceed.)
|
|
|
|
|
|
|
| 19 |
"""
|
| 20 |
|
| 21 |
+
# Function to handle method selection and ensure AI first asks for teacher input
|
| 22 |
def get_prompt_for_method(method):
|
| 23 |
if method.lower() == "bar model":
|
| 24 |
return """
|
| 25 |
### **Bar Model Approach**
|
| 26 |
+
Great choice! The Bar Model is a useful way to visualize proportions and percentages.
|
| 27 |
|
| 28 |
+
๐ **Now, please apply the Bar Model and explain your approach.**
|
| 29 |
- How would you represent the total investment in the bar model?
|
| 30 |
- How would you use it to find the unknown amount?
|
| 31 |
|
|
|
|
| 37 |
### **Double Number Line Approach**
|
| 38 |
Great choice! The Double Number Line helps align percentage values with real-world quantities.
|
| 39 |
|
| 40 |
+
๐ **Now, please apply the Double Number Line and explain your approach.**
|
| 41 |
- What values would you place on each line?
|
| 42 |
- How would you determine the total investment using this method?
|
| 43 |
|
|
|
|
| 49 |
### **Equation-Based Approach**
|
| 50 |
Great choice! Setting up an equation is a powerful way to solve proportional problems.
|
| 51 |
|
| 52 |
+
๐ **Now, please apply the Equation approach and explain your reasoning.**
|
| 53 |
- What proportion or equation would represent the situation?
|
| 54 |
- How would you solve for the total investment?
|
| 55 |
|
|
|
|
| 58 |
|
| 59 |
return "I didnโt understand your choice. Please type 'Bar Model,' 'Double Number Line,' or 'Equation' to proceed."
|
| 60 |
|
| 61 |
+
|
| 62 |
+
# Function to ensure AI first asks for an explanation before offering guidance
|
| 63 |
def get_feedback_for_method(method, teacher_response):
|
| 64 |
if not teacher_response.strip():
|
| 65 |
+
return "๐ **Before receiving guidance, please explain your thought process.** How are you approaching this problem using the selected method?"
|
| 66 |
|
| 67 |
if method.lower() == "bar model":
|
| 68 |
if "divide" in teacher_response.lower() and "60%" in teacher_response.lower():
|
|
|
|
| 79 |
return "โ
You're on the right track! Now, how can you solve for x in your equation?"
|
| 80 |
return "๐น Try writing the proportion as (60/100) = (1500/x). What steps would you take to solve for x?"
|
| 81 |
|
| 82 |
+
return "Interesting approach! Could you clarify your reasoning a bit more?"
|