Presentation is loading. Please wait.

Presentation is loading. Please wait.

Learning and Knowledge Acquisition

Similar presentations


Presentation on theme: "Learning and Knowledge Acquisition"— Presentation transcript:

1 Learning and Knowledge Acquisition

2 AGENTS THAT REASON LOGICALLY

3 Knowledge-based agents
Knowledge-based agents are able to accept new tasks in the form of explicitly described goals; they can achieve competence quickly by being told or learning new knowledge about the environment; and they can adapt to changes in the environment by updating the relevant knowledge. A knowledge-based agent needs to know many things: the current state of the world; how to infer unseen properties of the world from percepts; how the world evolves over time; what it wants to achieve; and what its own actions do in various circumstances

4 Knowledge-based agents
The central component of a knowledge-based agent is its knowledge base, or KB. Informally, a knowledge base is a set of representations of facts about the world. Each individual representation is called a sentence. The sentences are expressed in a language called a knowledge representation language. There must be a way to add new sentences to the knowledge base, and a way to query what is known. The standard names for these tasks are TELL and ASK, respectively

5

6 Knowledge Representation
The object of knowledge representation is to express knowledge in computer-tractable form, such that it can be used to help agents perform well. A knowledge representation language is defined by two aspects: 1. The syntax of a language describes the possible configurations that can constitute sentences. Usually, we describe syntax in terms of how sentences are represented on the printed page, but the real representation is inside the computer: each sentence is implemented by a physical configuration or physical property of some part of the agent. For now, think of this as being a physical pattern of electrons in the computer's memory.

7 Knowledge Representation
2. The semantics determines the facts in the world to which the sentences refer. Without semantics, a sentence is just an arrangement of electrons or a collection of marks on a page. With semantics, each sentence makes a claim about the world. And with semantics, we can say that when a particular configuration exists within an agent, the agent believes the corresponding sentence.

8 Knowledge Representation
For example, the syntax of the language of arithmetic expressions says that if x and y are expressions denoting numbers, then x > y is a sentence about numbers. The semantics of the language says that x > y is false when y is a bigger number than x, and true otherwise.

9 Inference Mechanism Provided the syntax and semantics are defined precisely, we can call the language a logic. From the syntax and semantics, we can derive an inference mechanism for an agent that uses the language. Inferencing deduces new knowledge from KB by using logic rules.

10 Logics To summarize, we can say that a logic consists of the following: 1. A formal system for describing states of affairs, consisting of (a) the syntax of the language, which describes how to make sentences, and (b) the semantics of the language, which states the systematic constraints on how sentences relate to states of affairs. 2. The proof theory—a set of rules for deducing the entailments of a set of sentences.

11 Logics We will concentrate on two kinds of logic: propositional or Boolean logic, and first-order logic (more precisely, first-order predicate calculus with equality). In propositional logic, symbols represent whole propositions (facts); for example, D might have the interpretation "the soldier is dead." which may or may not be a true proposition. Proposition symbols can be combined using Boolean connectives to generate sentences with more complex meanings.

12 Logics First-order logic commits to the representation of worlds in terms of objects and predicates on objects (i.e., properties of objects or relations between objects), as well as using connectives and quantifiers, which allow sentences to be written about everything in the universe at once. First-order logic seems to be able to capture a good deal of what we know about the world, and has been studied for about a hundred years. We will spend therefore a good deal of time looking at how to do representation and deduction using it.

13 How to represent the third status??
In both propositional and first-order logic, a sentence represents a fact and the agent either believes the sentence to be true, believes it to be false, or is unable to conclude either way. These logics therefore have three possible states of belief regarding any sentence. How to represent the third status??

14 Probabilistic Theory: Systems using probability theory, on the other hand, can have any degree of belief, ranging from 0 (total disbelief) to 1 (total belief). Fuzzy Logic: Systems based on fuzzy logic can have degrees of belief in a sentence, and also allow degrees of truth: a fact need not be true or false in the world, but can be true to a certain degree. For example, “Lahore is a large city" might be true only to degree 0.6

15 Logic as a KR language Propositional Logic First Order Higher Order
Modal Fuzzy Logic Multi-valued Probabilistic Temporal Non-monotonic

16 Ontology and epistemology
Ontology is the study of what there is, an inventory of what exists. An ontological commitment is a commitment to an existence claim. Epistemology is major branch of philosophy that concerns the forms, nature, and preconditions of knowledge.

17 No independent access to the world
The reasoning agent often gets its knowledge about the facts of the world as a sequence of logical sentences and must draw conclusions only from them without independent access to the world. Thus it is very important that the agent’s reasoning is sound!

18 The Wumpus World environment
The Wumpus computer game (search for it on web and play this game) The agent explores a cave consisting of rooms connected by passageways. Lurking somewhere in the cave is the Wumpus, a beast that eats any agent that enters its room. Some rooms contain bottomless pits that trap any agent that wanders into the room. Occasionally, there is a heap of gold in a room. The goal is to collect the gold and exit the world without being eaten

19 A typical Wumpus world The agent always starts in the field [1,1].
The task of the agent is to find the gold, return to the field [1,1] and climb out of the cave.

20 Agent in a Wumpus world: Percepts
The agent perceives a stench in the square containing the wumpus and in the adjacent squares (not diagonally) a breeze in the squares adjacent to a pit a glitter in the square where the gold is a bump, if it walks into a wall a woeful scream everywhere in the cave, if the wumpus is killed The percepts will be given as a five-symbol list: If there is a stench, and a breeze, but no glitter, no bump, and no scream, the percept is [Stench, Breeze, None, None, None] The agent can not perceive its own location.

21 Wumpus actions go forward turn right 90 degrees turn left 90 degrees
grab means pick up an object that is in the same square as the agent shoot means fire an arrow in a straight line in the direction the agent is looking. The arrow continues until it either hits and kills the wumpus or hits the wall. The agent has only one arrow. Only the first shot has any effect. climb is used to leave the cave. Only effective in start field. die, if the agent enters a square with a pit or a live wumpus. (No take-backs!)

22 Wumpus goal The agent’s goal is to find the gold and bring it back to the start as quickly as possible, without getting killed. 1000 points reward for climbing out of the cave with the gold 1 point deducted for every action taken 10000 points penalty for getting killed

23 The Wumpus agent’s first step

24 Later

25 World-wide web wumpuses
– Lisp version from Russell & Norvig – Web-based version you can play – downloadable Mac version

26 Summary Intelligent agents need knowledge about the world for making good decisions. The knowledge of an agent is stored in a knowledge base in the form of sentences in a knowledge representation language. A knowledge-based agent needs a knowledge base and an inference mechanism. It operates by storing sentences in its knowledge base, inferring new sentences with the inference mechanism, and using them to deduce which actions to take. A representation language is defined by its syntax and semantics, which specify the structure of sentences and how they relate to the facts of the world. The interpretation of a sentence is the fact to which it refers. If this fact is part of the actual world, then the sentence is true.


Download ppt "Learning and Knowledge Acquisition"

Similar presentations


Ads by Google