Search in Artificial Intelligence zFind the next move in chess, checkers. zScheduling: finding a good class schedule. zTheorem proving: given a set of.

Slides:



Advertisements
Similar presentations
Artificial Intelligence
Advertisements

Informed search algorithms
Review: Search problem formulation
An Introduction to Artificial Intelligence
Search I: Chapter 3 Aim: achieving generality Q: how to formulate a problem as a search problem?
Classic AI Search Problems
Heuristics CPSC 386 Artificial Intelligence Ellen Walker Hiram College.
Informed Search Methods How can we improve searching strategy by using intelligence? Map example: Heuristic: Expand those nodes closest in “as the crow.
Games & Adversarial Search Chapter 5. Games vs. search problems "Unpredictable" opponent  specifying a move for every possible opponent’s reply. Time.
Optimality of A*(standard proof) Suppose suboptimal goal G 2 in the queue. Let n be an unexpanded node on a shortest path to optimal goal G. f(G 2 ) =
Games & Adversarial Search
CS 484 – Artificial Intelligence1 Announcements Department Picnic: today, after class Lab 0 due today Homework 2 due Tuesday, 9/18 Lab 1 due Thursday,
1 Problem Solving Using Search Brute-force search Heuristic search Competitive search.
Search in AI.
State Space Search Algorithms CSE 472 Introduction to Artificial Intelligence Autumn 2003.
Informed (Heuristic) Search Evaluation Function returns a value estimating the desirability of expanding a frontier node Two Basic Approaches –Expand node.
Informed Search Methods Copyright, 1996 © Dale Carnegie & Associates, Inc. Chapter 4 Spring 2008.
Informed Search Methods Copyright, 1996 © Dale Carnegie & Associates, Inc. Chapter 4 Spring 2005.
1 Solving Problems by Searching. 2 Terminology State State Space Initial State Goal Test Action Step Cost Path Cost State Change Function State-Space.
Problem Spaces & Search CSE 473. © Daniel S. Weld Topics Agents & Environments Problem Spaces Search & Constraint Satisfaction Knowledge Repr’n.
Informed Search CSE 473 University of Washington.
Informed Search Methods How can we make use of other knowledge about the problem to improve searching strategy? Map example: Heuristic: Expand those nodes.
CSC344: AI for Games Lecture 4: Informed search
Heuristics CSE 473 University of Washington. © Daniel S. Weld Topics Agency Problem Spaces SearchKnowledge Representation Planning PerceptionNLPMulti-agentRobotics.
CS 561, Session 6 1 Last time: Problem-Solving Problem solving: Goal formulation Problem formulation (states, operators) Search for solution Problem formulation:
Solving Problems by Searching
Vilalta&Eick: Informed Search Informed Search and Exploration Search Strategies Heuristic Functions Local Search Algorithms Vilalta&Eick: Informed Search.
Informed Search Methods How can we make use of other knowledge about the problem to improve searching strategy? Map example: Heuristic: Expand those nodes.
Introduction to search Chapter 3. Why study search? §Search is a basis for all AI l search proposed as the basis of intelligence l inference l all learning.
Informed search algorithms
Informed search algorithms
CHAPTER 4: INFORMED SEARCH & EXPLORATION Prepared by: Ece UYKUR.
1 Artificial Intelligence CS 165A Tuesday, October 16, 2007  Informed (heuristic) search methods (Ch 4) 1.
Informed search algorithms Chapter 4. Best-first search Idea: use an evaluation function f(n) for each node –estimate of "desirability"  Expand most.
ISC 4322/6300 – GAM 4322 Artificial Intelligence Lecture 3 Informed Search and Exploration Instructor: Alireza Tavakkoli September 10, 2009 University.
Informed searching. Informed search Blind search algorithms do not consider any information about the states and the goals Often there is extra knowledge.
Outline for 4/2 Introduction & Logistics Notion of a Problem Space Search Techniques Video: Kasparov vs. Deep Blue Constraint Satisfaction Techniques.
Review: Tree search Initialize the frontier using the starting state While the frontier is not empty – Choose a frontier node to expand according to search.
Lecture 3: Uninformed Search
Search CPSC 386 Artificial Intelligence Ellen Walker Hiram College.
Artificial Intelligence for Games Informed Search (2) Patrick Olivier
Search (continued) CPSC 386 Artificial Intelligence Ellen Walker Hiram College.
Outline for 3/28 Introduction & Logistics Textbook: chapters 3, 4 and 5. Notion of a Problem Space Search Techniques Constraint Satisfaction Techniques.
4/11/2005EE562 EE562 ARTIFICIAL INTELLIGENCE FOR ENGINEERS Lecture 4, 4/11/2005 University of Washington, Department of Electrical Engineering Spring 2005.
A General Introduction to Artificial Intelligence.
1 Solving Problems by Searching. 2 Terminology State State Space Goal Action Cost State Change Function Problem-Solving Agent State-Space Search.
Problem Spaces & Search Dan Weld CSE 573. © Daniel S. Weld 2 Logistics Read rest of R&N chapter 4 Also read chapter 5 PS 1 will arrive by , so be.
Graph Search II GAM 376 Robin Burke. Outline Homework #3 Graph search review DFS, BFS A* search Iterative beam search IA* search Search in turn-based.
CSE 473: Artificial Intelligence Spring 2012 Search: Cost & Heuristics Luke Zettlemoyer Lecture adapted from Dan Klein’s slides Multiple slides from Stuart.
CPSC 420 – Artificial Intelligence Texas A & M University Lecture 5 Lecturer: Laurie webster II, M.S.S.E., M.S.E.e., M.S.BME, Ph.D., P.E.
CMPT 463. What will be covered A* search Local search Game tree Constraint satisfaction problems (CSP)
Lecture 3: Uninformed Search
Informed Search Methods
Last time: Problem-Solving
For Monday Chapter 6 Homework: Chapter 3, exercise 7.
Informed Search Methods
Logistics Problem Set 1 Mailing List Due 10/13 at start of class
CSE 473 Artificial Intelligence Oren Etzioni
HW #1 Due 29/9/2008 Write Java Applet to solve Goats and Cabbage “Missionaries and cannibals” problem with the following search algorithms: Breadth first.
Artificial Intelligence Informed Search Algorithms
CS Fall 2016 (Shavlik©), Lecture 9, Week 5
Searching for Solutions
Heuristics Local Search
Heuristics Local Search
Heuristic Search Methods
Lecture 9 Administration Heuristic search, continued
Heuristic Search Generate and Test Hill Climbing Best First Search
Search.
Search.
Midterm Review.
Presentation transcript:

Search in Artificial Intelligence zFind the next move in chess, checkers. zScheduling: finding a good class schedule. zTheorem proving: given a set of axioms and inference rules, find a proof of a theorem. zPlanning: find a sequence of actions to achieve a goal for a robot. zNatural language understanding: find the best parse of a sentence.

Dimensions of Search Problems zIn its general form: find a desired object among a set of objects. zSometimes, you don’t even know if the object exists or not. zIn other cases, the goal is to find the best object. zBlind vs. informed search.

3 Specifying a search problem? zWhat are states (nodes in graph)? zWhat are the operators (arcs between nodes)? zInitial state? zGoal test zMetric (e.g., distance to goal) E.g., Eight Puzzle

Search zTypes of Search yBlind yHeuristic & optimization yAdversary Search zAnalysis yCompleteness yTime complexity ySpace Complexity yGuaranteed to find best solution? yGuaranteed to find the closest solution?

5 Search Strategies zBlind Search yGenerate & test yDepth first search yBreadth first search yIterative deepening search yIterative broadening search zHeuristic search zOptimizing search

O(b^d) O(d) Not for infinite spaces Depth First Search a b cd e f gh zMaintain stack of nodes to visit zEvaluation yComplete? yTime Complexity? ySpace Complexity?

Yes O(b^d) Breadth First Search a b c def gh zMaintain queue of nodes to visit zEvaluation yComplete? yTime Complexity? ySpace Complexity?

Yes O(b^d) O(d) Iterative Deepening Search a b c d e f gh zDFS with limit; incrementally grow limit zEvaluation yComplete? yTime Complexity? ySpace Complexity? j i k L

9 Search Strategies zBlind Search zHeuristic Search yBest-first yBeam yHill climbing ySimulated annealing zOptimizing Search 

Heuristic Search zA heuristic (metric) is: yFunction from a state to a real number xLow number means state is close to goal xHigh number means state is far from the goal Designing a good heuristic is very important! (And hard) More on this in a bit...

No O(b^d) zIdea yBreadth first but use priority queue instead of a queue zEvaluation yComplete? yTime Complexity? ySpace Complexity? Best First Search a b c d e f ghj i k L

No O(b^d) O(b + N) Beam Search zIdea yBest first but only keep N best items on priority queue zEvaluation yComplete? yTime Complexity? ySpace Complexity? a b c d e f ghj i k L

No - suffers from plateau, local maxima, ridges O(b^d) but only in pathological cases O(b) Hill Climbing zIdea yAlways choose best child; no backtracking zEvaluation yComplete? yTime Complexity? ySpace Complexity? a b c d e f ghj i k L

Simulated Annealing zObjective: avoid local minima zTechnique: yFor the most part use hill climbing yOccasionally take non-optimal step yReduce probability(non-optimal) over time zComparison to Hill Climbing yCompleteness? ySpeed? ySpace Complexity? temp

15 Search Strategies zBlind Search zHeuristic Search zOptimizing Search yA* yIDA* ySMA* Objective is to find the very best solution.  

A* Search zIdea yBest first search with admissible heuristic yPlus keep checking until all possibilities look worse zEvaluation yFinds optimal solution? yTime Complexity? ySpace Complexity? Yes O(b^d) Underestimates cost of any solution which can reached from node {

Admissible Heuristics zf(x) = g(x) + h(x) zg: cost so far zh: underestimate of remaining costs a b c d e f For eight puzzle?

Importance of Heuristics D IDS A*(h1)A*(h2) zh1 = number of tiles in wrong place zh2 = sum of distances of tiles from correct loc

Iterative Deepening A* zLike iterative deepening depth first, but... zDepth bound modified to be an f-cost limit zContour lines bounding search a b c d e f F=15 F=21

SMA* zProblem is f-cost bound increases slowly zMust do iterative search again and again zStoring little state between each iteration yJust one number: next highest contour level zSMA* yUses all available memory to store state yDuplicates minimal work yOptimal in a number of nice ways

Adversary Search zGame playing: want to make the move for which the opponent cannot respond well. a b c d e f ghj i k L c f gh c f h c f g c f gh max min

Alpha-beta Pruning z a b c d e f ghj i k L c f c f c f c f max min max