From ee5e4fbb8c211beb8e643116ee62b2592c6b3150 Mon Sep 17 00:00:00 2001 From: "Dobbertin, Niclas" Date: Tue, 16 Apr 2024 11:40:09 +0200 Subject: start prod mul --- modeling/prod_addition.py | 44 +++++++++++++++++++++++++++++++++----------- 1 file changed, 33 insertions(+), 11 deletions(-) (limited to 'modeling/prod_addition.py') diff --git a/modeling/prod_addition.py b/modeling/prod_addition.py index 7ba7c22..3c7e888 100644 --- a/modeling/prod_addition.py +++ b/modeling/prod_addition.py @@ -116,6 +116,7 @@ def addition(Model): isa math_op carry_ones None tens_ans busy + ~retrieval> +retrieval> isa math_op arg1 =num1 @@ -310,16 +311,37 @@ def addition(Model): ) prods.append(add_hundreds_carry) - # addition_done = Model.productionstring( - # name="addition_done", - # string=""" - # =g> - # isa math_goal - # task done - # ==> - # ?g> - # """ - # ) - # prods.append(addition_done) + addition_done = Model.productionstring( + name="addition_done", + string=""" + =g> + isa math_goal + task done + =imaginal> + isa math_op + op add + arg1 =arg1 + ones1 =ones1 + tens1 =tens1 + hundreds1 =huns1 + arg2 =arg2 + ones2 =ones2 + tens2 =tens2 + hundreds2 =huns2 + ==> + +retrieval> + isa math_op + op add + arg1 =arg1 + ones1 =ones1 + tens1 =tens1 + hundreds1 =huns1 + arg2 =arg2 + ones2 =ones2 + tens2 =tens2 + hundreds2 =huns2 + """ + ) + prods.append(addition_done) return prods -- cgit v1.2.3