eyeprolog 1.6.0 → 1.6.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/examples/book/chapter-11/01-why.pl +7 -10
- package/examples/proof/access-control-policy.pl +80 -138
- package/examples/proof/age.pl +28 -58
- package/examples/proof/aliases-and-namespaces.pl +35 -48
- package/examples/proof/ancestor.pl +70 -100
- package/examples/proof/animal.pl +34 -43
- package/examples/proof/annotation.pl +92 -116
- package/examples/proof/attributed-variables.pl +30 -48
- package/examples/proof/backward.pl +13 -15
- package/examples/proof/bayes-diagnosis.pl +119 -170
- package/examples/proof/beam-deflection.pl +93 -192
- package/examples/proof/cache-performance.pl +159 -282
- package/examples/proof/canary-release.pl +92 -134
- package/examples/proof/cat-koko.pl +39 -66
- package/examples/proof/catalan-convolution.pl +68 -110
- package/examples/proof/cdcl-sat-solver.pl +83 -111
- package/examples/proof/chart-parser.pl +242 -428
- package/examples/proof/clinical-trial-screening.pl +205 -316
- package/examples/proof/clpb-boolean-circuit.pl +56 -80
- package/examples/proof/clpb-feature-model.pl +56 -80
- package/examples/proof/combinatorics-findall-sort.pl +29 -44
- package/examples/proof/composition-of-injective-functions-is-injective.pl +113 -218
- package/examples/proof/context-association.pl +75 -99
- package/examples/proof/d3-group.pl +29 -44
- package/examples/proof/data-negotiation.pl +39 -66
- package/examples/proof/dcg-command-parser.pl +28 -39
- package/examples/proof/declarative-fault-localization.pl +45 -76
- package/examples/proof/defeasible-reasoning.pl +49 -69
- package/examples/proof/deontic-logic.pl +52 -82
- package/examples/proof/derived-backward-rule.pl +41 -53
- package/examples/proof/derived-rule.pl +21 -30
- package/examples/proof/diamond-property.pl +208 -255
- package/examples/proof/dif-constraints.pl +18 -36
- package/examples/proof/dog.pl +15 -24
- package/examples/proof/electrical-rc-filter.pl +48 -84
- package/examples/proof/enigma1225.pl +7 -10
- package/examples/proof/epidemic-policy.pl +358 -670
- package/examples/proof/equality-saturation.pl +53 -68
- package/examples/proof/equivalence-classes-overlap-implies-same-class.pl +612 -990
- package/examples/proof/existential-rule.pl +14 -20
- package/examples/proof/expression-eval.pl +59 -92
- package/examples/proof/floating-point.pl +67 -106
- package/examples/proof/four-color-map.pl +97 -167
- package/examples/proof/gdpr-compliance.pl +106 -154
- package/examples/proof/good-cobbler.pl +7 -10
- package/examples/proof/graph-reachability.pl +81 -125
- package/examples/proof/greatest-lower-bound-uniqueness.pl +86 -128
- package/examples/proof/group-inverse-uniqueness.pl +44 -68
- package/examples/proof/hanoi.pl +77 -172
- package/examples/proof/heat-loss.pl +106 -190
- package/examples/proof/herbrand-semantics.pl +14 -18
- package/examples/proof/herbrand-witnesses.pl +49 -68
- package/examples/proof/ideal-gas-law.pl +68 -128
- package/examples/proof/integrity-check.pl +22 -34
- package/examples/proof/intuitionistic-logic-kripke.pl +75 -97
- package/examples/proof/iso-control-and-errors.pl +72 -89
- package/examples/proof/iso-dynamic-database.pl +34 -43
- package/examples/proof/iso-extension-pipeline-audit.pl +13 -34
- package/examples/proof/iso-extensions.pl +42 -57
- package/examples/proof/iso-grouped-solutions.pl +77 -109
- package/examples/proof/iso-integer-arithmetic.pl +37 -58
- package/examples/proof/iso-operators.pl +29 -44
- package/examples/proof/job-shop-scheduling.pl +33 -42
- package/examples/proof/json.pl +20 -25
- package/examples/proof/knapsack-optimization.pl +46 -58
- package/examples/proof/knights-tour-warnsdorff.pl +240 -474
- package/examples/proof/language.pl +70 -100
- package/examples/proof/linear-logic-resources.pl +103 -182
- package/examples/proof/list-collection.pl +54 -90
- package/examples/proof/modal-logic-kripke.pl +74 -94
- package/examples/proof/nixon-diamond.pl +107 -140
- package/examples/proof/partial-evaluator.pl +265 -370
- package/examples/proof/peasant.pl +80 -140
- package/examples/proof/prime-range.pl +27 -36
- package/examples/proof/proof-contrapositive.pl +42 -57
- package/examples/proof/propositional-dynamic-logic.pl +58 -107
- package/examples/proof/rdf12-annotation.pl +64 -112
- package/examples/proof/rdf12-directional-language.pl +14 -20
- package/examples/proof/rdf12-nested-triple-term.pl +7 -10
- package/examples/proof/rdf12-trig-graph-join.pl +8 -14
- package/examples/proof/rdf12-trig-named-graph.pl +22 -34
- package/examples/proof/rdf12-trig-triple-term.pl +7 -10
- package/examples/proof/rdf12-triple-term.pl +7 -10
- package/examples/proof/reified-conditionals.pl +10 -22
- package/examples/proof/reusable-builtins.pl +46 -94
- package/examples/proof/route-planning.pl +94 -124
- package/examples/proof/security-incident-correlation.pl +153 -234
- package/examples/proof/sieve.pl +8 -14
- package/examples/proof/snaf.pl +8 -14
- package/examples/proof/socrates.pl +20 -25
- package/examples/proof/spacecraft-battery-diagnosis.pl +138 -264
- package/examples/proof/stable-marriage.pl +61 -81
- package/examples/proof/symbolic-derivative.pl +107 -169
- package/examples/proof/term-tools.pl +42 -59
- package/examples/proof/totient-summatory.pl +55 -76
- package/examples/proof/trust-flow-provenance-threshold.pl +124 -268
- package/examples/proof/universal-vs-existential-termination.pl +23 -36
- package/examples/proof/uuid.pl +16 -46
- package/examples/proof/vanilla-meta-interpreter.pl +8 -14
- package/examples/proof/web-names.pl +29 -44
- package/examples/proof/weighted-interval-scheduling.pl +3864 -8379
- package/examples/proof/witch.pl +122 -163
- package/examples/proof/workplace-compliance.pl +35 -68
- package/package.json +1 -1
- package/src/explain.js +49 -43
- package/src/parser.js +12 -3
- package/src/write.js +8 -4
- package/test/conformance/expected-proofs/proofs/bindings_nested_term.pl +7 -10
- package/test/conformance/expected-proofs/proofs/builtin_numeric.pl +7 -10
- package/test/conformance/expected-proofs/proofs/conjunction_order.pl +8 -13
- package/test/conformance/expected-proofs/proofs/explicit_recursive.pl +28 -40
- package/test/conformance/expected-proofs/proofs/extra_aggregate_min.pl +7 -10
- package/test/conformance/expected-proofs/proofs/extra_compound_name_arguments.pl +7 -10
- package/test/conformance/expected-proofs/proofs/extra_context_parts.pl +30 -48
- package/test/conformance/expected-proofs/proofs/extra_eq_builtin.pl +7 -10
- package/test/conformance/expected-proofs/proofs/extra_explicit_path_bound.pl +33 -42
- package/test/conformance/expected-proofs/proofs/extra_findall_builtin.pl +7 -10
- package/test/conformance/expected-proofs/proofs/extra_forall_builtin.pl +7 -9
- package/test/conformance/expected-proofs/proofs/extra_iri_join.pl +7 -10
- package/test/conformance/expected-proofs/proofs/extra_negation_success.pl +7 -9
- package/test/conformance/expected-proofs/proofs/extra_nested_list_binding.pl +7 -10
- package/test/conformance/expected-proofs/proofs/extra_once_member.pl +13 -15
- package/test/conformance/expected-proofs/proofs/extra_recursive_path.pl +28 -40
- package/test/conformance/expected-proofs/proofs/herbrand_witness.pl +7 -10
- package/test/conformance/expected-proofs/proofs/iri_atom.pl +7 -10
- package/test/conformance/expected-proofs/proofs/list_builtin.pl +8 -14
- package/test/conformance/expected-proofs/proofs/once_child.pl +13 -15
- package/test/conformance/expected-proofs/proofs/rule_fact.pl +7 -10
- package/test/regression/cases-regression.mjs +28 -37
- package/test/regression/cases-white-box.mjs +54 -0
- package/test/regression/support.mjs +2 -2
- package/the-art-of-eyeprolog.md +26 -14
|
@@ -1,140 +1,110 @@
|
|
|
1
1
|
ancestor(pat, jan).
|
|
2
2
|
why(
|
|
3
3
|
ancestor(pat, jan),
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
by(fact("ancestor.pl", clause(1)))
|
|
12
|
-
)
|
|
13
|
-
])
|
|
4
|
+
step(
|
|
5
|
+
ancestor(pat, jan),
|
|
6
|
+
rule("ancestor.pl", clause(4)),
|
|
7
|
+
['X' = pat, 'Y' = jan],
|
|
8
|
+
[
|
|
9
|
+
step(parent(pat, jan), fact("ancestor.pl", clause(1)), [], [])
|
|
10
|
+
]
|
|
14
11
|
)
|
|
15
12
|
).
|
|
16
13
|
|
|
17
14
|
ancestor(jan, lies).
|
|
18
15
|
why(
|
|
19
16
|
ancestor(jan, lies),
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
by(fact("ancestor.pl", clause(2)))
|
|
28
|
-
)
|
|
29
|
-
])
|
|
17
|
+
step(
|
|
18
|
+
ancestor(jan, lies),
|
|
19
|
+
rule("ancestor.pl", clause(4)),
|
|
20
|
+
['X' = jan, 'Y' = lies],
|
|
21
|
+
[
|
|
22
|
+
step(parent(jan, lies), fact("ancestor.pl", clause(2)), [], [])
|
|
23
|
+
]
|
|
30
24
|
)
|
|
31
25
|
).
|
|
32
26
|
|
|
33
27
|
ancestor(lies, emma).
|
|
34
28
|
why(
|
|
35
29
|
ancestor(lies, emma),
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
by(fact("ancestor.pl", clause(3)))
|
|
44
|
-
)
|
|
45
|
-
])
|
|
30
|
+
step(
|
|
31
|
+
ancestor(lies, emma),
|
|
32
|
+
rule("ancestor.pl", clause(4)),
|
|
33
|
+
['X' = lies, 'Y' = emma],
|
|
34
|
+
[
|
|
35
|
+
step(parent(lies, emma), fact("ancestor.pl", clause(3)), [], [])
|
|
36
|
+
]
|
|
46
37
|
)
|
|
47
38
|
).
|
|
48
39
|
|
|
49
40
|
ancestor(pat, lies).
|
|
50
41
|
why(
|
|
51
42
|
ancestor(pat, lies),
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
uses([
|
|
66
|
-
proof(
|
|
67
|
-
goal(parent(jan, lies)),
|
|
68
|
-
by(fact("ancestor.pl", clause(2)))
|
|
69
|
-
)
|
|
70
|
-
])
|
|
43
|
+
step(
|
|
44
|
+
ancestor(pat, lies),
|
|
45
|
+
rule("ancestor.pl", clause(5)),
|
|
46
|
+
['X' = pat, 'Z' = lies, 'Y' = jan],
|
|
47
|
+
[
|
|
48
|
+
step(parent(pat, jan), fact("ancestor.pl", clause(1)), [], []),
|
|
49
|
+
step(
|
|
50
|
+
ancestor(jan, lies),
|
|
51
|
+
rule("ancestor.pl", clause(4)),
|
|
52
|
+
['X' = jan, 'Y' = lies],
|
|
53
|
+
[
|
|
54
|
+
step(parent(jan, lies), fact("ancestor.pl", clause(2)), [], [])
|
|
55
|
+
]
|
|
71
56
|
)
|
|
72
|
-
]
|
|
57
|
+
]
|
|
73
58
|
)
|
|
74
59
|
).
|
|
75
60
|
|
|
76
61
|
ancestor(pat, emma).
|
|
77
62
|
why(
|
|
78
63
|
ancestor(pat, emma),
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
goal(ancestor(lies, emma)),
|
|
99
|
-
by(rule("ancestor.pl", clause(4))),
|
|
100
|
-
bindings([binding("X", lies), binding("Y", emma)]),
|
|
101
|
-
uses([
|
|
102
|
-
proof(
|
|
103
|
-
goal(parent(lies, emma)),
|
|
104
|
-
by(fact("ancestor.pl", clause(3)))
|
|
105
|
-
)
|
|
106
|
-
])
|
|
64
|
+
step(
|
|
65
|
+
ancestor(pat, emma),
|
|
66
|
+
rule("ancestor.pl", clause(5)),
|
|
67
|
+
['X' = pat, 'Z' = emma, 'Y' = jan],
|
|
68
|
+
[
|
|
69
|
+
step(parent(pat, jan), fact("ancestor.pl", clause(1)), [], []),
|
|
70
|
+
step(
|
|
71
|
+
ancestor(jan, emma),
|
|
72
|
+
rule("ancestor.pl", clause(5)),
|
|
73
|
+
['X' = jan, 'Z' = emma, 'Y' = lies],
|
|
74
|
+
[
|
|
75
|
+
step(parent(jan, lies), fact("ancestor.pl", clause(2)), [], []),
|
|
76
|
+
step(
|
|
77
|
+
ancestor(lies, emma),
|
|
78
|
+
rule("ancestor.pl", clause(4)),
|
|
79
|
+
['X' = lies, 'Y' = emma],
|
|
80
|
+
[
|
|
81
|
+
step(parent(lies, emma), fact("ancestor.pl", clause(3)), [], [])
|
|
82
|
+
]
|
|
107
83
|
)
|
|
108
|
-
]
|
|
84
|
+
]
|
|
109
85
|
)
|
|
110
|
-
]
|
|
86
|
+
]
|
|
111
87
|
)
|
|
112
88
|
).
|
|
113
89
|
|
|
114
90
|
ancestor(jan, emma).
|
|
115
91
|
why(
|
|
116
92
|
ancestor(jan, emma),
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
uses([
|
|
131
|
-
proof(
|
|
132
|
-
goal(parent(lies, emma)),
|
|
133
|
-
by(fact("ancestor.pl", clause(3)))
|
|
134
|
-
)
|
|
135
|
-
])
|
|
93
|
+
step(
|
|
94
|
+
ancestor(jan, emma),
|
|
95
|
+
rule("ancestor.pl", clause(5)),
|
|
96
|
+
['X' = jan, 'Z' = emma, 'Y' = lies],
|
|
97
|
+
[
|
|
98
|
+
step(parent(jan, lies), fact("ancestor.pl", clause(2)), [], []),
|
|
99
|
+
step(
|
|
100
|
+
ancestor(lies, emma),
|
|
101
|
+
rule("ancestor.pl", clause(4)),
|
|
102
|
+
['X' = lies, 'Y' = emma],
|
|
103
|
+
[
|
|
104
|
+
step(parent(lies, emma), fact("ancestor.pl", clause(3)), [], [])
|
|
105
|
+
]
|
|
136
106
|
)
|
|
137
|
-
]
|
|
107
|
+
]
|
|
138
108
|
)
|
|
139
109
|
).
|
|
140
110
|
|
package/examples/proof/animal.pl
CHANGED
|
@@ -1,68 +1,59 @@
|
|
|
1
1
|
type(joe, human).
|
|
2
2
|
why(
|
|
3
3
|
type(joe, human),
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
)
|
|
12
|
-
])
|
|
4
|
+
step(
|
|
5
|
+
type(joe, human),
|
|
6
|
+
rule("animal.pl", clause(4)),
|
|
7
|
+
[],
|
|
8
|
+
[
|
|
9
|
+
step(human(joe), fact("animal.pl", clause(1)), [], [])
|
|
10
|
+
]
|
|
13
11
|
)
|
|
14
12
|
).
|
|
15
13
|
|
|
16
14
|
type(joe, animal).
|
|
17
15
|
why(
|
|
18
16
|
type(joe, animal),
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
)
|
|
32
|
-
])
|
|
17
|
+
step(
|
|
18
|
+
type(joe, animal),
|
|
19
|
+
rule("animal.pl", clause(5)),
|
|
20
|
+
[],
|
|
21
|
+
[
|
|
22
|
+
step(
|
|
23
|
+
animal(joe),
|
|
24
|
+
rule("animal.pl", clause(3)),
|
|
25
|
+
['X' = joe],
|
|
26
|
+
[
|
|
27
|
+
step(human(joe), fact("animal.pl", clause(1)), [], [])
|
|
28
|
+
]
|
|
33
29
|
)
|
|
34
|
-
]
|
|
30
|
+
]
|
|
35
31
|
)
|
|
36
32
|
).
|
|
37
33
|
|
|
38
34
|
subclassOf(human, animal).
|
|
39
35
|
why(
|
|
40
36
|
subclassOf(human, animal),
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
)
|
|
49
|
-
])
|
|
37
|
+
step(
|
|
38
|
+
subclassOf(human, animal),
|
|
39
|
+
rule("animal.pl", clause(6)),
|
|
40
|
+
[],
|
|
41
|
+
[
|
|
42
|
+
step(animal(human), fact("animal.pl", clause(2)), [], [])
|
|
43
|
+
]
|
|
50
44
|
)
|
|
51
45
|
).
|
|
52
46
|
|
|
53
47
|
succeeds(animalExample, true).
|
|
54
48
|
why(
|
|
55
49
|
succeeds(animalExample, true),
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
by(fact("animal.pl", clause(2)))
|
|
64
|
-
)
|
|
65
|
-
])
|
|
50
|
+
step(
|
|
51
|
+
succeeds(animalExample, true),
|
|
52
|
+
rule("animal.pl", clause(7)),
|
|
53
|
+
['__anon0' = human],
|
|
54
|
+
[
|
|
55
|
+
step(animal(human), fact("animal.pl", clause(2)), [], [])
|
|
56
|
+
]
|
|
66
57
|
)
|
|
67
58
|
).
|
|
68
59
|
|
|
@@ -1,150 +1,126 @@
|
|
|
1
1
|
name(a, "Alice").
|
|
2
2
|
why(
|
|
3
3
|
name(a, "Alice"),
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
uses([
|
|
23
|
-
proof(
|
|
24
|
-
goal(\=(name(a, "Alice"), (_left, _right))),
|
|
25
|
-
by(builtin(\=, 2))
|
|
26
|
-
)
|
|
27
|
-
])
|
|
4
|
+
step(
|
|
5
|
+
name(a, "Alice"),
|
|
6
|
+
rule("annotation.pl", clause(5)),
|
|
7
|
+
['S' = a, 'O' = "Alice", '_t' = t, 'Context' = (name(a, "Alice"), statedBy(t, bob), recorded(t, "2021-07-07"))],
|
|
8
|
+
[
|
|
9
|
+
step(annotation(t, (name(a, "Alice"), statedBy(t, bob), recorded(t, "2021-07-07"))), fact("annotation.pl", clause(1)), [], []),
|
|
10
|
+
step(
|
|
11
|
+
context_member((name(a, "Alice"), statedBy(t, bob), recorded(t, "2021-07-07")), name(a, "Alice")),
|
|
12
|
+
rule("annotation.pl", clause(2)),
|
|
13
|
+
['Left' = name(a, "Alice"), '_right' = (statedBy(t, bob), recorded(t, "2021-07-07")), 'Member' = name(a, "Alice")],
|
|
14
|
+
[
|
|
15
|
+
step(
|
|
16
|
+
context_member(name(a, "Alice"), name(a, "Alice")),
|
|
17
|
+
rule("annotation.pl", clause(4)),
|
|
18
|
+
['Member' = name(a, "Alice")],
|
|
19
|
+
[
|
|
20
|
+
step(\=(name(a, "Alice"), (_left, _right)), builtin(\=, 2), [], [])
|
|
21
|
+
]
|
|
28
22
|
)
|
|
29
|
-
]
|
|
23
|
+
]
|
|
30
24
|
)
|
|
31
|
-
]
|
|
25
|
+
]
|
|
32
26
|
)
|
|
33
27
|
).
|
|
34
28
|
|
|
35
29
|
log_nameOf(t, name(a, "Alice")).
|
|
36
30
|
why(
|
|
37
31
|
log_nameOf(t, name(a, "Alice")),
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
uses([
|
|
57
|
-
proof(
|
|
58
|
-
goal(\=(name(a, "Alice"), (_left, _right))),
|
|
59
|
-
by(builtin(\=, 2))
|
|
60
|
-
)
|
|
61
|
-
])
|
|
32
|
+
step(
|
|
33
|
+
log_nameOf(t, name(a, "Alice")),
|
|
34
|
+
rule("annotation.pl", clause(6)),
|
|
35
|
+
['T' = t, 'S' = a, 'O' = "Alice", 'Context' = (name(a, "Alice"), statedBy(t, bob), recorded(t, "2021-07-07"))],
|
|
36
|
+
[
|
|
37
|
+
step(annotation(t, (name(a, "Alice"), statedBy(t, bob), recorded(t, "2021-07-07"))), fact("annotation.pl", clause(1)), [], []),
|
|
38
|
+
step(
|
|
39
|
+
context_member((name(a, "Alice"), statedBy(t, bob), recorded(t, "2021-07-07")), name(a, "Alice")),
|
|
40
|
+
rule("annotation.pl", clause(2)),
|
|
41
|
+
['Left' = name(a, "Alice"), '_right' = (statedBy(t, bob), recorded(t, "2021-07-07")), 'Member' = name(a, "Alice")],
|
|
42
|
+
[
|
|
43
|
+
step(
|
|
44
|
+
context_member(name(a, "Alice"), name(a, "Alice")),
|
|
45
|
+
rule("annotation.pl", clause(4)),
|
|
46
|
+
['Member' = name(a, "Alice")],
|
|
47
|
+
[
|
|
48
|
+
step(\=(name(a, "Alice"), (_left, _right)), builtin(\=, 2), [], [])
|
|
49
|
+
]
|
|
62
50
|
)
|
|
63
|
-
]
|
|
51
|
+
]
|
|
64
52
|
)
|
|
65
|
-
]
|
|
53
|
+
]
|
|
66
54
|
)
|
|
67
55
|
).
|
|
68
56
|
|
|
69
57
|
statedBy(t, bob).
|
|
70
58
|
why(
|
|
71
59
|
statedBy(t, bob),
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
uses([
|
|
96
|
-
proof(
|
|
97
|
-
goal(\=(statedBy(t, bob), (_left, _right))),
|
|
98
|
-
by(builtin(\=, 2))
|
|
99
|
-
)
|
|
100
|
-
])
|
|
60
|
+
step(
|
|
61
|
+
statedBy(t, bob),
|
|
62
|
+
rule("annotation.pl", clause(7)),
|
|
63
|
+
['S' = t, 'O' = bob, '_t' = t, 'Context' = (name(a, "Alice"), statedBy(t, bob), recorded(t, "2021-07-07"))],
|
|
64
|
+
[
|
|
65
|
+
step(annotation(t, (name(a, "Alice"), statedBy(t, bob), recorded(t, "2021-07-07"))), fact("annotation.pl", clause(1)), [], []),
|
|
66
|
+
step(
|
|
67
|
+
context_member((name(a, "Alice"), statedBy(t, bob), recorded(t, "2021-07-07")), statedBy(t, bob)),
|
|
68
|
+
rule("annotation.pl", clause(3)),
|
|
69
|
+
['_left' = name(a, "Alice"), 'Right' = (statedBy(t, bob), recorded(t, "2021-07-07")), 'Member' = statedBy(t, bob)],
|
|
70
|
+
[
|
|
71
|
+
step(
|
|
72
|
+
context_member((statedBy(t, bob), recorded(t, "2021-07-07")), statedBy(t, bob)),
|
|
73
|
+
rule("annotation.pl", clause(2)),
|
|
74
|
+
['Left' = statedBy(t, bob), '_right' = recorded(t, "2021-07-07"), 'Member' = statedBy(t, bob)],
|
|
75
|
+
[
|
|
76
|
+
step(
|
|
77
|
+
context_member(statedBy(t, bob), statedBy(t, bob)),
|
|
78
|
+
rule("annotation.pl", clause(4)),
|
|
79
|
+
['Member' = statedBy(t, bob)],
|
|
80
|
+
[
|
|
81
|
+
step(\=(statedBy(t, bob), (_left, _right)), builtin(\=, 2), [], [])
|
|
82
|
+
]
|
|
101
83
|
)
|
|
102
|
-
]
|
|
84
|
+
]
|
|
103
85
|
)
|
|
104
|
-
]
|
|
86
|
+
]
|
|
105
87
|
)
|
|
106
|
-
]
|
|
88
|
+
]
|
|
107
89
|
)
|
|
108
90
|
).
|
|
109
91
|
|
|
110
92
|
recorded(t, "2021-07-07").
|
|
111
93
|
why(
|
|
112
94
|
recorded(t, "2021-07-07"),
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
uses([
|
|
137
|
-
proof(
|
|
138
|
-
goal(\=(recorded(t, "2021-07-07"), (_left, _right))),
|
|
139
|
-
by(builtin(\=, 2))
|
|
140
|
-
)
|
|
141
|
-
])
|
|
95
|
+
step(
|
|
96
|
+
recorded(t, "2021-07-07"),
|
|
97
|
+
rule("annotation.pl", clause(8)),
|
|
98
|
+
['S' = t, 'O' = "2021-07-07", '_t' = t, 'Context' = (name(a, "Alice"), statedBy(t, bob), recorded(t, "2021-07-07"))],
|
|
99
|
+
[
|
|
100
|
+
step(annotation(t, (name(a, "Alice"), statedBy(t, bob), recorded(t, "2021-07-07"))), fact("annotation.pl", clause(1)), [], []),
|
|
101
|
+
step(
|
|
102
|
+
context_member((name(a, "Alice"), statedBy(t, bob), recorded(t, "2021-07-07")), recorded(t, "2021-07-07")),
|
|
103
|
+
rule("annotation.pl", clause(3)),
|
|
104
|
+
['_left' = name(a, "Alice"), 'Right' = (statedBy(t, bob), recorded(t, "2021-07-07")), 'Member' = recorded(t, "2021-07-07")],
|
|
105
|
+
[
|
|
106
|
+
step(
|
|
107
|
+
context_member((statedBy(t, bob), recorded(t, "2021-07-07")), recorded(t, "2021-07-07")),
|
|
108
|
+
rule("annotation.pl", clause(3)),
|
|
109
|
+
['_left' = statedBy(t, bob), 'Right' = recorded(t, "2021-07-07"), 'Member' = recorded(t, "2021-07-07")],
|
|
110
|
+
[
|
|
111
|
+
step(
|
|
112
|
+
context_member(recorded(t, "2021-07-07"), recorded(t, "2021-07-07")),
|
|
113
|
+
rule("annotation.pl", clause(4)),
|
|
114
|
+
['Member' = recorded(t, "2021-07-07")],
|
|
115
|
+
[
|
|
116
|
+
step(\=(recorded(t, "2021-07-07"), (_left, _right)), builtin(\=, 2), [], [])
|
|
117
|
+
]
|
|
142
118
|
)
|
|
143
|
-
]
|
|
119
|
+
]
|
|
144
120
|
)
|
|
145
|
-
]
|
|
121
|
+
]
|
|
146
122
|
)
|
|
147
|
-
]
|
|
123
|
+
]
|
|
148
124
|
)
|
|
149
125
|
).
|
|
150
126
|
|
|
@@ -1,62 +1,44 @@
|
|
|
1
1
|
accepts_required_value(ok).
|
|
2
2
|
why(
|
|
3
3
|
accepts_required_value(ok),
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
by(builtin(put_atts, 2))
|
|
17
|
-
)
|
|
18
|
-
])
|
|
4
|
+
step(
|
|
5
|
+
accepts_required_value(ok),
|
|
6
|
+
rule("attributed-variables.pl", clause(4)),
|
|
7
|
+
['X' = 7],
|
|
8
|
+
[
|
|
9
|
+
step(
|
|
10
|
+
attach_required(Variable, 7),
|
|
11
|
+
rule("attributed-variables.pl", clause(1)),
|
|
12
|
+
['Value' = 7],
|
|
13
|
+
[
|
|
14
|
+
step(put_atts(Variable, required(7)), builtin(put_atts, 2), [], [])
|
|
15
|
+
]
|
|
19
16
|
),
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
by(builtin(=, 2))
|
|
23
|
-
)
|
|
24
|
-
])
|
|
17
|
+
step(=(7, 7), builtin(=, 2), [], [])
|
|
18
|
+
]
|
|
25
19
|
)
|
|
26
20
|
).
|
|
27
21
|
|
|
28
22
|
alias_preserves_attribute(ok).
|
|
29
23
|
why(
|
|
30
24
|
alias_preserves_attribute(ok),
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
by(builtin(put_atts, 2))
|
|
44
|
-
)
|
|
45
|
-
])
|
|
25
|
+
step(
|
|
26
|
+
alias_preserves_attribute(ok),
|
|
27
|
+
rule("attributed-variables.pl", clause(5)),
|
|
28
|
+
['X' = ready, 'Y' = ready],
|
|
29
|
+
[
|
|
30
|
+
step(
|
|
31
|
+
attach_required(Variable, ready),
|
|
32
|
+
rule("attributed-variables.pl", clause(1)),
|
|
33
|
+
['Value' = ready],
|
|
34
|
+
[
|
|
35
|
+
step(put_atts(Variable, required(ready)), builtin(put_atts, 2), [], [])
|
|
36
|
+
]
|
|
46
37
|
),
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
proof(
|
|
52
|
-
goal(get_atts(Y, required(ready))),
|
|
53
|
-
by(builtin(get_atts, 2))
|
|
54
|
-
),
|
|
55
|
-
proof(
|
|
56
|
-
goal(=(ready, ready)),
|
|
57
|
-
by(builtin(=, 2))
|
|
58
|
-
)
|
|
59
|
-
])
|
|
38
|
+
step(=(Y, Y), builtin(=, 2), [], []),
|
|
39
|
+
step(get_atts(Y, required(ready)), builtin(get_atts, 2), [], []),
|
|
40
|
+
step(=(ready, ready), builtin(=, 2), [], [])
|
|
41
|
+
]
|
|
60
42
|
)
|
|
61
43
|
).
|
|
62
44
|
|