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