summaryrefslogtreecommitdiff
path: root/modeling/productions_math.py
diff options
context:
space:
mode:
Diffstat (limited to 'modeling/productions_math.py')
-rw-r--r--modeling/productions_math.py27
1 files changed, 20 insertions, 7 deletions
diff --git a/modeling/productions_math.py b/modeling/productions_math.py
index a064710..cbacfa0 100644
--- a/modeling/productions_math.py
+++ b/modeling/productions_math.py
@@ -80,31 +80,44 @@ def start():
environment_process=env.environment_process,
stimuli=envs,
# triggers="space",
- triggers="b"
+ triggers="b",
)
i = 1
userinput = ""
while True:
sim.step()
- if sim.current_event.time >= 40:
+ if sim.current_event.time >= 50:
print(sim.current_event)
break
if "KEY PRESSED" in sim.current_event.action:
userinput = userinput + sim.current_event.action.split(":")[1]
- if sim.current_event.action == "NO RULE FOUND":
- print(goal)
+ # if sim.current_event.action == "NO RULE FOUND":
+ # print(goal)
if sim.current_event.action == "KEY PRESSED: SPACE":
i += 1
print(userinput)
print("NEW PROC")
- goal.add(
- actr.makechunk("", "math_goal", proc=f"proc{i}", ones_carry="hello")
- )
+ if i <= 6:
+ goal.add(
+ actr.makechunk(
+ "", "math_goal", proc=f"proc{i}", ones_carry="hello"
+ )
+ )
+ elif i == 7:
+ goal.add(
+ actr.makechunk(
+ "", "math_goal", proc="proc_overall", ones_carry="hello"
+ )
+ )
+ elif i > 7:
+ print("DONE")
+ break
# sim.run(max_time=25)
print(userinput)
print("Simulation time: ", sim.show_time())
print("goal: ", goal)
+ print(sim.current_event)
# print(list(env))
# print("imaginal: ", imaginal)
# imaginal.show("hundreds_ans")