Introduction

During the development of the tool HARDY within the AIAI, a need arose for a data file format for C++ that was easy for both humans and programs to read, was robust in the face of fast-moving software development, and that provided some compatibility with AI languages such as Prolog and LISP.

The result was the PROLOGIO library, which is able to read and write a Prolog-like attribute-value syntax, and is additionally capable of writing LISP syntax for no extra programming effort. The advantages of such a library are as follows:

  1. The data files are readable by humans
  2. I/O routines are easier to write and debug compared with using binary files
  3. The files are robust: unrecognised data will just be ignored by the application
  4. Inbuilt hashing gives a random access capability, useful for when linking up C++ objects as data is read in
  5. Prolog and LISP programs can load the files using a single command

The library was extended to use the ability to read and write Prolog-like structures for remote procedure call (RPC) communication. The next two sections outline the two main ways the library can be used.

PROLOGIO for data file manipulation

PROLOGIO for RPC

Availability and location of PROLOGIO