eyemind 0.5.19 → 0.5.20
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/README.md +26 -26
- package/SPEC.md +1 -1
- package/package.json +1 -1
- package/src/version.js +1 -1
package/README.md
CHANGED
|
@@ -200,9 +200,9 @@ A reified triple `<< s p o >>` and an annotation `{| ... |}` become their reifie
|
|
|
200
200
|
A file ending in `.n3` is Notation3: eyemind compiles its facts and rules into a program, with the N3 built-ins it uses written as eyemind rules, and writes the conclusions back as N3. RDF default-graph data joins the N3 document as triples:
|
|
201
201
|
|
|
202
202
|
```sh
|
|
203
|
-
eyemind examples/family.n3
|
|
204
|
-
eyemind --program examples/family.n3 > /tmp/family.js
|
|
205
|
-
eyemind -c examples/family.n3
|
|
203
|
+
eyemind examples/family-n3.n3 # the derived triples as N3
|
|
204
|
+
eyemind --program examples/family-n3.n3 > /tmp/family.js # the compiled program, to inspect
|
|
205
|
+
eyemind -c examples/family-n3.n3 # a proof of it, checked
|
|
206
206
|
```
|
|
207
207
|
|
|
208
208
|
Triples are `rdf(Subject, Predicate, Object)`, with IRIs, blank nodes and literals written as in the RDF table above. N3 integers and decimals become eyemind numbers; float and double literals retain their RDF datatype, including numbers written with an exponent. Decimals use binary64 storage; `math:sum` adds their canonical decimal values before rounding its result. `=>` becomes `implies`, or `restricted` when the conclusion has blank nodes of its own, `<=` becomes `implied_by`, `{ ... } => false` becomes `contradiction`, and scoped negation and collection become `not` and `findall`, so an N3 run has a proof that eyemind checks like any other. Derived rules can trigger inference fuses too.
|
|
@@ -233,11 +233,11 @@ for a quoted universal, as rules stated as data quote their variables.
|
|
|
233
233
|
`log:includes` never instantiates the universals of its subject. Matching in
|
|
234
234
|
nested graph terms below the first level is by unification, so it depends on
|
|
235
235
|
the order of their triples. See
|
|
236
|
-
[universal instances](https://eyereasoner.github.io/eyemind/examples/deck/universal-instances),
|
|
237
|
-
[a shared existential](https://eyereasoner.github.io/eyemind/examples/deck/shared-existential),
|
|
238
|
-
[an existential rule](https://eyereasoner.github.io/eyemind/examples/deck/explicit-existential-rule),
|
|
239
|
-
[quantifier scopes](https://eyereasoner.github.io/eyemind/examples/deck/quantifier-scopes) and
|
|
240
|
-
[graph terms](https://eyereasoner.github.io/eyemind/examples/deck/graph-terms).
|
|
236
|
+
[universal instances](https://eyereasoner.github.io/eyemind/examples/deck/universal-instances-n3),
|
|
237
|
+
[a shared existential](https://eyereasoner.github.io/eyemind/examples/deck/shared-existential-n3),
|
|
238
|
+
[an existential rule](https://eyereasoner.github.io/eyemind/examples/deck/explicit-existential-rule-n3),
|
|
239
|
+
[quantifier scopes](https://eyereasoner.github.io/eyemind/examples/deck/quantifier-scopes-n3) and
|
|
240
|
+
[graph terms](https://eyereasoner.github.io/eyemind/examples/deck/graph-terms-n3).
|
|
241
241
|
|
|
242
242
|
The Notation3 test suite case `static/success-literal-22.n3` expects the
|
|
243
243
|
pattern `{ _:X :B :C }` to match `{ :A :B :C }`. eyemind's scorer checks
|
|
@@ -260,17 +260,17 @@ inside their formulas; `?g graph:content ?data` and
|
|
|
260
260
|
`?data log:includes { ... }` inspect them. Contents with the same graph name
|
|
261
261
|
from several RDF inputs are combined, while blank nodes keep their source
|
|
262
262
|
scopes. Conclusions can attach further formulas to that name; the output
|
|
263
|
-
writes these as N3 formulas. See the [named graph example](https://eyereasoner.github.io/eyemind/examples/deck/trig-named-graph).
|
|
263
|
+
writes these as N3 formulas. See the [named graph example](https://eyereasoner.github.io/eyemind/examples/deck/trig-named-graph-n3).
|
|
264
264
|
|
|
265
265
|
Scoped calls can use formulas supplied by the document's stated lists, including RDF collections written with `rdf:first` and `rdf:rest`, and the named-graph formulas loaded from RDF. These calls are specialized before reasoning so their dependencies remain available for stratification and proof checking; formulas constructed only during reasoning are not supported by this compilation.
|
|
266
266
|
|
|
267
267
|
The documents `log:semantics`, `log:semanticsOrError` and `log:content` name are read before compiling. The command reads local files and HTTP(S) documents, with a ten-second fetch timeout and a 16 MiB response limit. The library uses the host callbacks `readFile(path)` and `readDocument(iri)`; without them it does not read external documents. Their contents become facts of the compiled program, which can be saved with `--program` for later proof checking.
|
|
268
268
|
|
|
269
269
|
Examples run directly from their N3 source in the playground and on the command line:
|
|
270
|
-
[family queries](https://eyereasoner.github.io/eyemind/examples/deck/family),
|
|
271
|
-
[scoped negation](https://eyereasoner.github.io/eyemind/examples/deck/scoped-negation),
|
|
272
|
-
[invoice collection](https://eyereasoner.github.io/eyemind/examples/deck/invoice),
|
|
273
|
-
[French cities](https://eyereasoner.github.io/eyemind/examples/deck/french-cities), and
|
|
270
|
+
[family queries](https://eyereasoner.github.io/eyemind/examples/deck/family-n3),
|
|
271
|
+
[scoped negation](https://eyereasoner.github.io/eyemind/examples/deck/scoped-negation-n3),
|
|
272
|
+
[invoice collection](https://eyereasoner.github.io/eyemind/examples/deck/invoice-n3),
|
|
273
|
+
[French cities](https://eyereasoner.github.io/eyemind/examples/deck/french-cities-n3), and
|
|
274
274
|
[existential witnesses](https://eyereasoner.github.io/eyemind/examples/deck/witnesses-n3).
|
|
275
275
|
Each deck shows the N3 result and what its saved proof establishes, including
|
|
276
276
|
any remaining obligations.
|
|
@@ -287,9 +287,9 @@ to their message. Prefix and base changes apply to subsequent data.
|
|
|
287
287
|
Whole-log replay gives N3 or JavaScript rules an ordered view of the messages:
|
|
288
288
|
|
|
289
289
|
```sh
|
|
290
|
-
eyemind examples/message-boundaries.n3 examples/data/message-boundaries.trig
|
|
291
|
-
eyemind --proof examples/message-boundaries.n3 examples/data/message-boundaries.trig
|
|
292
|
-
eyemind --check-proof examples/proof/message-boundaries.n3 examples/message-boundaries.n3 examples/data/message-boundaries.trig
|
|
290
|
+
eyemind examples/message-boundaries-n3.n3 examples/data/message-boundaries-n3.trig
|
|
291
|
+
eyemind --proof examples/message-boundaries-n3.n3 examples/data/message-boundaries-n3.trig
|
|
292
|
+
eyemind --check-proof examples/proof/message-boundaries-n3.n3 examples/message-boundaries-n3.n3 examples/data/message-boundaries-n3.trig
|
|
293
293
|
```
|
|
294
294
|
|
|
295
295
|
The replay vocabulary is `eymsg:`, with namespace
|
|
@@ -311,7 +311,7 @@ with `graph(...)` terms for payload formulas.
|
|
|
311
311
|
For independent processing, run the rules once per message:
|
|
312
312
|
|
|
313
313
|
```sh
|
|
314
|
-
eyemind --stream-messages examples/message-alerts.n3 examples/data/message-alerts.nt
|
|
314
|
+
eyemind --stream-messages examples/message-alerts-n3.n3 examples/data/message-alerts-n3.nt
|
|
315
315
|
```
|
|
316
316
|
|
|
317
317
|
The Node command incrementally reads files, standard input (`-`) or HTTP(S)
|
|
@@ -324,9 +324,9 @@ the ordinary N3, RDF or term format selected for the run.
|
|
|
324
324
|
The playground's **Independent RDF Messages** mode processes its loaded
|
|
325
325
|
text with the same boundaries. Whole-log replay supports proofs;
|
|
326
326
|
`--stream-messages` rejects proof, proof-checking, compiled-program and
|
|
327
|
-
unused-clause modes. The [message-boundaries](https://eyereasoner.github.io/eyemind/examples/deck/message-boundaries),
|
|
328
|
-
[message-alerts](https://eyereasoner.github.io/eyemind/examples/deck/message-alerts)
|
|
329
|
-
and [message-provenance](https://eyereasoner.github.io/eyemind/examples/deck/message-provenance)
|
|
327
|
+
unused-clause modes. The [message-boundaries](https://eyereasoner.github.io/eyemind/examples/deck/message-boundaries-n3),
|
|
328
|
+
[message-alerts](https://eyereasoner.github.io/eyemind/examples/deck/message-alerts-n3)
|
|
329
|
+
and [message-provenance](https://eyereasoner.github.io/eyemind/examples/deck/message-provenance-n3)
|
|
330
330
|
decks show the outputs and remaining proof obligations.
|
|
331
331
|
|
|
332
332
|
Library hosts can import `RdfMessageReader` and `parseRdfMessages` from
|
|
@@ -358,7 +358,7 @@ use binary64 arithmetic: `0.1e0 + 0.2e0` is
|
|
|
358
358
|
`"0.30000000000000004"^^xsd:double`. Floating-point overflow and division by
|
|
359
359
|
zero follow IEEE-754, including `INF`, `-INF`, `NaN` and signed zero; decimal
|
|
360
360
|
division by zero is an expression error. Mixed numeric expressions use
|
|
361
|
-
SPARQL type promotion. The [exact decimals example](https://eyereasoner.github.io/eyemind/examples/deck/exact-decimals)
|
|
361
|
+
SPARQL type promotion. The [exact decimals example](https://eyereasoner.github.io/eyemind/examples/deck/exact-decimals-srl)
|
|
362
362
|
shows both arithmetic models.
|
|
363
363
|
|
|
364
364
|
`NOW()` returns one UTC `xsd:dateTime` throughout a rule set evaluation.
|
|
@@ -374,7 +374,7 @@ recorded context; it does not attest the wall-clock time or the randomness
|
|
|
374
374
|
of the seed. Library calls to `compileSrl` and `reasonSrl` accept
|
|
375
375
|
`context: { now, seed }`, with an ISO UTC timestamp including milliseconds
|
|
376
376
|
and 64 lowercase hexadecimal seed digits, to reproduce an execution.
|
|
377
|
-
The [execution identifiers example](https://eyereasoner.github.io/eyemind/examples/deck/execution-identifiers)
|
|
377
|
+
The [execution identifiers example](https://eyereasoner.github.io/eyemind/examples/deck/execution-identifiers-srl)
|
|
378
378
|
has a fixed context in the example manifest for its saved artifacts;
|
|
379
379
|
ordinary command-line and playground runs capture fresh values.
|
|
380
380
|
|
|
@@ -403,10 +403,10 @@ inference. JavaScript programs write `step(...)` records. N3 inputs write
|
|
|
403
403
|
N3 proofs, and SRL inputs write SRL `DATA` proofs:
|
|
404
404
|
|
|
405
405
|
```sh
|
|
406
|
-
eyemind --proof examples/socrates.n3 > /tmp/socrates-proof.n3
|
|
407
|
-
eyemind --check-proof /tmp/socrates-proof.n3 examples/socrates.n3
|
|
408
|
-
eyemind --proof examples/socrates.srl > /tmp/socrates-proof.srl
|
|
409
|
-
eyemind --check-proof /tmp/socrates-proof.srl examples/socrates.srl
|
|
406
|
+
eyemind --proof examples/socrates-n3.n3 > /tmp/socrates-proof.n3
|
|
407
|
+
eyemind --check-proof /tmp/socrates-proof.n3 examples/socrates-n3.n3
|
|
408
|
+
eyemind --proof examples/socrates-srl.srl > /tmp/socrates-proof.srl
|
|
409
|
+
eyemind --check-proof /tmp/socrates-proof.srl examples/socrates-srl.srl
|
|
410
410
|
```
|
|
411
411
|
|
|
412
412
|
Native proofs use `pe:`, `https://eyereasoner.github.io/pe#`, for the claims,
|
package/SPEC.md
CHANGED
package/package.json
CHANGED
package/src/version.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
// The release this checkout is; ./release keeps it in step with package.json.
|
|
2
|
-
export const VERSION = '0.5.
|
|
2
|
+
export const VERSION = '0.5.20';
|