damianoazzolini / pasta

Tool to perform various types of inference in probabilistic answer set programs under the credal semantics and with statistical statements.
GNU General Public License v3.0
7 stars 4 forks source link

Multiple AD #17

Closed damianoazzolini closed 9 months ago

damianoazzolini commented 9 months ago

Multiple annotated disjunctions in the same file are not correctly handled, due to the conversion with auxiliary facts.

0.05 :: am1 ; 0.65 :: am2 ; 0.3 :: am3.

x1 :- am1.
x0 :- am2.
x0 ; x1 :- am3.

0.05 :: bm1 ; 0.65 :: bm2 ; 0.3 :: bm3.

y1 :- bm1.
y0 :- bm2.
y0 ; y1 :- bm3.

qr:- x1.
qr:- y1.

Expected P(qr) = [0.0975, 0.5775], computed [0.05,0.35].

friguzzi commented 9 months ago

I think you should use the conversion of an AD that is used in ProbLog and PITA: the AD

am1:0.3;am2:0.1; am3:0.6.

is converted to

0.3::am1i.

0.142857143::am2i.

am1:- am1i.

am2:- not am1i, am2i.

am3:- not am1i, not am2i.