> I tried a version that was supposed to be specifically for SWI, but it didn't work
Current SWI doesn't work with SWI's own aleph module (derived from [2]) anymore because Aleph uses false :- ... for encoding negative examples when false/0 is a static builtin in ISO/IEC 13211-1 (2012) as mentioning briefly in [1]. It's an unfortunate choice to break existing code by introducing pointless trivial builtins with such generic names and I officially "complained" about this. It might also break other Prolog software such as Stickel et. al.'s PTTP. The original ISO spec, for similar reasons, didn't define consult/1 or assert/1. Quantum Prolog deliberarely didn't follow ISO in this respect and doesn't define false as builtin. For SWI, you can run an old pre-ISO 2012 version (cf [1]) as a workaround.
I should really put the ISO port of Aleph on a public repo one of these days. I was always intending to do that after the site/article went online.
[1]: https://quantumprolog.sgml.net/bioinformatics-demo/part1.htm...
Thanks, yes, the SWI version I tried was Fabrizio Riguzzi's one. It's possible the use of false/0 was indeed the problem because IIRC I just kept getting silent failures.
It's funny there's both fail/0 and false/0 in ISO (though not sure which version) but only true/0 and no succeed/0. My guess is that an "I-mean-false" predicate is useful (e.g. for failure-driven loops) but "fail" strikes some folks as too procedural so we also got "false". But I'm only guessing.
I'd like to blame Aleph for using "false:-" for negative examples, rather than ISO. I suspect it's a hack to make it easier to cause negative examples to fail, somewhere. Normally ":- a" should be immediately recognised as a goal with a negative literal, but since that's the syntax used in directives it's probably not immediately obvious to most that "a" is negated. It wasn't to me for the first 10 years or so.