I think Jonathan Sewall wrote:
[Charset iso-8859-1 unsupported, filtering to ASCII...]
> Just to be sure, since I need backtracking for my algorithm, too, I want 
> to confirm my understanding that there is no generalized undo function 
> for Jess.  That is, e.g., there's no built-in, general way to undo the 
> effects of an RHS firing.  That right?  As you might know by now, I use 
> bsave-bload for backtracking, but I appreciate other suggestions (like 
> this one).  Thanks again,
> 

As an aside, I have to point  out that complete rollback of a rule
firing isn't possible because the RHS of a rule might do many things
that aren't undoable, from printing a message to the user to exiting
the JVM.

But in any case, the next release of Jess 7 (tomorrow or Friday) has a
mechanism for "marking" working memory and "rolling back" to that
mark. All it can do, though, is retract new facts asserted since the
mark, not undo modify or retract operations. Still, this marking
capability is very useful if you have, for example, a few thousand
"catalog-item" facts that you'd like to load just once, and then start
just at that point for a series of per-customer transactions. It could
also definitely be used for backtracking if the deductive rules didn't
modify existing facts.

---------------------------------------------------------
Ernest Friedman-Hill  
Advanced Software Research          Phone: (925) 294-2154
Sandia National Labs                FAX:   (925) 294-2234
PO Box 969, MS 9012                 [EMAIL PROTECTED]
Livermore, CA 94550         http://herzberg.ca.sandia.gov

--------------------------------------------------------------------
To unsubscribe, send the words 'unsubscribe jess-users [EMAIL PROTECTED]'
in the BODY of a message to [EMAIL PROTECTED], NOT to the list
(use your own address!) List problems? Notify [EMAIL PROTECTED]
--------------------------------------------------------------------

Reply via email to