eyeling 1.24.5 → 1.24.7

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.
Files changed (294) hide show
  1. package/HANDBOOK.md +0 -99
  2. package/README.md +2 -2
  3. package/dist/browser/eyeling.browser.js +6 -0
  4. package/{see/examples/n3 → examples}/annotation.n3 +1 -1
  5. package/{see/examples/n3/backward_recursion.n3 → examples/backward-recursion.n3} +0 -2
  6. package/examples/collection.n3 +3 -0
  7. package/examples/context-association.n3 +59 -0
  8. package/{see/examples/n3/dijkstra_risk_path.n3 → examples/dijkstra-risk-path.n3} +3 -18
  9. package/{see/examples/n3/eco_route_insight.n3 → examples/eco-route-insight.n3} +2 -47
  10. package/{see/examples/n3/genetic_knapsack_selection.n3 → examples/genetic-knapsack-selection.n3} +2 -24
  11. package/{see/examples → examples}/input/annotation.trig +3 -3
  12. package/{see/examples/input/backward_recursion.trig → examples/input/backward-recursion.trig} +2 -2
  13. package/{see/examples/input/builtin_coverage.trig → examples/input/builtin-coverage.trig} +2 -2
  14. package/{see/examples → examples}/input/collection.trig +3 -3
  15. package/examples/input/context-association.trig +35 -0
  16. package/{see/examples/input/dijkstra_risk_path.trig → examples/input/dijkstra-risk-path.trig} +4 -4
  17. package/{see/examples/input/eco_route_insight.trig → examples/input/eco-route-insight.trig} +4 -4
  18. package/{see/examples/input/genetic_knapsack_selection.trig → examples/input/genetic-knapsack-selection.trig} +4 -4
  19. package/{see/examples/input/rc_discharge_envelope.trig → examples/input/rc-discharge-envelope.trig} +4 -4
  20. package/{see/examples/input/rdf_dataset.trig → examples/input/rdf-dataset.trig} +4 -4
  21. package/{see/examples/input/rdf_message_flow.trig → examples/input/rdf-message-flow.trig} +3 -3
  22. package/{see/examples/input/rdf_messages.trig → examples/input/rdf-messages.trig} +4 -4
  23. package/{see/examples/input/school_placement_audit.trig → examples/input/school-placement-audit.trig} +4 -4
  24. package/{see/examples/input/smoke_arithmetic.trig → examples/input/smoke-arithmetic.trig} +3 -3
  25. package/{see/examples/input/triple_terms.trig → examples/input/triple-terms.trig} +3 -3
  26. package/examples/output/annotation.n3 +0 -0
  27. package/examples/output/backward-recursion.n3 +4 -0
  28. package/examples/output/builtin-coverage.n3 +0 -0
  29. package/examples/output/collection.n3 +0 -0
  30. package/examples/output/context-association.n3 +9 -0
  31. package/examples/output/dijkstra-risk-path.n3 +3 -0
  32. package/examples/output/eco-route-insight.n3 +3 -0
  33. package/examples/output/genetic-knapsack-selection.n3 +3 -0
  34. package/examples/output/rc-discharge-envelope.n3 +9 -0
  35. package/examples/output/rc-discharge-envelope.txt +9 -0
  36. package/examples/output/rdf-dataset.n3 +5 -0
  37. package/examples/output/rdf-message-flow.n3 +7 -0
  38. package/examples/output/rdf-messages.n3 +7 -0
  39. package/examples/output/school-placement-audit.n3 +3 -0
  40. package/examples/output/smoke-arithmetic.n3 +5 -0
  41. package/examples/output/smoke-arithmetic.txt +5 -0
  42. package/examples/output/triple-terms.n3 +5 -0
  43. package/{see/examples/n3/rc_discharge_envelope.n3 → examples/rc-discharge-envelope.n3} +2 -15
  44. package/{see/examples/n3/rdf_dataset.n3 → examples/rdf-dataset.n3} +2 -11
  45. package/{see/examples/n3/rdf_message_flow.n3 → examples/rdf-message-flow.n3} +9 -75
  46. package/{see/examples/n3/rdf_messages.n3 → examples/rdf-messages.n3} +6 -43
  47. package/{see/examples/n3/school_placement_audit.n3 → examples/school-placement-audit.n3} +2 -14
  48. package/{see/examples/n3/smoke_arithmetic.n3 → examples/smoke-arithmetic.n3} +3 -5
  49. package/{see/examples/n3/triple_terms.n3 → examples/triple-terms.n3} +1 -4
  50. package/eyeling.js +6 -0
  51. package/lib/builtins.js +6 -0
  52. package/package.json +4 -7
  53. package/test/api.test.js +25 -8
  54. package/test/examples.test.js +22 -2
  55. package/test/package.test.js +16 -2
  56. package/see/README.md +0 -149
  57. package/see/examples/_see.js +0 -249
  58. package/see/examples/age.js +0 -1459
  59. package/see/examples/annotation.js +0 -1320
  60. package/see/examples/backward.js +0 -1405
  61. package/see/examples/backward_recursion.js +0 -1504
  62. package/see/examples/bayes_diagnosis.js +0 -2883
  63. package/see/examples/bayes_therapy.js +0 -4152
  64. package/see/examples/bmi.js +0 -3038
  65. package/see/examples/builtin_coverage.js +0 -2524
  66. package/see/examples/collection.js +0 -1320
  67. package/see/examples/complex.js +0 -3762
  68. package/see/examples/complex_matrix_stability.js +0 -2973
  69. package/see/examples/composition_of_injective_functions_is_injective.js +0 -2170
  70. package/see/examples/control_system.js +0 -1918
  71. package/see/examples/crypto_builtins_tests.js +0 -1489
  72. package/see/examples/delfour.js +0 -3174
  73. package/see/examples/digital_product_passport.js +0 -2856
  74. package/see/examples/dijkstra.js +0 -2070
  75. package/see/examples/dijkstra_risk_path.js +0 -1874
  76. package/see/examples/doc/age.md +0 -27
  77. package/see/examples/doc/annotation.md +0 -24
  78. package/see/examples/doc/backward.md +0 -26
  79. package/see/examples/doc/backward_recursion.md +0 -26
  80. package/see/examples/doc/bayes_diagnosis.md +0 -41
  81. package/see/examples/doc/bayes_therapy.md +0 -40
  82. package/see/examples/doc/bmi.md +0 -38
  83. package/see/examples/doc/builtin_coverage.md +0 -53
  84. package/see/examples/doc/collection.md +0 -24
  85. package/see/examples/doc/complex.md +0 -38
  86. package/see/examples/doc/complex_matrix_stability.md +0 -35
  87. package/see/examples/doc/composition_of_injective_functions_is_injective.md +0 -24
  88. package/see/examples/doc/control_system.md +0 -32
  89. package/see/examples/doc/crypto_builtins_tests.md +0 -27
  90. package/see/examples/doc/delfour.md +0 -37
  91. package/see/examples/doc/digital_product_passport.md +0 -36
  92. package/see/examples/doc/dijkstra.md +0 -28
  93. package/see/examples/doc/dijkstra_risk_path.md +0 -30
  94. package/see/examples/doc/dog.md +0 -28
  95. package/see/examples/doc/eco_route_insight.md +0 -33
  96. package/see/examples/doc/equals.md +0 -26
  97. package/see/examples/doc/equivalence_classes_overlap_implies_same_class.md +0 -24
  98. package/see/examples/doc/euler_identity.md +0 -39
  99. package/see/examples/doc/ev_roundtrip_planner.md +0 -32
  100. package/see/examples/doc/existential_rule.md +0 -24
  101. package/see/examples/doc/expression_eval.md +0 -26
  102. package/see/examples/doc/family_cousins.md +0 -24
  103. package/see/examples/doc/fastpow.md +0 -29
  104. package/see/examples/doc/fibonacci.md +0 -28
  105. package/see/examples/doc/french_cities.md +0 -28
  106. package/see/examples/doc/fundamental_theorem_arithmetic.md +0 -36
  107. package/see/examples/doc/genetic_knapsack_selection.md +0 -29
  108. package/see/examples/doc/goldbach_1000.md +0 -31
  109. package/see/examples/doc/good_cobbler.md +0 -27
  110. package/see/examples/doc/gps.md +0 -35
  111. package/see/examples/doc/gray_code_counter.md +0 -31
  112. package/see/examples/doc/greatest_lower_bound_uniqueness.md +0 -24
  113. package/see/examples/doc/group_inverse_uniqueness.md +0 -24
  114. package/see/examples/doc/hadamard_approx.md +0 -32
  115. package/see/examples/doc/hanoi.md +0 -26
  116. package/see/examples/doc/odrl_dpv_risk_ranked.md +0 -57
  117. package/see/examples/doc/path_discovery.md +0 -33
  118. package/see/examples/doc/rc_discharge_envelope.md +0 -33
  119. package/see/examples/doc/rdf_dataset.md +0 -26
  120. package/see/examples/doc/rdf_message_flow.md +0 -35
  121. package/see/examples/doc/rdf_messages.md +0 -37
  122. package/see/examples/doc/school_placement_audit.md +0 -31
  123. package/see/examples/doc/smoke_arithmetic.md +0 -31
  124. package/see/examples/doc/socrates.md +0 -24
  125. package/see/examples/doc/triple_terms.md +0 -26
  126. package/see/examples/doc/wind_turbine.md +0 -37
  127. package/see/examples/doc/witch.md +0 -28
  128. package/see/examples/dog.js +0 -1436
  129. package/see/examples/eco_route_insight.js +0 -2110
  130. package/see/examples/equals.js +0 -1363
  131. package/see/examples/equivalence_classes_overlap_implies_same_class.js +0 -1792
  132. package/see/examples/euler_identity.js +0 -2038
  133. package/see/examples/ev_roundtrip_planner.js +0 -2562
  134. package/see/examples/existential_rule.js +0 -1363
  135. package/see/examples/expression_eval.js +0 -1798
  136. package/see/examples/family_cousins.js +0 -1586
  137. package/see/examples/fastpow.js +0 -2207
  138. package/see/examples/fibonacci.js +0 -1594
  139. package/see/examples/french_cities.js +0 -1492
  140. package/see/examples/fundamental_theorem_arithmetic.js +0 -2106
  141. package/see/examples/genetic_knapsack_selection.js +0 -1743
  142. package/see/examples/goldbach_1000.js +0 -1798
  143. package/see/examples/good_cobbler.js +0 -1396
  144. package/see/examples/gps.js +0 -2813
  145. package/see/examples/gray_code_counter.js +0 -1641
  146. package/see/examples/greatest_lower_bound_uniqueness.js +0 -1918
  147. package/see/examples/group_inverse_uniqueness.js +0 -1897
  148. package/see/examples/hadamard_approx.js +0 -4417
  149. package/see/examples/hanoi.js +0 -1625
  150. package/see/examples/input/age.trig +0 -27
  151. package/see/examples/input/backward.trig +0 -25
  152. package/see/examples/input/bayes_diagnosis.trig +0 -111
  153. package/see/examples/input/bayes_therapy.trig +0 -130
  154. package/see/examples/input/bmi.trig +0 -28
  155. package/see/examples/input/complex.trig +0 -26
  156. package/see/examples/input/complex_matrix_stability.trig +0 -65
  157. package/see/examples/input/composition_of_injective_functions_is_injective.trig +0 -35
  158. package/see/examples/input/control_system.trig +0 -31
  159. package/see/examples/input/crypto_builtins_tests.trig +0 -25
  160. package/see/examples/input/delfour.trig +0 -90
  161. package/see/examples/input/digital_product_passport.trig +0 -116
  162. package/see/examples/input/dijkstra.trig +0 -34
  163. package/see/examples/input/dog.trig +0 -31
  164. package/see/examples/input/equals.trig +0 -25
  165. package/see/examples/input/equivalence_classes_overlap_implies_same_class.trig +0 -28
  166. package/see/examples/input/euler_identity.trig +0 -34
  167. package/see/examples/input/ev_roundtrip_planner.trig +0 -90
  168. package/see/examples/input/existential_rule.trig +0 -26
  169. package/see/examples/input/expression_eval.trig +0 -41
  170. package/see/examples/input/family_cousins.trig +0 -39
  171. package/see/examples/input/fastpow.trig +0 -25
  172. package/see/examples/input/fibonacci.trig +0 -51
  173. package/see/examples/input/french_cities.trig +0 -38
  174. package/see/examples/input/fundamental_theorem_arithmetic.trig +0 -42
  175. package/see/examples/input/goldbach_1000.trig +0 -53
  176. package/see/examples/input/good_cobbler.trig +0 -24
  177. package/see/examples/input/gps.trig +0 -35
  178. package/see/examples/input/gray_code_counter.trig +0 -33
  179. package/see/examples/input/greatest_lower_bound_uniqueness.trig +0 -29
  180. package/see/examples/input/group_inverse_uniqueness.trig +0 -29
  181. package/see/examples/input/hadamard_approx.trig +0 -32
  182. package/see/examples/input/hanoi.trig +0 -26
  183. package/see/examples/input/odrl_dpv_risk_ranked.trig +0 -107
  184. package/see/examples/input/path-discovery.trig +0 -96448
  185. package/see/examples/input/path_discovery.trig +0 -29
  186. package/see/examples/input/socrates.trig +0 -26
  187. package/see/examples/input/wind_turbine.trig +0 -48
  188. package/see/examples/input/witch.trig +0 -26
  189. package/see/examples/n3/age.n3 +0 -28
  190. package/see/examples/n3/backward.n3 +0 -22
  191. package/see/examples/n3/bayes_diagnosis.n3 +0 -122
  192. package/see/examples/n3/bayes_therapy.n3 +0 -149
  193. package/see/examples/n3/bmi.n3 +0 -145
  194. package/see/examples/n3/collection.n3 +0 -3
  195. package/see/examples/n3/complex.n3 +0 -140
  196. package/see/examples/n3/complex_matrix_stability.n3 +0 -113
  197. package/see/examples/n3/composition_of_injective_functions_is_injective.n3 +0 -27
  198. package/see/examples/n3/control_system.n3 +0 -59
  199. package/see/examples/n3/crypto_builtins_tests.n3 +0 -18
  200. package/see/examples/n3/delfour.n3 +0 -167
  201. package/see/examples/n3/digital_product_passport.n3 +0 -156
  202. package/see/examples/n3/dijkstra.n3 +0 -46
  203. package/see/examples/n3/dog.n3 +0 -20
  204. package/see/examples/n3/equals.n3 +0 -11
  205. package/see/examples/n3/equivalence_classes_overlap_implies_same_class.n3 +0 -19
  206. package/see/examples/n3/euler_identity.n3 +0 -41
  207. package/see/examples/n3/ev_roundtrip_planner.n3 +0 -82
  208. package/see/examples/n3/existential_rule.n3 +0 -10
  209. package/see/examples/n3/expression_eval.n3 +0 -21
  210. package/see/examples/n3/family_cousins.n3 +0 -62
  211. package/see/examples/n3/fastpow.n3 +0 -56
  212. package/see/examples/n3/fibonacci.n3 +0 -44
  213. package/see/examples/n3/french_cities.n3 +0 -28
  214. package/see/examples/n3/fundamental_theorem_arithmetic.n3 +0 -84
  215. package/see/examples/n3/goldbach_1000.n3 +0 -66
  216. package/see/examples/n3/good_cobbler.n3 +0 -10
  217. package/see/examples/n3/gps.n3 +0 -70
  218. package/see/examples/n3/gray_code_counter.n3 +0 -53
  219. package/see/examples/n3/greatest_lower_bound_uniqueness.n3 +0 -20
  220. package/see/examples/n3/group_inverse_uniqueness.n3 +0 -19
  221. package/see/examples/n3/hadamard_approx.n3 +0 -43
  222. package/see/examples/n3/hanoi.n3 +0 -16
  223. package/see/examples/n3/odrl_dpv_risk_ranked.n3 +0 -460
  224. package/see/examples/n3/path_discovery.n3 +0 -43
  225. package/see/examples/n3/socrates.n3 +0 -21
  226. package/see/examples/n3/wind_turbine.n3 +0 -85
  227. package/see/examples/n3/witch.n3 +0 -30
  228. package/see/examples/odrl_dpv_risk_ranked.js +0 -5128
  229. package/see/examples/output/age.md +0 -48
  230. package/see/examples/output/annotation.md +0 -43
  231. package/see/examples/output/backward.md +0 -50
  232. package/see/examples/output/backward_recursion.md +0 -54
  233. package/see/examples/output/bayes_diagnosis.md +0 -103
  234. package/see/examples/output/bayes_therapy.md +0 -84
  235. package/see/examples/output/bmi.md +0 -164
  236. package/see/examples/output/builtin_coverage.md +0 -99
  237. package/see/examples/output/collection.md +0 -44
  238. package/see/examples/output/complex.md +0 -61
  239. package/see/examples/output/complex_matrix_stability.md +0 -55
  240. package/see/examples/output/composition_of_injective_functions_is_injective.md +0 -62
  241. package/see/examples/output/control_system.md +0 -61
  242. package/see/examples/output/crypto_builtins_tests.md +0 -68
  243. package/see/examples/output/delfour.md +0 -100
  244. package/see/examples/output/digital_product_passport.md +0 -100
  245. package/see/examples/output/dijkstra.md +0 -74
  246. package/see/examples/output/dijkstra_risk_path.md +0 -76
  247. package/see/examples/output/dog.md +0 -50
  248. package/see/examples/output/eco_route_insight.md +0 -88
  249. package/see/examples/output/equals.md +0 -50
  250. package/see/examples/output/equivalence_classes_overlap_implies_same_class.md +0 -86
  251. package/see/examples/output/euler_identity.md +0 -73
  252. package/see/examples/output/ev_roundtrip_planner.md +0 -79
  253. package/see/examples/output/existential_rule.md +0 -54
  254. package/see/examples/output/expression_eval.md +0 -50
  255. package/see/examples/output/family_cousins.md +0 -187
  256. package/see/examples/output/fastpow.md +0 -36
  257. package/see/examples/output/fibonacci.md +0 -53
  258. package/see/examples/output/french_cities.md +0 -70
  259. package/see/examples/output/fundamental_theorem_arithmetic.md +0 -101
  260. package/see/examples/output/genetic_knapsack_selection.md +0 -66
  261. package/see/examples/output/goldbach_1000.md +0 -58
  262. package/see/examples/output/good_cobbler.md +0 -54
  263. package/see/examples/output/gps.md +0 -102
  264. package/see/examples/output/gray_code_counter.md +0 -68
  265. package/see/examples/output/greatest_lower_bound_uniqueness.md +0 -60
  266. package/see/examples/output/group_inverse_uniqueness.md +0 -60
  267. package/see/examples/output/hadamard_approx.md +0 -510
  268. package/see/examples/output/hanoi.md +0 -51
  269. package/see/examples/output/odrl_dpv_risk_ranked.md +0 -139
  270. package/see/examples/output/path_discovery.md +0 -65
  271. package/see/examples/output/rc_discharge_envelope.md +0 -102
  272. package/see/examples/output/rdf_dataset.md +0 -54
  273. package/see/examples/output/rdf_message_flow.md +0 -198
  274. package/see/examples/output/rdf_messages.md +0 -134
  275. package/see/examples/output/school_placement_audit.md +0 -99
  276. package/see/examples/output/smoke_arithmetic.md +0 -54
  277. package/see/examples/output/socrates.md +0 -55
  278. package/see/examples/output/triple_terms.md +0 -53
  279. package/see/examples/output/wind_turbine.md +0 -108
  280. package/see/examples/output/witch.md +0 -87
  281. package/see/examples/path_discovery.js +0 -1774
  282. package/see/examples/rc_discharge_envelope.js +0 -1993
  283. package/see/examples/rdf_dataset.js +0 -1512
  284. package/see/examples/rdf_message_flow.js +0 -2580
  285. package/see/examples/rdf_messages.js +0 -2176
  286. package/see/examples/school_placement_audit.js +0 -1867
  287. package/see/examples/smoke_arithmetic.js +0 -1483
  288. package/see/examples/socrates.js +0 -1420
  289. package/see/examples/triple_terms.js +0 -1442
  290. package/see/examples/wind_turbine.js +0 -2853
  291. package/see/examples/witch.js +0 -1519
  292. package/see/see.js +0 -2179
  293. package/test/see.test.js +0 -159
  294. /package/{see/examples/n3/builtin_coverage.n3 → examples/builtin-coverage.n3} +0 -0
@@ -1,44 +0,0 @@
1
- # Collection
2
-
3
- ## Entailment
4
- The derivation produced 0 new fact(s) from 2 stated fact(s).
5
- Main entailment: **_:b2 :p :q.**
6
-
7
- Selected entailments:
8
- - _:b2 :p :q .
9
- - (1 _:b2 (2)) :p2 :q2 .
10
-
11
- ## Explanation
12
- Starts with 2 source fact(s), applies 0 rule(s), and reaches a fixpoint.
13
-
14
- Selected explanation support:
15
- - _:b2 :p :q . _(source)_
16
- - (1 _:b2 (2)) :p2 :q2 . _(source)_
17
-
18
- The selected facts are serialized in the Formal TriG Output section.
19
-
20
- ## Formal TriG Output
21
-
22
- ```trig
23
- @prefix : <https://eyereasoner.github.io/see/examples/collection#> .
24
- @prefix log: <http://www.w3.org/2000/10/swap/log#> .
25
- @prefix see: <https://example.org/see#> .
26
- @prefix in: <https://example.org/see/input#> .
27
- @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
28
-
29
- in:metadata {
30
- in:run a see:InputDataset .
31
- in:run see:name "collection" .
32
- in:run see:title "Collection" .
33
- in:run see:sourceFile "examples/n3/collection.n3" .
34
- in:run see:sourceSHA256 "ebce812d5e37729432cb77a638cde078af333450cc12ebd66b06083867cee7fa" .
35
- in:run see:description "" .
36
- in:run see:compiler "see.js N3-to-JS compiler" .
37
- in:run see:inputFacts 2 .
38
- in:run see:compiledRules 0 .
39
- in:run see:compiledBackwardRules 0 .
40
- in:run see:compiledFuses 0 .
41
- in:run see:compiledQueries 0 .
42
- }
43
- ```
44
-
@@ -1,61 +0,0 @@
1
- # Complex numbers
2
-
3
- ## Entailment
4
- The derivation produced 1 formula-valued entailment(s).
5
- Main entailment: **:test is { ((-1 0) (0.5 0)) complex:exponentiation (-3.49148133884313e-15 1) . ((2.71828182845905 0) (0 3.14159265358979)) complex:exponentiation (-1 3.23108914886517e-15) . ((0 1) (0 1)) complex:exponentiation (0.207879576350761 0) . ((2.71828182845905 0) (-1.57079632679 0)) complex:exponentiation (0.207879576351779 0) . (2 0) complex:asin (1.5707963267949 1.31695789692482) . (2 0) complex:acos (0 -1.31695789692482) }.**
6
-
7
- Selected entailments:
8
- - :test :is { ((-1 0) (0.5 0)) complex:exponentiation (-3.49148133884313e-15 1) . ((2.71828182845905 0) (0 3.14159265358979)) complex:exponentiation (-1 3.23108914886517e-15) . ((0 1) (0 1)) complex:exponentiation (0.207879576350761 0) . ((2.71828182845905 0) (-1.57079632679 0)) complex:exponentiation (0.207879576351779 0) . (2 0) complex:asin (1.5707963267949 1.31695789692482) . (2 0) complex:acos (0 -1.31695789692482) } .
9
-
10
- ## Explanation
11
- Starts with 0 source fact(s), applies 9 rule(s), and reaches a fixpoint.
12
-
13
- Derivation steps:
14
- - Rule 9 (6 premise pattern(s) => 1 conclusion pattern(s)) derives :test :is { ((-1 0) (0.5 0)) complex:exponentiation (-3.49148133884313e-15 1) . ((2.71828182845905 0) (0 3.14159265358979)) complex:exponentiation (-1 3.23108914886517e-15) . ((0 1) (0 1)) complex:exponentiation (0.207879576350761 0) . ((2.71828182845905 0) (-1.57079632679 0)) complex:exponentiation (0.207879576351779 0) . (2 0) complex:asin (1.5707963267949 1.31695789692482) . (2 0) complex:acos (0 -1.31695789692482) } .
15
- - Uses: no graph premises; built-ins/constants satisfied the rule.
16
-
17
- Selected explanation support:
18
- - :test :is { ((-1 0) (0.5 0)) complex:exponentiation (-3.49148133884313e-15 1) . ((2.71828182845905 0) (0 3.14159265358979)) complex:exponentiation (-1 3.23108914886517e-15) . ((0 1) (0 1)) complex:exponentiation (0.207879576350761 0) . ((2.71828182845905 0) (-1.57079632679 0)) complex:exponentiation (0.207879576351779 0) . (2 0) complex:asin (1.5707963267949 1.31695789692482) . (2 0) complex:acos (0 -1.31695789692482) } . _(derived by Rule 9)_
19
- - no graph premises; built-ins/constants satisfied the rule.
20
-
21
- The formula-valued facts are serialized in the Formal TriG Output section.
22
-
23
- ## Formal TriG Output
24
-
25
- ```trig
26
- @prefix math: <http://www.w3.org/2000/10/swap/math#> .
27
- @prefix log: <http://www.w3.org/2000/10/swap/log#> .
28
- @prefix complex: <https://eyereasoner.github.io/eye/complex#> .
29
- @prefix : <http://example.org/#> .
30
- @prefix see: <https://example.org/see#> .
31
- @prefix in: <https://example.org/see/input#> .
32
- @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
33
- @prefix out: <https://example.org/see/output#> .
34
-
35
- :test :is out:formula1 .
36
-
37
- out:formula1 {
38
- ((-1 0) (0.5 0)) complex:exponentiation (-3.49148133884313e-15 1) .
39
- ((2.71828182845905 0) (0 3.14159265358979)) complex:exponentiation (-1 3.23108914886517e-15) .
40
- ((0 1) (0 1)) complex:exponentiation (0.207879576350761 0) .
41
- ((2.71828182845905 0) (-1.57079632679 0)) complex:exponentiation (0.207879576351779 0) .
42
- (2 0) complex:asin (1.5707963267949 1.31695789692482) .
43
- (2 0) complex:acos (0 -1.31695789692482) .
44
- }
45
-
46
- in:metadata {
47
- in:run a see:InputDataset .
48
- in:run see:name "complex" .
49
- in:run see:title "Complex numbers" .
50
- in:run see:sourceFile "examples/n3/complex.n3" .
51
- in:run see:sourceSHA256 "f06171b97fcf380a64522165c21d4544ef88af39e5f8a679aad2e51bcc63c2b6" .
52
- in:run see:description "See https://en.wikipedia.org/wiki/Complex_number" .
53
- in:run see:compiler "see.js N3-to-JS compiler" .
54
- in:run see:inputFacts 0 .
55
- in:run see:compiledRules 1 .
56
- in:run see:compiledBackwardRules 8 .
57
- in:run see:compiledFuses 0 .
58
- in:run see:compiledQueries 0 .
59
- }
60
- ```
61
-
@@ -1,55 +0,0 @@
1
- # Complex Matrix Stability
2
-
3
- ## Entailment
4
- A_unstable = [[(1,1),(0,0)],[(0,0),(2,0)]] has spectral radius 2 and is unstable. A_stable = [[(1,0),(0,0)],[(0,0),(-1,0)]] has spectral radius 1 and is marginally stable. A_damped = [[(0,0),(0,0)],[(0,0),(0,0)]] has spectral radius 0 and is damped.
5
-
6
- ## Explanation
7
- For a discrete-time linear system x_{k+1} = A x_k, diagonal matrix eigenvalues are the diagonal entries. The largest squared complex modulus determines the spectral radius class. The N3 derivation also validates that |z*w|^2 = |z|^2*|w|^2 for a concrete complex product and that scaling A_unstable by 2 multiplies the squared spectral radius by 4.
8
-
9
- **Generated derivation support**
10
-
11
- Compiled support: 40 source fact(s), 17 rule(s), fixpoint reached before rendering.
12
-
13
- Derivation steps:
14
- - Rule 16 (9 premise pattern(s) => 1 conclusion pattern(s)) derives :Case :scenarioOk true .
15
- - Uses: :Case :unstableMatrix :A_unstable . _(source)_; :Case :stableMatrix :A_stable . _(source)_; :Case :dampedMatrix :A_damped . _(source)_
16
- - Rule 17 (8 premise pattern(s) => 1 conclusion pattern(s)) derives :report log:outputString "[authored report]" .
17
- - Uses: :Case :scenarioOk true . _(derived)_; :A_unstable :pretty "[[(1,1),(0,0)],[(0,0),(2,0)]]" . _(source)_; :A_stable :pretty "[[(1,0),(0,0)],[(0,0),(-1,0)]]" . _(source)_; :A_damped :pretty "[[(0,0),(0,0)],[(0,0),(0,0)]]" . _(source)_
18
-
19
- Selected explanation support:
20
- - :report log:outputString "[authored report]" . _(authored report, Rule 17)_
21
- - :Case :scenarioOk true . _(derived by Rule 16)_
22
- - :Case :unstableMatrix :A_unstable . _(source)_
23
- - :Case :stableMatrix :A_stable . _(source)_
24
- - :Case :dampedMatrix :A_damped . _(source)_
25
-
26
- ## Formal TriG Output
27
-
28
- ```trig
29
- @prefix : <https://eyereasoner.github.io/see/examples/complex-matrix-stability#> .
30
- @prefix log: <http://www.w3.org/2000/10/swap/log#> .
31
- @prefix math: <http://www.w3.org/2000/10/swap/math#> .
32
- @prefix string: <http://www.w3.org/2000/10/swap/string#> .
33
- @prefix see: <https://example.org/see#> .
34
- @prefix in: <https://example.org/see/input#> .
35
- @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
36
-
37
- :Case :scenarioOk true .
38
- :report log:outputString "=== Answer ===\nA_unstable = [[(1,1),(0,0)],[(0,0),(2,0)]] has spectral radius 2 and is unstable. A_stable = [[(1,0),(0,0)],[(0,0),(-1,0)]] has spectral radius 1 and is marginally stable. A_damped = [[(0,0),(0,0)],[(0,0),(0,0)]] has spectral radius 0 and is damped.\n\n=== Explanation ===\nFor a discrete-time linear system x_{k+1} = A x_k, diagonal matrix eigenvalues are the diagonal entries. The largest squared complex modulus determines the spectral radius class. The N3 derivation also validates that |z*w|^2 = |z|^2*|w|^2 for a concrete complex product and that scaling A_unstable by 2 multiplies the squared spectral radius by 4." .
39
-
40
- in:metadata {
41
- in:run a see:InputDataset .
42
- in:run see:name "complex_matrix_stability" .
43
- in:run see:title "Complex Matrix Stability" .
44
- in:run see:sourceFile "examples/n3/complex_matrix_stability.n3" .
45
- in:run see:sourceSHA256 "0ffed52d668e21ce26c5de11d2783603153ab79b6e2f92dece41e70777531297" .
46
- in:run see:description "Diagonal 2x2 complex matrices are classified for discrete-time stability.\nThis adapts the Eyeling complex matrix example as a committed SEE N3\nsource that compiles to a standalone JavaScript example." .
47
- in:run see:compiler "see.js N3-to-JS compiler" .
48
- in:run see:inputFacts 40 .
49
- in:run see:compiledRules 2 .
50
- in:run see:compiledBackwardRules 15 .
51
- in:run see:compiledFuses 0 .
52
- in:run see:compiledQueries 0 .
53
- }
54
- ```
55
-
@@ -1,62 +0,0 @@
1
- # Composition of injective functions is injective.
2
-
3
- ## Entailment
4
- The compiled query selected 2 fact(s) after the rule closure was computed.
5
- Main entailment: **:result :sameInputByCompositeInjectivity (:h :b :a).**
6
-
7
- Selected entailments:
8
- - :result :sameInputByCompositeInjectivity (:h :b :a) .
9
- - :result :sameInputByCompositeInjectivity (:h :a :b) .
10
-
11
- ## Explanation
12
- Starts with 12 source fact(s), applies 8 rule(s), and reaches a fixpoint.
13
- The log:query projection then keeps only the matching fact(s) shown above.
14
-
15
- Derivation steps:
16
- - Rule 1: ?x :inX true => (?x ?x) :sameTerm true derives (:a :a) :sameTerm true ., (:b :b) :sameTerm true .
17
- - Uses: :a :inX true . _(source)_; :b :inX true . _(source)_
18
- - Rule 2: ?y :inY true => (?y ?y) :sameTerm true derives (:p :p) :sameTerm true ., (:q :q) :sameTerm true .
19
- - Uses: :p :inY true . _(source)_; :q :inY true . _(source)_
20
- - Rule 3: ?z :inZ true => (?z ?z) :sameTerm true derives (:r :r) :sameTerm true .
21
- - Uses: :r :inZ true . _(source)_
22
- - Rule 6 (4 premise pattern(s) => 1 conclusion pattern(s)) derives (:p :q) :sameTerm true ., (:q :p) :sameTerm true ., (:a :b) :sameTerm true ., (:b :a) :sameTerm true .
23
- - Uses: :g :injective true . _(source)_; (:g :p) :app :r . _(source)_; (:g :q) :app :r . _(source)_; (:r :r) :sameTerm true . _(derived)_; … +5 more premise fact(s)
24
- - Rule 7 (3 premise pattern(s) => 1 conclusion pattern(s)) derives (:h :a) :app :r ., (:h :b) :app :r .
25
- - Uses: :h :compositeOf (:g :f) . _(source)_; (:f :a) :app :p . _(source)_; (:g :p) :app :r . _(source)_; (:f :b) :app :q . _(source)_; … +1 more premise fact(s)
26
- - Rule 8 (9 premise pattern(s) => 1 conclusion pattern(s)) derives (:h :a :a) :sameInputUnderEqualCompositeOutput true ., (:h :b :b) :sameInputUnderEqualCompositeOutput true ., (:h :a :b) :sameInputUnderEqualCompositeOutput true ., (:h :b :a) :sameInputUnderEqualCompositeOutput true .
27
- - Uses: :h :compositeOf (:g :f) . _(source)_; :f :injective true . _(source)_; :g :injective true . _(source)_; (:f :a) :app :p . _(source)_; … +8 more premise fact(s)
28
-
29
- Selected explanation support:
30
- - :result :sameInputByCompositeInjectivity (:h :b :a) . _(no recorded rule support)_
31
- - :result :sameInputByCompositeInjectivity (:h :a :b) . _(no recorded rule support)_
32
-
33
- The query-selected facts are serialized in the Formal TriG Output section.
34
-
35
- ## Formal TriG Output
36
-
37
- ```trig
38
- @prefix : <https://eyereasoner.github.io/eye/reasoning#> .
39
- @prefix log: <http://www.w3.org/2000/10/swap/log#> .
40
- @prefix see: <https://example.org/see#> .
41
- @prefix in: <https://example.org/see/input#> .
42
- @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
43
-
44
- :result :sameInputByCompositeInjectivity (:h :a :b) .
45
- :result :sameInputByCompositeInjectivity (:h :b :a) .
46
-
47
- in:metadata {
48
- in:run a see:InputDataset .
49
- in:run see:name "composition_of_injective_functions_is_injective" .
50
- in:run see:title "Composition of injective functions is injective." .
51
- in:run see:sourceFile "examples/n3/composition_of_injective_functions_is_injective.n3" .
52
- in:run see:sourceSHA256 "59429a6490d6587b42c78b3206d390c6a9c1570a2fcdfa09407be0261c99b88f" .
53
- in:run see:description "" .
54
- in:run see:compiler "see.js N3-to-JS compiler" .
55
- in:run see:inputFacts 12 .
56
- in:run see:compiledRules 8 .
57
- in:run see:compiledBackwardRules 0 .
58
- in:run see:compiledFuses 0 .
59
- in:run see:compiledQueries 1 .
60
- }
61
- ```
62
-
@@ -1,61 +0,0 @@
1
- # Control System
2
-
3
- ## Entailment
4
- The compiled query selected 2 fact(s) after the rule closure was computed.
5
- Main entailment: **:actuator2 :control1 26.08.**
6
-
7
- Selected entailments:
8
- - :actuator2 :control1 26.08 .
9
- - :actuator1 :control1 39.2734619867828 .
10
-
11
- ## Explanation
12
- Starts with 7 source fact(s), applies 4 rule(s), and reaches a fixpoint.
13
- The log:query projection then keeps only the matching fact(s) shown above.
14
-
15
- Derivation steps:
16
- - Rule 1 (6 premise pattern(s) => 1 conclusion pattern(s)) derives :actuator1 :control1 39.2734619867828 .
17
- - Uses: :input2 :measurement2 true . _(source)_; :disturbance1 :measurement3 35766 . _(source)_
18
- - Rule 2 (10 premise pattern(s) => 1 conclusion pattern(s)) derives :actuator2 :control1 26.08 .
19
- - Uses: :input3 :measurement3 56967 . _(source)_; :state3 :observation3 22 . _(source)_; :output2 :measurement4 24 . _(source)_; :output2 :target2 29 . _(source)_
20
-
21
- Selected explanation support:
22
- - :actuator2 :control1 26.08 . _(derived by Rule 2)_
23
- - :input3 :measurement3 56967 . _(source)_
24
- - :state3 :observation3 22 . _(source)_
25
- - :output2 :measurement4 24 . _(source)_
26
- - :output2 :target2 29 . _(source)_
27
- - :actuator1 :control1 39.2734619867828 . _(derived by Rule 1)_
28
- - :input2 :measurement2 true . _(source)_
29
- - :disturbance1 :measurement3 35766 . _(source)_
30
-
31
- The query-selected facts are serialized in the Formal TriG Output section.
32
-
33
- ## Formal TriG Output
34
-
35
- ```trig
36
- @prefix math: <http://www.w3.org/2000/10/swap/math#> .
37
- @prefix log: <http://www.w3.org/2000/10/swap/log#> .
38
- @prefix : <https://eyereasoner.github.io/see/examples/control-system#> .
39
- @prefix see: <https://example.org/see#> .
40
- @prefix in: <https://example.org/see/input#> .
41
- @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
42
-
43
- :actuator1 :control1 39.2734619867828 .
44
- :actuator2 :control1 26.08 .
45
-
46
- in:metadata {
47
- in:run a see:InputDataset .
48
- in:run see:name "control_system" .
49
- in:run see:title "Control System" .
50
- in:run see:sourceFile "examples/n3/control_system.n3" .
51
- in:run see:sourceSHA256 "0950a7098972ffc4883c2cc7410f7d54f5699111ecfc026bc88dba74ef0ffc40" .
52
- in:run see:description "Compact SEE version of the EYE reasoning/control-system example." .
53
- in:run see:compiler "see.js N3-to-JS compiler" .
54
- in:run see:inputFacts 7 .
55
- in:run see:compiledRules 2 .
56
- in:run see:compiledBackwardRules 2 .
57
- in:run see:compiledFuses 0 .
58
- in:run see:compiledQueries 1 .
59
- }
60
- ```
61
-
@@ -1,68 +0,0 @@
1
- # crypto builtins tests
2
-
3
- ## Entailment
4
- The derivation produced 4 new fact(s) from 0 stated fact(s).
5
- Main entailment: **:ok_crypto_sha512_1 is a :Pass.**
6
-
7
- Selected entailments:
8
- - :ok_crypto_sha512_1 rdf:type :Pass .
9
- - :ok_crypto_sha256_1 rdf:type :Pass .
10
- - :ok_crypto_md5_1 rdf:type :Pass .
11
- - :ok_crypto_sha_1 rdf:type :Pass .
12
-
13
- ## Explanation
14
- Starts with 0 source fact(s), applies 4 rule(s), and reaches a fixpoint.
15
-
16
- Derivation steps:
17
- - Rule 1: "hello world" crypto:sha "2aae6c35c94fcfb415dbe95f408b9ce91ee846ed" => :ok_crypto_sha_1 rdf:type :Pass derives :ok_crypto_sha_1 rdf:type :Pass .
18
- - Uses: no graph premises; built-ins/constants satisfied the rule.
19
- - Rule 2: "hello world" crypto:md5 "5eb63bbbe01eeed093cb22bb8f5acdc3" => :ok_crypto_md5_1 rdf:type :Pass derives :ok_crypto_md5_1 rdf:type :Pass .
20
- - Uses: no graph premises; built-ins/constants satisfied the rule.
21
- - Rule 3: "hello world" crypto:sha256 "b94d27b9934d3e08a52e52d7da7dabfac484efe37a5380ee9088f7ace2efcde9" => :ok_crypto_sha256_1 rdf:type :Pass derives :ok_crypto_sha256_1 rdf:type :Pass .
22
- - Uses: no graph premises; built-ins/constants satisfied the rule.
23
- - Rule 4: "hello world" crypto:sha512 "309ecc489c12d6eb4cc40f50c902f2b4d0ed77ee511a7c7a9bcd3ca86d4cd86f989dd35bc5ff499670da34255b45b0cfd830e81f605dcf7dc5542e93ae9cd76f" => :ok_crypto_sha512_1 rdf:type :Pass derives :ok_crypto_sha512_1 rdf:type :Pass .
24
- - Uses: no graph premises; built-ins/constants satisfied the rule.
25
-
26
- Selected explanation support:
27
- - :ok_crypto_sha512_1 rdf:type :Pass . _(derived by Rule 4)_
28
- - no graph premises; built-ins/constants satisfied the rule.
29
- - :ok_crypto_sha256_1 rdf:type :Pass . _(derived by Rule 3)_
30
- - no graph premises; built-ins/constants satisfied the rule.
31
- - :ok_crypto_md5_1 rdf:type :Pass . _(derived by Rule 2)_
32
- - no graph premises; built-ins/constants satisfied the rule.
33
- - :ok_crypto_sha_1 rdf:type :Pass . _(derived by Rule 1)_
34
- - no graph premises; built-ins/constants satisfied the rule.
35
-
36
- The selected facts are serialized in the Formal TriG Output section.
37
-
38
- ## Formal TriG Output
39
-
40
- ```trig
41
- @prefix : <https://eyereasoner.github.io/see/examples/crypto-builtins-tests#> .
42
- @prefix crypto: <http://www.w3.org/2000/10/swap/crypto#> .
43
- @prefix log: <http://www.w3.org/2000/10/swap/log#> .
44
- @prefix see: <https://example.org/see#> .
45
- @prefix in: <https://example.org/see/input#> .
46
- @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
47
-
48
- :ok_crypto_sha_1 rdf:type :Pass .
49
- :ok_crypto_md5_1 rdf:type :Pass .
50
- :ok_crypto_sha256_1 rdf:type :Pass .
51
- :ok_crypto_sha512_1 rdf:type :Pass .
52
-
53
- in:metadata {
54
- in:run a see:InputDataset .
55
- in:run see:name "crypto_builtins_tests" .
56
- in:run see:title "crypto builtins tests" .
57
- in:run see:sourceFile "examples/n3/crypto_builtins_tests.n3" .
58
- in:run see:sourceSHA256 "36867ada425da37071cbc96e74a10311adbfe437adf3d8e56b4a1d95a23763b5" .
59
- in:run see:description "" .
60
- in:run see:compiler "see.js N3-to-JS compiler" .
61
- in:run see:inputFacts 0 .
62
- in:run see:compiledRules 4 .
63
- in:run see:compiledBackwardRules 0 .
64
- in:run see:compiledFuses 0 .
65
- in:run see:compiledQueries 0 .
66
- }
67
- ```
68
-
@@ -1,100 +0,0 @@
1
- # Delfour
2
-
3
- ## Entailment
4
- The scanner is allowed to use a neutral shopping insight and recommends Low-Sugar Tea Biscuits instead of Classic Tea Biscuits.
5
- case : delfour
6
- decision : Allowed
7
- scanned product : Classic Tea Biscuits
8
- suggested alternative: Low-Sugar Tea Biscuits
9
-
10
- ## Explanation
11
- The phone desensitizes a diabetes-related household condition into a scoped low-sugar need, wraps it in an expiring Insight + Policy envelope, and the scanner consumes that envelope for shopping assistance.
12
- metric : sugar_g_per_serving
13
- threshold : 10.0
14
- scope : self-scanner @ pick_up_scanner
15
- retailer : Delfour
16
- signature alg : SHA-256
17
- banner headline : Track sugar per serving while you scan
18
- expires at : 2025-10-05T22:33:48Z
19
- audit entries : 1
20
- bus files written : 6
21
-
22
- **Generated derivation support**
23
-
24
- Compiled support: 61 source fact(s), 16 rule(s), fixpoint reached before rendering.
25
-
26
- Derivation steps:
27
- - Rule 1: :householdProfile :condition "Diabetes" => :case :needsLowSugar true derives :case :needsLowSugar true .
28
- - Uses: :householdProfile :condition "Diabetes" . _(source)_
29
- - Rule 2: :case :needsLowSugar true => :insight :derivedFromNeed "low_sugar" derives :insight :derivedFromNeed "low_sugar" .
30
- - Uses: :case :needsLowSugar true . _(derived)_
31
- - Rule 3 (3 premise pattern(s) => 1 conclusion pattern(s)) derives :assurance :payloadHashMatches true .
32
- - Uses: :envelope :canonicalJson "insight=lower_sugar;policy=shopping_assist_only;expires=2025-10-05T22:33:48Z" . _(source)_; :signature :payloadHashSHA256 "9025c5ccc1cc3e97aa639e3ca2d62e65ba0abed9cf3573b487c61d8cec6b3460" . _(source)_
33
- - Rule 4: :insight :serializedLowercase ?s; ?s string:notMatches "diabetes|medical" => :assurance :minimizationStripsSensitiveTerms true derives :assurance :minimizationStripsSensitiveTerms true .
34
- - Uses: :insight :serializedLowercase "metric=sugar_g_per_serving;retailer=delfour;threshold=10.0;scope=self-scanner" . _(source)_
35
- - Rule 5 (3 premise pattern(s) => 1 conclusion pattern(s)) derives :assurance :scopeComplete true .
36
- - Uses: :insight :scopeDevice "self-scanner" . _(source)_; :insight :scopeEvent "pick_up_scanner" . _(source)_; :insight :expiresAt "2025-10-05T22:33:48Z" . _(source)_
37
- - Rule 6 (8 premise pattern(s) => 2 conclusion pattern(s)) derives :decision :outcome "Allowed" ., :assurance :authorizationAllowed true .
38
- - Uses: _:blank1 odrl:action odrl:use . _(source)_; _:blank1 odrl:target :insight . _(source)_; _:blank2 odrl:rightOperand "shopping_assist" . _(source)_; _:blank1 odrl:constraint _:blank2 . _(source)_; … +3 more premise fact(s)
39
-
40
- Selected explanation support:
41
- - :delfour :suggests :lowSugarBiscuits . _(derived by Rule 19)_
42
- - :result :ready true . _(derived by Rule 15)_
43
- - :assurance :payloadHashMatches true . _(derived by Rule 3)_
44
- - :envelope :canonicalJson "insight=lower_sugar;policy=shopping_assist_only;expires=2025-10-05T22:33:48Z" . _(source)_
45
- - :signature :payloadHashSHA256 "9025c5ccc1cc3e97aa639e3ca2d62e65ba0abed9cf3573b487c61d8cec6b3460" . _(source)_
46
- - :assurance :minimizationStripsSensitiveTerms true . _(derived by Rule 4)_
47
- - :insight :serializedLowercase "metric=sugar_g_per_serving;retailer=delfour;threshold=10.0;scope=self-scanner" . _(source)_
48
- - :assurance :scopeComplete true . _(derived by Rule 5)_
49
- - :insight :scopeDevice "self-scanner" . _(source)_
50
- - :insight :scopeEvent "pick_up_scanner" . _(source)_
51
- - :insight :expiresAt "2025-10-05T22:33:48Z" . _(source)_
52
- - :assurance :authorizationAllowed true . _(derived by Rule 6)_
53
- - _:blank1 odrl:action odrl:use . _(source)_
54
- - _:blank1 odrl:target :insight . _(source)_
55
- - _:blank2 odrl:rightOperand "shopping_assist" . _(source)_
56
- - _:blank1 odrl:constraint _:blank2 . _(source)_
57
- - ... 3 more premise fact(s)
58
- - ... 5 more premise fact(s)
59
- - :scan :scannedProduct :classicBiscuits . _(source)_
60
- - :classicBiscuits :productName "Classic Tea Biscuits" . _(source)_
61
- - :case :suggestedAlternative :lowSugarBiscuits . _(derived by Rule 8)_
62
- - :scan :scannedProduct :classicBiscuits . _(source)_
63
- - :classicBiscuits :sugarTenths 120 . _(source)_
64
- - :lowSugarBiscuits rdf:type :Product . _(source)_
65
- - :lowSugarBiscuits :sugarTenths 30 . _(source)_
66
- - ... 12 more premise fact(s)
67
-
68
- ## Formal TriG Output
69
-
70
- ```trig
71
- @prefix : <https://eyereasoner.github.io/see/examples/delfour#> .
72
- @prefix ins: <https://example.org/insight#> .
73
- @prefix odrl: <http://www.w3.org/ns/odrl/2/> .
74
- @prefix math: <http://www.w3.org/2000/10/swap/math#> .
75
- @prefix string: <http://www.w3.org/2000/10/swap/string#> .
76
- @prefix crypto: <http://www.w3.org/2000/10/swap/crypto#> .
77
- @prefix log: <http://www.w3.org/2000/10/swap/log#> .
78
- @prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
79
- @prefix see: <https://example.org/see#> .
80
- @prefix in: <https://example.org/see/input#> .
81
- @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
82
-
83
- :delfour :suggests :lowSugarBiscuits .
84
-
85
- in:metadata {
86
- in:run a see:InputDataset .
87
- in:run see:name "delfour" .
88
- in:run see:title "Delfour" .
89
- in:run see:sourceFile "examples/n3/delfour.n3" .
90
- in:run see:sourceSHA256 "250631cb3de8addff7037b54789b63b2ea034eb6b579c61a9feca542efd584c1" .
91
- in:run see:description "N3-compiled version of the Delfour insight-economy example. A private phone\ncondition is desensitized into a scoped low-sugar insight; the scanner may use\nit for shopping assistance, but not for marketing." .
92
- in:run see:compiler "see.js N3-to-JS compiler" .
93
- in:run see:inputFacts 61 .
94
- in:run see:compiledRules 16 .
95
- in:run see:compiledBackwardRules 0 .
96
- in:run see:compiledFuses 3 .
97
- in:run see:compiledQueries 1 .
98
- }
99
- ```
100
-
@@ -1,100 +0,0 @@
1
- # Digital Product Passport
2
-
3
- ## Entailment
4
- Passport decision : PASS for ACME X1000 SN123.
5
- recycled content : 13%
6
- lifecycle footprint : 52500 gCO2e
7
- total component mass : 105 g
8
- critical raw materials : Lithium, Cobalt
9
- circularity hint : repairFriendly
10
- public endpoint : https://example.org/dpp/ACME-X1000-SN123
11
-
12
- ## Explanation
13
- The passport folds the explicit component list to derive total mass and recycled mass, then computes an integer recycled-content percentage. Lifecycle footprint is derived by summing manufacturing, transport, and use-phase emissions. The product is repair-friendly because the battery is replaceable and the public passport section exposes repair, spare-parts, and manual documentation. Restricted declarations remain in the restricted section.
14
-
15
- Component roll-up:
16
- BatteryPack-01 Battery mass=48g recycled=0g materials=Lithium, Cobalt, Nickel replaceable=yes
17
- Chassis-01 Housing mass=32g recycled=12g materials=Aluminium replaceable=no
18
- Mainboard-01 Electronics mass=25g recycled=2g materials=Copper, GoldTrace replaceable=no
19
- Public documents:
20
- Doc-UserManual UserManual https://example.org/manuals/acme-x1000
21
- Doc-RepairGuide RepairGuide https://example.org/repair/acme-x1000
22
- Doc-SpareParts SparePartsCatalog https://example.org/spares/acme-x1000
23
-
24
- **Generated derivation support**
25
-
26
- Compiled support: 90 source fact(s), 12 rule(s), fixpoint reached before rendering.
27
-
28
- Derivation steps:
29
- - Rule 1 (3 premise pattern(s) => 1 conclusion pattern(s)) derives :passport :exposesCriticalMaterial :Lithium ., :passport :exposesCriticalMaterial :Cobalt .
30
- - Uses: :ACME_X1000_SN123 :hasComponent :BatteryPack_01 . _(source)_; :BatteryPack_01 :containsMaterial :Lithium . _(source)_; :Lithium :criticalRawMaterial true . _(source)_; :BatteryPack_01 :containsMaterial :Cobalt . _(source)_; … +1 more premise fact(s)
31
- - Rule 2 (3 premise pattern(s) => 2 conclusion pattern(s)) derives :MassRollup :componentMass 48 ., :MassRollup :componentRecycledMass 0 ., :MassRollup :componentMass 32 ., :MassRollup :componentRecycledMass 12 ., … +2 more
32
- - Uses: :ACME_X1000_SN123 :hasComponent :BatteryPack_01 . _(source)_; :BatteryPack_01 :massG 48 . _(source)_; :BatteryPack_01 :recycledMassG 0 . _(source)_; :ACME_X1000_SN123 :hasComponent :Chassis_01 . _(source)_; … +5 more premise fact(s)
33
- - Rule 3 (4 premise pattern(s) => 3 conclusion pattern(s)) derives :passport :totalMassG 105 ., :passport :recycledMassG 14 ., :passport :recycledPct 13 .
34
- - Uses: no graph premises; built-ins/constants satisfied the rule.
35
- - Rule 4 (4 premise pattern(s) => 1 conclusion pattern(s)) derives :passport :lifecycleFootprintGCO2e 52500 .
36
- - Uses: :Footprint :manufacturingGCO2e 32000 . _(source)_; :Footprint :transportGCO2e 2500 . _(source)_; :Footprint :usePhaseGCO2e 18000 . _(source)_
37
- - Rule 5 (4 premise pattern(s) => 1 conclusion pattern(s)) derives :passport :hasRequiredPublicDocType :UserManual ., :passport :hasRequiredPublicDocType :RepairGuide ., :passport :hasRequiredPublicDocType :SparePartsCatalog .
38
- - Uses: :Policy :publicDocType :UserManual . _(source)_; :Doc_UserManual rdf:type :Document . _(source)_; :Doc_UserManual :docType :UserManual . _(source)_; :Doc_UserManual :section "public" . _(source)_; … +8 more premise fact(s)
39
- - Rule 6 (4 premise pattern(s) => 1 conclusion pattern(s)) derives :passport :keepsRestrictedDocTypeRestricted :DeclarationOfConformity ., :passport :keepsRestrictedDocTypeRestricted :SubstanceDeclaration .
40
- - Uses: :Policy :restrictedDocType :DeclarationOfConformity . _(source)_; :Doc_DoC_CE rdf:type :Document . _(source)_; :Doc_DoC_CE :docType :DeclarationOfConformity . _(source)_; :Doc_DoC_CE :section "restricted" . _(source)_; … +4 more premise fact(s)
41
-
42
- Selected explanation support:
43
- - :digitalProductPassport :decision "PASS" . _(derived by Rule 14)_
44
- - :passport :decision "PASS" . _(derived by Rule 11)_
45
- - :passport :massBalanced true . _(derived by Rule 10)_
46
- - :passport :totalMassG 105 . _(derived by Rule 3)_
47
- - no graph premises; built-ins/constants satisfied the rule.
48
- - :passport :recycledMassG 14 . _(derived by Rule 3)_
49
- - no graph premises; built-ins/constants satisfied the rule.
50
- - :passport :recycledPct 13 . _(derived by Rule 3)_
51
- - no graph premises; built-ins/constants satisfied the rule.
52
- - :passport :lifecycleFootprintGCO2e 52500 . _(derived by Rule 4)_
53
- - :Footprint :manufacturingGCO2e 32000 . _(source)_
54
- - :Footprint :transportGCO2e 2500 . _(source)_
55
- - :Footprint :usePhaseGCO2e 18000 . _(source)_
56
- - :passport :exposesCriticalMaterial :Lithium . _(derived by Rule 1)_
57
- - :ACME_X1000_SN123 :hasComponent :BatteryPack_01 . _(source)_
58
- - :BatteryPack_01 :containsMaterial :Lithium . _(source)_
59
- - :Lithium :criticalRawMaterial true . _(source)_
60
- - ... 9 more premise fact(s)
61
- - :passport :totalMassG 105 . _(derived by Rule 3)_
62
- - no graph premises; built-ins/constants satisfied the rule.
63
- - :passport :recycledPct 13 . _(derived by Rule 3)_
64
- - no graph premises; built-ins/constants satisfied the rule.
65
- - :passport :lifecycleFootprintGCO2e 52500 . _(derived by Rule 4)_
66
- - :Footprint :manufacturingGCO2e 32000 . _(source)_
67
- - :Footprint :transportGCO2e 2500 . _(source)_
68
- - :Footprint :usePhaseGCO2e 18000 . _(source)_
69
- - ... 3 more premise fact(s)
70
-
71
- ## Formal TriG Output
72
-
73
- ```trig
74
- @prefix : <https://eyereasoner.github.io/see/examples/digital-product-passport#> .
75
- @prefix math: <http://www.w3.org/2000/10/swap/math#> .
76
- @prefix list: <http://www.w3.org/2000/10/swap/list#> .
77
- @prefix log: <http://www.w3.org/2000/10/swap/log#> .
78
- @prefix string: <http://www.w3.org/2000/10/swap/string#> .
79
- @prefix see: <https://example.org/see#> .
80
- @prefix in: <https://example.org/see/input#> .
81
- @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
82
-
83
- :digitalProductPassport :decision "PASS" .
84
-
85
- in:metadata {
86
- in:run a see:InputDataset .
87
- in:run see:name "digital_product_passport" .
88
- in:run see:title "Digital Product Passport" .
89
- in:run see:sourceFile "examples/n3/digital_product_passport.n3" .
90
- in:run see:sourceSHA256 "502e99d8e51a930eba50cb2411263cb6db5d98d63fe3dd48254612d993a9ab95" .
91
- in:run see:description "N3-compiled version of the smartphone Digital Product Passport example. The\nrules fold component mass, recycled content, critical raw materials, public\ndocuments, lifecycle footprint, and access-policy validations into a public PASS." .
92
- in:run see:compiler "see.js N3-to-JS compiler" .
93
- in:run see:inputFacts 90 .
94
- in:run see:compiledRules 12 .
95
- in:run see:compiledBackwardRules 0 .
96
- in:run see:compiledFuses 2 .
97
- in:run see:compiledQueries 1 .
98
- }
99
- ```
100
-
@@ -1,74 +0,0 @@
1
- # Dijkstra's algorithm to find the shortest path
2
-
3
- ## Entailment
4
- The derivation produced 9 new fact(s) from 9 stated fact(s).
5
- Main entailment: **(:f :e) :edge 3.**
6
-
7
- Selected entailments:
8
- - (:f :e) :edge 3 .
9
- - (:f :d) :edge 6 .
10
- - (:e :d) :edge 2 .
11
- - (:e :c) :edge 10 .
12
- - (:d :c) :edge 8 .
13
- - (:d :b) :edge 5 .
14
-
15
- ## Explanation
16
- Starts with 9 source fact(s), applies 5 rule(s), and reaches a fixpoint.
17
-
18
- Derivation steps:
19
- - Rule 1: (?A ?B) :edge ?C => (?B ?A) :edge ?C derives (:b :a) :edge 4 ., (:c :a) :edge 2 ., (:c :b) :edge 1 ., (:d :b) :edge 5 ., … +5 more
20
- - Uses: (:a :b) :edge 4 . _(source)_; (:a :c) :edge 2 . _(source)_; (:b :c) :edge 1 . _(source)_; (:b :d) :edge 5 . _(source)_; … +5 more premise fact(s)
21
-
22
- Selected explanation support:
23
- - (:f :e) :edge 3 . _(derived by Rule 1)_
24
- - (:e :f) :edge 3 . _(source)_
25
- - (:f :d) :edge 6 . _(derived by Rule 1)_
26
- - (:d :f) :edge 6 . _(source)_
27
- - (:e :d) :edge 2 . _(derived by Rule 1)_
28
- - (:d :e) :edge 2 . _(source)_
29
- - (:e :c) :edge 10 . _(derived by Rule 1)_
30
- - (:c :e) :edge 10 . _(source)_
31
- - (:d :c) :edge 8 . _(derived by Rule 1)_
32
- - (:c :d) :edge 8 . _(source)_
33
- - (:d :b) :edge 5 . _(derived by Rule 1)_
34
- - (:b :d) :edge 5 . _(source)_
35
-
36
- The selected facts are serialized in the Formal TriG Output section.
37
-
38
- ## Formal TriG Output
39
-
40
- ```trig
41
- @prefix list: <http://www.w3.org/2000/10/swap/list#> .
42
- @prefix math: <http://www.w3.org/2000/10/swap/math#> .
43
- @prefix log: <http://www.w3.org/2000/10/swap/log#> .
44
- @prefix : <https://eyereasoner.github.io/see/examples/dijkstra#> .
45
- @prefix see: <https://example.org/see#> .
46
- @prefix in: <https://example.org/see/input#> .
47
- @prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
48
-
49
- (:b :a) :edge 4 .
50
- (:c :a) :edge 2 .
51
- (:c :b) :edge 1 .
52
- (:d :b) :edge 5 .
53
- (:d :c) :edge 8 .
54
- (:e :c) :edge 10 .
55
- (:e :d) :edge 2 .
56
- (:f :d) :edge 6 .
57
- (:f :e) :edge 3 .
58
-
59
- in:metadata {
60
- in:run a see:InputDataset .
61
- in:run see:name "dijkstra" .
62
- in:run see:title "Dijkstra's algorithm to find the shortest path" .
63
- in:run see:sourceFile "examples/n3/dijkstra.n3" .
64
- in:run see:sourceSHA256 "e877c1cfea99078228bd424f6e55761e56cc54bc1e64b21540231620cc3620ab" .
65
- in:run see:description "" .
66
- in:run see:compiler "see.js N3-to-JS compiler" .
67
- in:run see:inputFacts 9 .
68
- in:run see:compiledRules 2 .
69
- in:run see:compiledBackwardRules 3 .
70
- in:run see:compiledFuses 0 .
71
- in:run see:compiledQueries 0 .
72
- }
73
- ```
74
-