ICS 361 -- Artificial Intelligence Programming
Expert Systems and Natural Language Processing in Prolog
This assignment is worth 150 points.
Knowledge-based and expert systems are frequently used to classify
things. Much of the power of these systems lies in the separation of
the inferencing mechanism and the domain knowledge. The inferencing
engine without a knowledge base is called an expert system shell.
These systems may be based on rules, frames or other structures, with
rules being the most common.
- An example of bird classification using rules is based on
the book "birds of north america". The code is
- An example of animal classification rules in Lisp can be found
from Patrick Winston's Artificial Intelligence book.
Expert systems work in a manner similar to the way Prolog's
interpreter reasons with a database of facts and rules. This makes
Prolog a good choice to implement this type of program.
- (75 p) An Expert System for classifying Hawaiian animals,
birds, fish or plants.
- Download and look at the code in the
file animalES.pro. For a look at
the source, see
the prolog tutorial, (C) J.R. Fisher
- This program classifies several large animals after asking the
user several yes/no questions.
- Your goal is to take the Expert System Shell (inference engine)
part of the file and save it to 7.pro. Then create a
new knowledge base containing Hawaiian animals, birds, fish or plants
as specified in the rules below.
- All species must be native to Hawaii.
- Your system must contain at least 10 species
If your last name starts with
- A-F, create a knowledge base of Hawaiian animals (mammals, turtles, reptiles, amphibians, ...),
- G-L, create a knowledge base of Hawaiian birds,
- M-R, create a knowledge base of Hawaiian fish,
- S-Z, create a knowledge base of Hawaiian plants.
- Use the WWW or books, etc. to find the knowledge to build your
knowledge base, and credit the source in comments in your source file.
- Testing: Demonstrate that your system works correctly with at least 2 instances of each species in
your knowledge base. Other/unlisted species shoulde classify as 'unknown'.
Create transcript(s) of your program working correctly.
- (50 p) Knowledge-based rule development in English - toward automating knowlege acquisition.
- Download and examine APES
sourceforge home for APES.
- Use APES to create a rule base with the same 10 species used in the first part of the assignment plus add five additional species.
Test your rules with the new knowledge base. Turn in transcript(s) showing at least 2 exmples of each species
plus at least two unknown cases.
- (25 p) Report. Compare your experience writing rules in part 1
with your experience generating rules in part 2 in a separate text
file. Which was easier? why? Your answer should be 1-2 pages
NOTE - use single quotes (') rather than double quotes (") for
strings in Prolog.
- Extra Credit (25 p) Create a one-page quick reference for
Prolog, similar to the emacs and unix guides.
(c) N. E. Reed, 2004-2016