Re: play(player, game)
Hans Chalupsky <[email protected]>
| Newsgroups | gmane.comp.ai.powerloom |
|---|---|
| Message-ID | <[email protected]> |
>>>>> Octav Popescu <[email protected]> writes: > --On Wednesday, May 25, 2005 12:47 -0700 Hans Chalupsky <[email protected]> wrote: >>>>>>> Octav Popescu <[email protected]> writes: >> >>> Another question: irrespective of the CLOSED declaration, does PowerLoom >>> do 3-value (or 5-value with the defaults) logic computation? Like saying >>> (AND UNKNOWN FALSE) = FALSE, (AND UNKNOWN TRUE) = UNKNOWN, (OR UNKNOWN >>> TRUE) = TRUE, (OR UNKNOWN FALSE) = UNKNOWN. >> >> Yes, for example: >> >> STELLA(3): (defrelation happy (?x)) >> | r|HAPPY >> STELLA(4): (assert (not (happy joe))) >> | P|(NOT (HAPPY JOE)) >> STELLA(5): (ask (happy fred)) >> UNKNOWN >> STELLA(6): (ask (and (happy joe) (happy fred))) >> FALSE >> STELLA(7): (ask (or (happy joe) (happy fred))) >> UNKNOWN >> STELLA(8): (ask (or (not (happy joe)) (happy fred))) >> TRUE >> STELLA(10): (ask (and (not (happy joe)) (happy fred))) >> UNKNOWN >> STELLA(11): >> >> Hans > Well, that's great, but then I get: > ? (ask (and (happy fred) (happy joe))) > UNKNOWN Again, this is because of "asymmetric effort" for deriving what you asked for vs. its negation. When the query engine determined that `(happy fred)' is unknown it stopped there, because that made the conjunction fail. It does not try to disprove any of the remaining conjuncts to see whether it can prove the conjunction to be false vs. just unknown. Conceivably, we could be a bit more aggressive there and at least look for shallow disproofs of other conjuncts similar to what we do for atomic propositions. If you explicitly ask for the negation, you get what you expect: STELLA(38): (ask (not (and (happy fred) (happy joe)))) TRUE We've considered to add a 3-valued-ask option (similar to Loom) that would ask for the negation of the top-level goal automatically if the positive was found to be unknown, for users who don't mind the extra inference effort for the sake of more complete results. > ? (ask (or (happy fred) (happy joe))) > FALSE Thanks for pointing that out, this was a bug in our truth-value propagation logic, it will be fixed with the next version. Hans