Knowledge and search, page 1 CSI 4106, Winter 2005 Knowledge and search Points Properties of knowledge  Completeness  Objectivity  Certainty  Formalizability.

Slides:



Advertisements
Similar presentations
1 Knowledge Representation Introduction KR and Logic.
Advertisements

Presentation on Artificial Intelligence
ARCHITECTURES FOR ARTIFICIAL INTELLIGENCE SYSTEMS
Problem Solving Well-formed predicate calculus expressions provide a means of describing objects and relations in a problem domain and inference rule.
C O N T E X T - F R E E LANGUAGES ( use a grammar to describe a language) 1.
Rules, page 1 CSI 4106, Winter 2005 Representing knowledge with rules Points Definitions Production systems Conflict resolution strategies Examples A financial.
Logic CPSC 386 Artificial Intelligence Ellen Walker Hiram College.
CSC 423 ARTIFICIAL INTELLIGENCE
Task Analysis EDU 553 – Principles of Instructional Design Dr. Steve Broskoske.
Search: Representation and General Search Procedure Jim Little UBC CS 322 – Search 1 September 10, 2014 Textbook § 3.0 –
Problem Solving and Search in AI Part I Search and Intelligence Search is one of the most powerful approaches to problem solving in AI Search is a universal.
Chapter Two: Finite Automata
Graphs and Trees This handout: Total degree of a graph Applications of Graphs.
Building Control Algorithms For State Space Search
WHAT IS ARTIFICIAL INTELLIGENCE?
State Spaces Introduction to Artificial Intelligence Dr. Robin Burke.
CPSC 322, Lecture 19Slide 1 Propositional Logic Intro, Syntax Computer Science cpsc322, Lecture 19 (Textbook Chpt ) February, 23, 2009.
Search: Representation and General Search Procedure CPSC 322 – Search 1 January 12, 2011 Textbook § 3.0 –
CPSC 322 Introduction to Artificial Intelligence November 10, 2004.
Knowledge Acquisitioning. Definition The transfer and transformation of potential problem solving expertise from some knowledge source to a program.
Introduction to Artificial Intelligence Problem Solving Ruth Bergman Fall 2002.
Programming Language Semantics Mooly SagivEran Yahav Schrirber 317Open space html://
Dr Eleni Mangina – COURSE: LOGIC PROGRAMMING (during a joint degree with Fudan University in Software Engineering) DEPT. OF COMPUTER SCIENCE UCD Problem.
Semantics with Applications Mooly Sagiv Schrirber html:// Textbooks:Winskel The.
1. 1 Text Book Artificial Intelligence: A Modern Approach, S. Russell and P. Norvig, 3/e, Prentice Hall, 2010 References  Artificial Intelligence, Patrick.
Lesson 6. Refinement of the Operator Model This page describes formally how we refine Figure 2.5 into a more detailed model so that we can connect it.
Graphs and Trees This handout: Terminology of Graphs Applications of Graphs.
Artificial Intelligence Problem solving by searching CSC 361 Prof. Mohamed Batouche Computer Science Department CCIS – King Saud University Riyadh, Saudi.
Problem Solving. What is a Problem? An ambiguous situation not clearly showing how to reach the goal. Given Initial Situation Desired Goal Situation What.
CS344: Introduction to Artificial Intelligence Pushpak Bhattacharyya CSE Dept., IIT Bombay Lecture 13– Search.
Artificial Intelligence Introduction (2). What is Artificial Intelligence ?  making computers that think?  the automation of activities we associate.
Notes for Chapter 12 Logic Programming The AI War Basic Concepts of Logic Programming Prolog Review questions.
1 State Space of a Problem Lecture 03 ITS033 – Programming & Algorithms Asst. Prof.
110/19/2015CS360 AI & Robotics AI Application Areas  Neural Networks and Genetic Algorithms  These model the structure of neurons in the brain  Humans.
Planning, page 1 CSI 4106, Winter 2005 Planning Points Elements of a planning problem Planning as resolution Conditional plans Actions as preconditions.
UNIVERSITY OF SOUTH CAROLINA Department of Computer Science and Engineering Programs with Common Sense Mingzhe Du and Hongying Du April, 2011 This paper.
Logic Programming Module 2AIT202 Website Lecturer: Dave Sharp Room: AG15
MATH CHALLENGE Challenge your mind!  Math is all around you in …  Nature  Art  Games  The following slides have links and puzzles for you.  Select.
Artificial Intelligence and Knowledge Based Systems Fall 2009 Frank Hadlock.
Introduction to Planning Dr. Shazzad Hosain Department of EECS North South Universtiy
Knowledge Representation
Sight Words.
11 Artificial Intelligence CS 165A Thursday, October 25, 2007  Knowledge and reasoning (Ch 7) Propositional logic 1.
Knowledge Representation Fall 2013 COMP3710 Artificial Intelligence Computing Science Thompson Rivers University.
CS621: Artificial Intelligence Pushpak Bhattacharyya CSE Dept., IIT Bombay Lecture 13– Search 17 th August, 2010.
Introduction to State Space Search
L24-205_ Aristotle on Causes. Four causes Opposites as logical, not physical principles: another way to approach systematicity. With things,
CSCI 383 Object-Oriented Programming & Design Lecture 7 Martin van Bommel.
Some Thoughts to Consider 5 Take a look at some of the sophisticated toys being offered in stores, in catalogs, or in Sunday newspaper ads. Which ones.
Artificial Intelligence Knowledge Representation.
AS Computer Studies Algorithms & Problem Solving 1 & 2.
Network Management Lecture 13. MACHINE LEARNING TECHNIQUES 2 Dr. Atiq Ahmed Université de Balouchistan.
Knowledge Representation
Knowledge Representation Techniques
The Decision-making Process
Problem solving by Searching
Some problems Cse-402 K3r20,k3r23.
Knowledge Representation
STATE SPACE REPRESENTATION
Structural relations Carnie 2013, chapter 4 Kofi K. Saah.
Introduction Artificial Intelligent.
Chapter Two: Finite Automata
ENGL221 Introduction to Linguistic Analysis
4. Computational Problem Solving
Some problems Cse-402 K3r20,k3r23.
STATE SPACE REPRESENTATION
Problem Solving by Searching Search Methods :
Knowledge Representation
Artificial Intelligence
Lecture One: Automata Theory Amjad Ali
Presentation transcript:

Knowledge and search, page 1 CSI 4106, Winter 2005 Knowledge and search Points Properties of knowledge  Completeness  Objectivity  Certainty  Formalizability The role of search A small case study

Knowledge and search, page 2 CSI 4106, Winter 2005 Properties of knowledge: completeness "Knowledge is always incomplete": true or false? What do we need to know when we play a game? make a holiday plan? recognize a picture?

Knowledge and search, page 3 CSI 4106, Winter completeness (2) Even in a very restricted real-life domain there may be unexpected situations. Find examples of such situations in buying groceries, fixing a car. Knowledge contained in an AI software system for some application is necessarily much less complete than what we know about this application: true or false?

Knowledge and search, page 4 CSI 4106, Winter 2005 Properties of knowledge: objectivity Knowledge may be objective or subjective: we have to make a distinction between facts and beliefs. Beliefs are associated with agents. Jack is planning a gift for his mother. He believes that she dislikes classical music. Will he buy a Mozart CD for her? Is there anything subjective in the game of chess? Is there anything objective in art appreciation?

Knowledge and search, page 5 CSI 4106, Winter 2005 Properties of knowledge: certainty Knowledge may be certain or uncertain. Diagnostic expert systems are a good example: faults and repair advice do not always logically follow from observations or symptoms. What (if anything) can we conclude with certainty from a sick person's short breath? a car engine noise? a position in a chess game? Probability plays an essential role here -- more to come, later.

Knowledge and search, page 6 CSI 4106, Winter 2005 Properties of knowledge: formalizability Knowledge may or may not be easily formalized -- written down in some symbolic language (recall the physical-symbol systems). People often operate in an approximate manner and allow themselves a margin of error. Perhaps the same should be possible for intelligent systems, except that systems only have explicit knowledge that has been put into them.

Knowledge and search, page 7 CSI 4106, Winter formalizability (2) People rely on experience; systems must have experience formalized as well. Which of the following can be formalized (represented!) with little effort: the rules of ice hockey? the relationship between moods and colours? the decision-making of a loan officer in a bank? a surgical procedure?

Knowledge and search, page 8 CSI 4106, Winter 2005 The role of search Intelligent behaviour requires knowledge. There is a hypothesis is that intelligent action can be reduced to search. While intelligence is certainly more than search, the hypothesis is attractive: search is well understood, easily mechanized, manageable, and so on. Formally represented knowledge can also be easily used in search.

Knowledge and search, page 9 CSI 4106, Winter 2005 The role of search (2) Search means systematic traversal of a space of possible solutions of a problem. A search space is usually a graph (often as simple as a tree). A node represents a partial solution. An edge represents a step in the construction of a solution.

Knowledge and search, page 10 CSI 4106, Winter 2005 The role of search (3) The purpose of search may be: to find a path in the graph from a start node to a goal node (that is, from an initial to a final situation), to find a goal node. Examples in textbooks are often puzzles and games -- not surprisingly, because these problems are the easiest to present as search. The challenge is to try it with other kinds of problems.

Knowledge and search, page 11 CSI 4106, Winter 2005 The role of search (4) Examples of such problems: Analyze an English sentence. Debug a Pascal procedure. Program a robot.

Knowledge and search, page 12 CSI 4106, Winter 2005 A small case study A farmer has a wolf, a goat and a cabbage. He wants to cross the river from the south bank to the north bank. There is a boat that can only carry the farmer and at most one of his possessions. The wolf left alone with the goat will eat it. The goat left alone with the cabbage will eat it. How can the farmer cross the river and lose none of the three?

Knowledge and search, page 13 CSI 4106, Winter case study (2) This is a classical example of a planning problem. We must find a sequence of actions that will take the farmer across the river. At each moment, the whole situation is in one of its possible states. A state describes the position of the farmer, his three possessions and the boat with respect to the north and south bank of the river. An action is one crossing of the river, north or south. As a result of such an action, the farmer, the boat and possibly one of the three objects transfer from one bank to the other. There are constraints on actions, as no action should leave to an unsafe state.

Knowledge and search, page 14 CSI 4106, Winter case study (3) In the initial situation, everything is on the south bank. In the desired final situation the farmer and his three possessions are on the north bank. We will represent a situation as a four-tuple of locations: of the farmer, the wolf, the goat and the cabbage. We do not need to represent the position of the boat, because in is always located on the same bank as the farmer. For example, in the situation situation(s, n, s, n) the farmer and the goat are on the south bank, and the other two on the north bank. Is this situation safe?

Knowledge and search, page 15 CSI 4106, Winter case study (4) We represent the initial situation as situation(s,s,s,s) and the final situation as situation(n,n,n,n) Four actions are possible in each situation. The farmer transfers himself to the opposite bank; he also transfers nothing, or the wolf, or the goat, or the cabbage. We will represent these actions as Prolog terms: moved( nothing ) moved( wolf ) moved( goat ) moved( cabbage )

Knowledge and search, page 16 CSI 4106, Winter case study (5) A situation is safe if it is safe both for the goat and the cabbage. The goat is safe if the farmer is on the same bank of the river, or when the wolf is not. The cabbage is safe if the farmer is on the same bank, or when the goat is not. We can express in Prolog everything we know about this problem. First, the main predicate: successfulMoves( Mvs ) :- movesLeadingTo( Mvs, situation( n, n, n, n ) ). Mvs is a list of representations of actions.

Knowledge and search, page 17 CSI 4106, Winter case study (6) No actions are necessary to stay in the initial situation: movesLeadingTo( [], situation( s, s, s, s ) ). Otherwise, let Mvs1 be a list of legal actions leading to situation S1. Perform one more action and add it to Mvs1 : movesLeadingTo( Mvs, S ) :- movesLeadingTo( Mvs1, S1 ), transforms( Mv, S1, S ), append( Mvs1, [Mv], Mvs ), safe( S ).

Knowledge and search, page 18 CSI 4106, Winter case study (7) North is opposite south: opposite( n, s ). opposite( s, n ). The four possible actions: transforms( moved( nothing ), situation( X, Z1, Z2, Z3 ), situation( Y, Z1, Z2, Z3 ) ) :- opposite( X, Y ). transforms( moved( wolf ), situation( X, X, Z2, Z3 ), situation( Y, Y, Z2, Z3 ) ) :- opposite( X, Y ). continued

Knowledge and search, page 19 CSI 4106, Winter case study (8) transforms( moved( goat ), situation( X, Z1, X, Z3 ), situation( Y, Z1, Y, Z3 ) ) :- opposite( X, Y ). transforms( moved( cabbage ), situation( X, Z1, Z2, X ), situation( Y, Z1, Z2, Y ) ) :- opposite( X, Y ). The safety rules are as discussed earlier: safe( S ) :- safe_for_goat( S ), safe_for_cabbage( S ).

Knowledge and search, page 20 CSI 4106, Winter case study (9) The farmer and the goat together: safe_for_goat( situation( X, Z1, X, Z3 ) ). The wolf and the goat separated: safe_for_goat( situation( X, Z1, Y, Z3 ) ) :- opposite( Z1, Y ).

Knowledge and search, page 21 CSI 4106, Winter case study (10) The same for the goat and the cabbage: safe_for_cabbage( situation( X, Z1, Z2, X ) ). safe_for_cabbage( situation( X, Z1, Z2, Y ) ) :- opposite( Z2, Y ). And finally here is a solution: ?- successfulMoves( Mvs ). Mvs = [moved(goat), moved(nothing), moved(wolf), moved(goat), moved(cabbage), moved(nothing), moved(goat)] Yes

Knowledge and search, page 22 CSI 4106, Winter case study (11) This program requires cuts in the definitions of safe_for_cabbage and safe_for_goat if it is to lose its annoying nondeterminism. It will then quickly deliver the other optimal solution: Mvs = [moved(goat), moved(nothing), moved(cabbage), moved(goat), moved(wolf), moved(nothing), moved(goat)] After that, the program begins to deliver non- optimal solutions, longer and longer, with the unproductive moved(X), moved(X) inserted just about everywhere.