KnowledgeWorks rules are defined as follows:
<rule> ::=
(defrule <rule-name> <direction> [<doc-string>] <body>)
<direction> ::= {:forward | :backward}
Every rule must have a unique name which must also be distinct from any KnowledgeWorks object class name and from any context (rule-group) name. The expressions which form the body of a rule have the same syntax and meaning regardless of whether they occur on the left or right hand side of a forward or backward chaining rule. If
doc-string
is given, then it should be a string. The value can be retrieved by calling the function
documentation
with doc-type
rule
.
KnowledgeWorks and Prolog User Guide (Unix version) - 6 Dec 2011