uswipl - dumbed-Down SWI-Prolog REPL ==================================== uswipl is a dumbed-down, IPC-friendly Prolog REPL built on top of SWI-Prolog. Requirements ------------ To build uswipl, you need SWI-Prolog installed. Installation ------------ Enter the following command to build uswipl: make uswipl Running uswipl -------------- uswipl takes the same arguments as `swipl(1)`, it's REPL only allows two types of interactions: 1. Assertions, which are done by entering an exclamation mark followed by a term, e.g.: !a :- b 2. Queries on unary predicates, which are done by entering a question mark followed by a predicate name. uswipl will then proceed to print each result for that predicate, one per line. e.g.: ?mypred uswipl will terminate on error, misinput, upon receiving a signal, or when reading EOF from stdin. Ok, but why? ------------ Because (SWI/GNU) Prolog is awesome but a pain to call from other languages. The C API is what it is, and the REPL doesn't seem to have been built with IPC in mind. You can start uswipl from any other programming language, provide an init `-f` or a state `-x` file containing your main Prolog logic, and, through a few queries and assertions, be done with gluing your software together.