Arbitrary Lisp expressions may be called from rules. See 3.1.2 Forward Chaining Syntax.
KnowledgeWorks and Prolog User Guide (Windows version) - 01 Dec 2021 19:36:02