[PowerLoom Forum] forward-chaining issue

Xingzhi Pan vengeance.storm at gmail.com
Sun Nov 27 23:55:38 PST 2005


Hello, friends.

I've been trying forward-chaining in PowerLoom. It seemed that,
sometimes PowerLoom will add inferred facts into KB, and sometimes
not. Try to compare these:

(defconcept company)
(defrelation number-of-employees ((?c company)(?n INTEGER)) )
(defrelation number-of-managers ((?c company)(?n INTEGER)) )
(defconcept small-company ((?c company)))
(assert (forall ?c (=> (small-company ?c) (and(number-of-employees ?c
50)(number-of-managers ?c 10))) ))
(assert (small-company com1))
(all-facts-of com1)

and

(defconcept company)
(defrelation number-of-employees ((?c company)(?n INTEGER)) )
(defrelation number-of-managers ((?c company)(?n INTEGER)) )
(defconcept small-company ((?c company)))
(assert (forall ?c (=> (and(number-of-employees ?c
50)(number-of-managers ?c 10))(small-company ?c)) ))
(assert (company com1))
(assert (and (number-of-managers com1 10)(number-of-employees com1 50)) )
(all-facts-of com1)

I found that PowerLoom will do the inference only when the antecedent
is an 'atom' proposition. When it's something like (and P Q), nothing
seems happened. Have I done something wrong? Or it's designed so? Any
help would be appreciated.
--
Pan Xingzhi



More information about the powerloom-forum mailing list