CLIPS

from Wikipedia, the free encyclopedia

CLIPS (of English. C L anguage I ntegrated P roduction S ystem, or "C-Language Integrated Production System") is a software for the creation of expert systems . CLIPS has become known as a data-driven (i.e. forward-chaining) production system with which expert systems (XPS) can be created. It contains a development environment written in C with a Lisp- like appearance and the multi-paradigm programming language COOL , which supports rule-based , object-oriented , functional and procedural programming . It thus combines the paradigms that are often only implemented individually by languages, such as Prolog (rule-based), Smalltalk (OO), Lisp (functional) and C (procedural).

Historical

In the 1970s and 1980s, the heyday of AI research , the US space agency NASA also worked on expert systems. In the 1970s, Lisp (“List Processing”), often on expensive special hardware , was predominantly used as the programming language for AI research and rule-based systems . From 1984 onwards, NASA used the ART * Inference product (or ART for short, Automated Reasoning Tool ) on such Lisp machines , a special software from Inference Corporation that was written in Lisp and whose rule definition language went back to OPS5 .

Dissatisfied with the development, the lack of portability of the software and the high costs, NASA decided at short notice to develop a suitable language itself that could run on inexpensive Intel hardware. The project name for this language was initially NAIL (NASA Artificial Intelligence Language), and from 1985 onwards it was written in ISO-C instead of Lisp for the purpose of greater platform independence . In order to be able to continue the inventory of existing ART software, it should be lexically, semantically and functionally a 1: 1 copy of the commercial product ART previously used by NASA (without use and knowledge of its sources). The user environment was also modeled on the one known from Lisp . However, the language range of CLIPS compared to the original ART * Inference had to be reduced due to the weaker Intel platform (the absolute limit for addressable memory was only 640 kB at the time ). The first prototype was created in 1985 and version 1.0 was achieved at the turn of the year. In the summer of 1986, CLIPS was made publicly available as version 3.0 by NASA ( public domain , later also the sources).

Further development

New versions and sub-versions with extended functionalities followed in large succession by 1988, and CLIPS gradually became more widespread in companies and universities. CLIPS was then completely rewritten and modularized between version 4.1 (1986) and 4.2 (1988). With this version, a detailed manual on the CLIPS architecture was published for the first time, and functionality for validation and verification of the rules was added. New functionality came in 1989 with version 4.3. Until then, CLIPS was a purely “logical” language with deductions based on the Rete algorithm . With CLIPS 5.0, however, further program paradigms were introduced in 1991: the procedural imperative and that of object orientation. This was associated with the introduction of the OOP language COOL ( Clips Object-Oriented Language , i.e. object-oriented CLIPS language). With CLIPS 5.1 in 1991 there were extensions for the X Window System , MS-DOS and Macintosh interfaces. From 1998, CLIPS 6.1 also supported C ++ compilers . CLIPS 6.2 finally brought a further expansion of the supported interfaces for the operating systems MS Windows 95, 98, Windows NT and macOS .

In 2008 CLIPS reached version 6.30. It is characterized primarily by improved integration in C ++, .NET and Java.

For version 6.4, according to the FAQ on the CLIPS website, support for Unicode is provided, which is also relevant for language interoperability, since all current operating systems on which CLIPS can run, as well as some of the programming languages ​​and runtime environments provided for software integration (Java and. NET) have been supporting Unicode for a number of years.

Technical

With CLIPS, expert systems can be created in the classic sense. Before running, the source code must be compiled with a common ANSI-C compiler for the respective platform. Such compilers are available for all common platforms.

CLIPS can also be embedded in other programs using runtime programs that are written in common languages. These were initially C, C ++, Ada , later other languages ​​were added, such as Delphi and Java. This possible embedding in other languages ​​is a deliberately sought-after feature of CLIPS / COOL compared to other logical or AI languages ​​such as Prolog , Planner or Lisp (which dominated the AI ​​scene in the 1970s and 1980s), because it allows interoperationality with existing software environments, The continued use of existing codes and the transfer of knowledge are promoted and the effort involved in familiarizing oneself with CLIPS is reduced.

How it works on a case study

For logical deductions, CLIPS works as usual with facts (logical premises ) and rules ( logical final figures ). The final figure of the modus ponens (or more precisely differentiated here: the modus darii ), which was already familiar in ancient logic , is often reproduced by the following example:

  • All people are mortal.
  • Socrates is a human.
  • It follows: Socrates is mortal.

The aim is to show how CLIPS produces the conclusion (statement, line 3) from the facts (lines 1 and 2). First, the knowledge base is expanded to include the two relevant inputs:

  • People are mortal.
  • Socrates is a human.

Now we add another fact:

  • Dogs are mortal.

In CLIPS language these are as follows:

 (deffacts Wahrheiten
     (ist Mensch sterblich)
     (ist Sokrates Mensch)
     (ist Hund sterblich)
  )

Note the Lisp-like notation of CLIPS with round brackets and the order (operator argument argument).

The applicable final rule (the modus ponens) is as follows:

  • if: a implies b and b implies c , it also follows: a implies c ,

which is in CLIPS language:

 (defrule translation
     (ist ?a ?b)
     (ist ?b ?c)
      
     (assert (ist ?a ?c))
  )

Before we run this rule for the first time, our knowledge base looks like this for a query:

   1- (ist Mensch sterblich)
   2- (ist Sokrates Mensch)
   3- (ist Hund sterblich)

Now we apply the rule formulated above to the set facts. CLIPS then outputs the following:

   1- (ist Mensch sterblich)
   2- (ist Sokrates Mensch)
   3- (ist Hund sterblich)
   4- (ist Sokrates sterblich)

The system stops when all rules have been applied to all facts. The conclusion is simply added to the knowledge base as a new fact. We therefore now find a new statement in the knowledge base, in CLIPS language (is Socrates mortal) or translated back into the syntax of everyday language: Socrates is mortal . And as we also note, the system of (is dog mortal) did not conclude (is Socrates dog) , so it did not fall for the famous sophism , which was a well-known fallacy even in ancient times.

Follow-up projects

From CLIPS, the companies Inference and its successors derived a series of products that were repeatedly renamed or initiated new follow-up projects. So there were the software products (in this chronological order) ART-IM (later called ARTEnterprise), Eclipse (not to be confused with the development environment of the same name ), its successor HaleyRules and CLIPS / R2 (from Production Systems Technology).

A functionally simplified version of CLIPS has been available since 1995 under the name JESS (Java Expert System Shell) for the Unix and MS Windows operating system platforms, which from version 7 includes the rule definition language JessML. JESS was completely rewritten in Java at Sandia National Laboratories in Livermore, USA, and developed for use with or as an extension of Java. Compared to CLIPS, its functionality is somewhat reduced, so it offers less selection of rule application strategies, dispenses with modules and does not offer most of the functions of COOL, since Java itself offers these missing functions. However, JESS can also be used entirely without Java. In contrast to CLIPS, JESS is not open source . Commercial users also need a corresponding usage permit . Version 8.0 was released in October 2013 with initial support for the Android mobile operating system .

A variant of CLIPS expanded to include fuzzy logic is FuzzyCLIPS (Fuzzy Extension to the CLIPS Expert System Shell). The system uses two additional concepts: blur ( "fuzziness") and uncertainty . FuzzyCLIPS allows the free mixing of fuzzy and ordinary expressions for the rules and facts of an expert system. It was developed at the Institute for Information Technology of the Canadian Government Agency for Scientific and Industrial Research and also found its way into the integrated software development environment Eclipse . Due to the high effort required to adapt to new CLIPS versions, the project was no longer developed from 2010 onwards.

EHSIS (Erabaki Hartzea SIstemen Sortzailea) is a commercial, Spanish-language integrated development environment written in C for the generation of expert systems based on CLIPS and FuzzyCLIPS. It supports a multitude of communication protocols, database connectors and multimedia interfaces, but only runs under MS Windows. EHSIS has so far been used primarily in the medical sector and at universities in Latin America.

The Python module PyCLIPS 1.0 has been available since 2004 , an extension module for the Python programming language , which provides the complete CLIPS functionality in Python.

In 2001 David Young began to develop a system inspired by CLIPS and JESS under the name LISA (Lisp-based Intelligent Software Agents), which is written with the Common Lisp Object System of the ANSI Common Lisp. Young's goals are completely free availability and the greatest possible platform independence (portability) of the sources as well as interoperability with as many common Lisp variants as possible. The first productive release appeared as version 1.0 on August 31, 2001, version 3.0 appeared on September 8, 2007. It runs with LispWorks , ACL , CLISP , CMUCL , SBCL and OpenMCL .

Web links