summaryrefslogtreecommitdiff
path: root/modeling/prod_procedure.py
diff options
context:
space:
mode:
authorDobbertin, Niclas <niclas.dobbertin@mailbox.org>2024-05-10 18:22:08 +0200
committerDobbertin, Niclas <niclas.dobbertin@mailbox.org>2024-05-10 18:22:08 +0200
commit27124f640cd8a8df934cc736216c7bda6a2e9f8c (patch)
treef94ef8b93d8ef5c5dec40e8cd832e568a2ebd47a /modeling/prod_procedure.py
parent3fcf103c9da2444ee3f93f92ac4c811a987b5e90 (diff)
procedures progress
Diffstat (limited to 'modeling/prod_procedure.py')
-rw-r--r--modeling/prod_procedure.py111
1 files changed, 111 insertions, 0 deletions
diff --git a/modeling/prod_procedure.py b/modeling/prod_procedure.py
new file mode 100644
index 0000000..9b1cbaf
--- /dev/null
+++ b/modeling/prod_procedure.py
@@ -0,0 +1,111 @@
+#!/usr/bin/env python3
+
+
+def procedures(Model):
+ prods = []
+
+ proc_start = Model.productionstring(
+ name="proc_start",
+ string="""
+ =g>
+ isa math_goal
+ proc =proc
+ op None
+ nextop None
+ ?retrieval>
+ state free
+ ==>
+ +retrieval>
+ isa procedure
+ proc =proc
+
+ """,
+ )
+ prods.append(proc_start)
+
+ proc_start_task1 = Model.productionstring(
+ name="proc_start_task1",
+ string="""
+ =g>
+ isa math_goal
+ proc =proc
+ op None
+ nextop None
+ =retrieval>
+ isa procedure
+ proc =proc
+ result1 None
+ op1 =op
+ arg1_1 =arg1
+ arg1_2 =arg2
+ ==>
+ +g>
+ isa math_goal
+ proc =proc
+ task 1
+ op =op
+ arg1 =arg1
+ arg2 =arg2
+ """,
+ )
+ prods.append(proc_start_task1)
+
+ proc_harvest_task1 = Model.productionstring(
+ name="proc_harvest_task1",
+ string="""
+ =g>
+ isa math_goal
+ proc =proc
+ task 1
+ op done
+ nextop None
+ =imaginal>
+ isa math_op
+ ?retrieval>
+ state free
+ ==>
+ +retrieval>
+ isa procedure
+ proc =proc
+ """,
+ )
+
+ proc_harvest_task1_done = Model.productionstring(
+ name="proc_harvest_task1_done",
+ string="""
+ =g>
+ isa math_goal
+ proc =proc
+ task 1
+ op done
+ nextop None
+ =imaginal>
+ isa math_op
+ result =result1
+ =retrieval>
+ isa procedure
+ proc =proc
+ op1 =op1
+ arg1_1 =arg1_1
+ arg1_2 =arg1_2
+ op2 =op2
+ arg2_1 =arg2_1
+ arg2_2 =arg2_2
+ result2 =result2
+ ==>
+ +g>
+ isa math_goal
+ proc =proc
+ +imaginal>
+ isa procedure
+ proc =proc
+ op1 =op1
+ arg1_1 =arg1_1
+ arg1_2 =arg1_2
+ result1 =result1
+ op2 =op2
+ arg2_1 =arg2_1
+ arg2_2 =arg2_2
+ result2 =result2
+ """,
+ )