Skip to content

Commit

Permalink
implicit graph term scope of blank nodes
Browse files Browse the repository at this point in the history
  • Loading branch information
josd committed Oct 19, 2023
1 parent 115a79d commit f7d9ee6
Show file tree
Hide file tree
Showing 8 changed files with 43 additions and 25 deletions.
1 change: 1 addition & 0 deletions RELEASE
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
EYE release

v5.2.0 (2023-10-19) implicit graph term scope of blank nodes
v5.1.1 (2023-10-18) fixing --pass-only-new
v5.1.0 (2023-10-17) implicit global scope of blank nodes
v5.0.10 (2023-10-15) testing s(urface) equ(ivalent) ent(ailment)s
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
5.1.1
5.2.0
35 changes: 26 additions & 9 deletions eye.pl
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
:- use_module(library(pcre)).
:- catch(use_module(library(http/http_open)), _, true).

version_info('EYE v5.1.1 (2023-10-18)').
version_info('EYE v5.2.0 (2023-10-19)').

license_info('MIT License

Expand Down Expand Up @@ -962,6 +962,8 @@
% DEPRECATED
opts(['--blogic'|Argus], Args) :-
!,
retractall(flag(blogic)),
assertz(flag(blogic)),
opts(Argus, Args).
opts(['--csv-separator', Separator|Argus], Args) :-
!,
Expand Down Expand Up @@ -2725,14 +2727,29 @@
}.
symbol(Name) -->
[bnode(Lbl)],
{ atom_codes(Lbl, LblCodes),
subst([[[0'-], [0'_, 0'M, 0'I, 0'N, 0'U, 0'S, 0'_]], [[0'.], [0'_, 0'D, 0'O, 0'T, 0'_]]], LblCodes, LblTidy),
atom_codes(Label, LblTidy),
( evar(Label, S, 0)
-> true
; atom_concat(Label, '_', M),
gensym(M, S),
assertz(evar(Label, S, 0))
{ ( flag(blogic)
-> atom_codes(Lbl, LblCodes),
subst([[[0'-], [0'_, 0'M, 0'I, 0'N, 0'U, 0'S, 0'_]], [[0'.], [0'_, 0'D, 0'O, 0'T, 0'_]]], LblCodes, LblTidy),
atom_codes(Label, LblTidy),
( evar(Label, S, 0)
-> true
; atom_concat(Label, '_', M),
gensym(M, S),
assertz(evar(Label, S, 0))
)
; nb_getval(fdepth, D),
( D =:= 0
-> Label = Lbl
; atom_codes(Lbl, LblCodes),
subst([[[0'-], [0'_, 0'M, 0'I, 0'N, 0'U, 0'S, 0'_]], [[0'.], [0'_, 0'D, 0'O, 0'T, 0'_]]], LblCodes, LblTidy),
atom_codes(Label, LblTidy)
),
( evar(Label, S, D)
-> true
; atom_concat(Label, '_', M),
gensym(M, S),
assertz(evar(Label, S, D))
)
),
( ( nb_getval(entail_mode, false),
nb_getval(fdepth, 0)
Expand Down
Binary file modified eye.zip
Binary file not shown.
20 changes: 10 additions & 10 deletions reasoning/bi/biA.n3
Original file line number Diff line number Diff line change
Expand Up @@ -492,12 +492,12 @@
{
{
<http://eyereasoner.github.io/eye/reasoning/bi/ab_c.n3> log:semantics {
:a :b _:e_c_2.
:a :b _:e_c_14.
}.
{
:a :b _:e_c_2.
:a :b _:e_c_14.
} log:equalTo {
:a :b _:e_c_2.
:a :b _:e_c_14.
}.
} => {
:loges3 :result true.
Expand Down Expand Up @@ -663,12 +663,12 @@
{
{
<http://eyereasoner.github.io/eye/reasoning/bi/ab_c.n3> log:semantics {
:a :b _:e_c_2.
:a :b _:e_c_14.
}.
{
:a :b _:e_c_2.
:a :b _:e_c_14.
} log:includes {
:a :b _:e_c_2.
:a :b _:e_c_14.
}.
} => {
:logis3 :result true.
Expand Down Expand Up @@ -791,10 +791,10 @@
{
{
<http://eyereasoner.github.io/eye/reasoning/bi/ab_c.n3> log:semantics {
:a :b _:e_c_2.
:a :b _:e_c_14.
}.
{
:a :b _:e_c_2.
:a :b _:e_c_14.
} log:notIncludes {
:a :b :c.
}.
Expand All @@ -805,13 +805,13 @@
{
{
<http://eyereasoner.github.io/eye/reasoning/bi/ab_c.n3> log:semantics {
:a :b _:e_c_2.
:a :b _:e_c_14.
}.
<http://eyereasoner.github.io/eye/reasoning/bi/abc.n3> log:semantics {
:a :b :c.
}.
{
:a :b _:e_c_2.
:a :b _:e_c_14.
} log:notIncludes {
:a :b :c.
}.
Expand Down
4 changes: 2 additions & 2 deletions reasoning/blogic/test
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash
for f in *.n3
do
echo + eye --quiet --skolem-genid 8b98b360-9a70-4845-b52c-c675af60ad01 --nope $f --output $f.out
eye --quiet --skolem-genid 8b98b360-9a70-4845-b52c-c675af60ad01 --nope $f --output $f.out
echo + eye --quiet --skolem-genid 8b98b360-9a70-4845-b52c-c675af60ad01 --nope --blogic $f --output $f.out
eye --quiet --skolem-genid 8b98b360-9a70-4845-b52c-c675af60ad01 --nope --blogic $f --output $f.out
done
2 changes: 1 addition & 1 deletion reasoning/blogic/version.n3.out
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
@prefix log: <http://www.w3.org/2000/10/swap/log#>.

() log:version "EYE v5.1.1 (2023-10-18)".
() log:version "EYE v5.2.0 (2023-10-19)".
4 changes: 2 additions & 2 deletions reasoning/iq/iqA.n3
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
@prefix : <http://example.org/test#>.

_:e_x_1 :says {
_:e_x_1 :knows :Albert.
_:e_x_3 :knows :Albert.
}.
:s :p :o.
:s :pp {
Expand All @@ -10,7 +10,7 @@ _:e_x_1 :says {
{
?U_0 :knows :Albert.
} => {
?U_0 :knows :Kurt.
<http://eyereasoner.github.io/var#x_0> :knows :Kurt.
}.
{
:e :p :a.
Expand Down

0 comments on commit f7d9ee6

Please sign in to comment.