![](https://csdnimg.cn/release/download_crawler_static/10201507/bg10.jpg)
■ PrefaCe
xx
I use a variety of languages and applications in the book’s various demonstrations
and projects. The languages used are mainly Python, Prolog, and the Wolfram Language.
Each of these languages brings some unique features that allow the book demonstrations
to be quickly and easily implemented.
The main application that I use is Mathematica, which is a full-featured symbolic
processing program that also happens to be part of the Jessie distribution. Mathematica
is also a commercial program that ordinarily costs hundreds of dollars, but is provided
gratis due to the very generous gift of the Wolfram Corporation and Dr. Stephen Wolfram
(CEO) in particular.
I tried to layout the book in a logical manner by first introducing AI in Chapter 1. It is
difficult to explain AI to people who have never heard of it, although it is often surprising
to inform that them that AI often affects them in their daily lives. I have provided a
considerable amount of detail in the first chapter by trying to define AI and how it is
commonly applied in everyday life situations. It will soon become apparent to you how
invasive AI has become in modern society, whether you like it or not. Please note that I
used the term invasive in a non-derogatory way, simply to point out that AI is commonly
applied in many areas, some of which will surprise you. In addition, I also discuss the
topic of business intelligence (BI), as it is very closely allied to AI and is often the vehicle
through which AI affects most people. Some AI practitioners often refer to BI as simply
AI applied in a business setting. You will learn that it is much more than that, however.
I adopt it because it is a useful simplification.
I next explore some basic AI concepts in Chapter 2. There is initially some discussion
regarding basic logical constructs, as they are important to understand inference, which
is an AI core foundation. Expert knowledge systems are next discussed, which constitute
a major portion of the more general knowledge management systems (KMS)—an
important part of BI. The discussion then turns to machine learning, which is a huge
research area in modern AI. Finally, I conclude the chapter with an introduction to fuzzy
logic (FL), which is thoroughly demonstrated in a later book project.
Chapter 3 shows you how to implement a practical expert system using the Prolog
language. I explore some key Prolog features and explain how this somewhat specialized
language is so useful in implementing AI concepts, without requiring extensive
programing support as would be necessary if general-purpose languages such as C/C++
or Java were used for the same purposes. A simple console question-and-answer program
is used in the practical demonstration.
Chapter 4 focuses on using AI with games. Admittedly, the games are quite simple;
however, the chapter’s goal is to simply demonstrate how AI is incorporated into gaming
logic. These gaming AI concepts may then be easily expanded to handle much more
complex games. I used Python to implement the games, which are controlled through a
traditional text-console interface. Do not expect to see World of Warcraft (WoW)–quality
graphics in this chapter, but rest assured that WoW does use AI in its games.
In Chapter 5, I return to using Prolog to implement some fuzzy logic controls
for a practical project demonstration. There is also a simplified expert rules system
incorporated into the project. A Raspberry Pi system using both temperature and
humidity sensors will control a virtual heating and cooling system.
Chapter 6 introduces the concept of shallow machine learning. A Python program
is created, in which the computer “learns” your favorite color and make “decisions”
regarding color selection. Finally, I close the chapter with a discussion of adaptive
learning, which plays a large role in BI.