Have you ever tried to port a complex Prolog program from one Prolog system to another? The ISO Prolog standard makes this easy, right?
As anyone knows who has ever attempted such a port, the answer is usually "no". The core ISO Prolog standard, while a significant achievement, is limited in its scope. It does not address libraries interfaces, constraint systems, or number of other features that real applications need. The lack of a broad-based standard is not the only impediment to portability. It actually may be impossible to move between Prolog systems if your application requires features such as tabling, native code generation, dynamic indexing, compiler analysis or an interactive development environment. To some extent, this diversity is a result of the health of logic programming, as there are numerous fine Prolog systems, each of which has a rapidly evolving code base and specializes in diverse and important research directions. However the limited portablity of Prolog code, along with the lack of a single Prolog system to which all researchers contribute, can also be a barrier for potential users of logic programming.
The Prolog-Commons Working Group has formed in order to start to address some of these issues. In particular, it is currently working on a common, public-domoin set of libraries. This manual documents the common libraries developed so far.
The first meeting of the group, organized by Bart Demoen, occurred in Leuven, Belgium on February 12-14, and was attended by Manuel Hermenegildo and José Morales of Ciao Prolog, Jan Wielemaker of SWI Prolog, Vítor Santos Costas of YAP Prolog, Daniel Diaz and Salvador Abreu of GNU Prolog , and Terrance Swift of XSB Prolog. Each of the Prolog mentioned has unique features that the others do not, and as a result all have their own dedicated user communities.
The first day of the meeting was somewhat informal. An important psychological milestone was passed when all implementors managed to install one another's Prologs on their laptops. A common repository for working code was also created, and discussion began on what exactly to do with the repository. The group quickly agreed on general standards for using modules in libraries, for adding annotations about types, and for unit testing. At the same time, consensus for documenting code in a "literate programming" style proved more difficult, although the group achieved a provisional agreement on this as well. The second and third days built on the progress of the first, when the attendees began to actually add code and APIs to the repository, which by the end of the meeting contained nearly 4000 lines of code.
Creation of a common set of sophisticated libraries and packages for Prolog is a giant task, of which the Leuven meeting was (hopefully) the first step. However, in addition to the concrete progress made on the repository, the attendees agreed that there was a great deal of intangible benefit in understanding both one another's systems and how to write more portable library code.
The next meeting of the working group is planned to take place near the time of ICLP 2009 in Pasadena California.