Yuyu Xu
unread,Jul 5, 2012, 8:00:25 PM7/5/12Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to py...@googlegroups.com
Hey,
I've been reading pyke for sometime and am wondering is there's any way to log or print out the forward chaining rules firing process.
For example,
Inside example.krb, there's a rule
test_rule
foreach
test.word($w1)
test.word($w2)
assert
test.connectTwo($w1, $w2)
I want to have the print out like:
test.word("hello")
test.word("world")
firing test_rule, asserting:
test.connectTow("hello", "world")
And you can turn on/off the print out or log by engine.get_rb('example').enableLog()
Appreciate it if someone can point me to the right place in the code to make these changes.
Or other ways to debug forward chaining rules would be also good.
Thanks