What I'm saying that NO "Something" is not qualified and it should not
matter if you now you retracted fact-1 that was blocking the rule and
later you retracted fact-3 that happens to block rule at that moment -
I'd expect rule to fire once.

I'd expect rule-1 in Edson example to fire just once. Forget logical
assertion for a second - imagine that you assert and retract String()
facts. So everytime fact is retracted rule fires in current
implementation. Rule states that it should fire when NO String() facts
exists and not when String() fact happen to be retracted. At least
that is how I see it.

And to Michael's point that "there is  no "fire only once" in the
contract of the rule. " What if the same rule has a "positive"
condition in it (in addition to the "NO"). Would you expect it to fire
on each blocking fact retraction as well? I'd say probably not.

Anyway, I think I need to do more thinking on what and how but feel
free to share your thought on this subject.

On 4/25/06, Michael Neale <[EMAIL PROTECTED]> wrote:
> If I understand in my pre-caffeinated state, then I think what you are
> saying is:
>
> We start off with NO "Something" in WM.
> The rule "R" fires.
>
> We add "Something" to WM
> nothing happens
>
> We remove "Something" from WM
> The rule "R" fires again. **
>
> Now in ReteOO ** will happen. In LEAPS it does not?
>
> Well, the answer is allways: WWJD: What Would Jess Do ?
> I am thinking the ReteOO way is what I would intuitively expect, as there is
> no "fire only once" in the contract of the rule.
>
>
>
>
>
>
>
>
> On 4/26/06, Alexander Bagerman <[EMAIL PROTECTED]> wrote:
> > All,
> > While going through fixing logical assertion tests for leaps I
> > realized that I might not be able to support behavior for rules with
> > no positive conditions in the way RETEOO does. Please do not skip the
> > rest of the email saying "that's ok, leaps is experimental" :-)
> >
> > Here is an issue - loop / no loop tests rely on multiple activation of
> > the rules that have the following structure:
> > rule "r"
> >     when
> >         not Something
> >     then
> > ...
> > end
> >
> > You would expect this rule to fire only once but in reality (RETEOO
> > reality) it fires first time its "when" section is valid (even if
> > there was not ever blocking facts) and than every time when rule goes
> > from "have blocking facts can not fire" to "ok, last blocking fact is
> > removed, I can fire now". Does it break a paradime that states that
> > rule can fire only once on same conditions? Let's say I have one more
> > condition in "when" section like that:
> > rule "r"
> >     when
> >         someFact is matching condition
> >         and not Something
> >     then
> > ...
> > end
> >
> > I would expect this rule to fire only once, even if it goes from "have
> > blocking facts can not fire" to "ok, last blocking fact is removed, I
> > can fire now" multiple times assuming that someFact was not retracted.
> >
> > What are your thoughts on it?
> >
> > -Alex
> >
>
>

Reply via email to