A start state: s0 ∈ S Uninformed (Blind) search: when we don`t know

State space:
all possible congurations of the domain
of interest
Search Algorithm:
Enqueue nodes by the cost of the
path and heuristic estimate of the node.
A start state: s0 ∈ S
Admissible Heuristic: if h ∗ (n) is the cost of the
Goal States: The set of end states
shortest path from n to any goal, then h(n) is admissiOperators A: Actions available , dened in terms of a ble i h(n) ≤ h ∗ (n)
mapping from a state to its successor
A* search: Heuristic search with an admissible heurisPath: a sequence of states and operators
tic, it is complete and optimal
Path cost: number associated with each path
Consistent: An admissible heuristic is consistent if
Solution: a path from s0 to a goal state
h(s) ≤ cost(s, s0 ) + h(s0 ) for every state s and its suc0
Optimal solutions: a solution with minimum cost
cessors s
Search node: a state, the parent state and the opera- Iterative Deepening A*: Basically DFS, instead of
f (h + c), we expand all nodes
increase f . Uses less memory than
tor used to generate it, the cost of the path, the depth
max depth, we use max
of the node
up to
Candidate nodes: a set of nodes to be expanded
Expanding a node: Applying all legal operators
to
the state in the node and generating all successor states
Uninformed (Blind) search:
f,
then we
A*.
when we don't know
Real-Time search:
Do A* but with the g function equal
to cost from current state rather than from the start
how far a state is to the goal. Has exponential worst
α-pruning:
case complexity
value of any node in the current search horizon, and a
Informed (heuristic) search:
a heuristic is used to
guess how far the state is to the goal
Breadth-rst search:
all nodes at level i get expand-
ed before all nodes at level i+1, complete,
O(bd )
time
and space complexity
Branching factor:
•
•
•
Nodes at the deepest level get
DFS,
Constructive:
Iterative improvement/repair:
Global search:
start with a
start from multiple states far a-
part, and go around the serch space
Hill climbing:
greedy local search. Start at a cong-
successor is worst than the current state. Can get stuck
in local extrema, can get stuck on a plateau.
Simulated annealing:
E,
crease the depth successively. It is complete, and has
old value
linear space requirements.
probability
Heuristic:
move to
Best-First Search:
Nodes are enqueued in the order
of most promising to least promising.
d
O(b )
plexity, not complete or optimal, greedy.
time com-
Heuristic
if a new value
Xi ,
if it's worse,
Ei is better than
move to Xi with
E−E
− T i
Intuition about the distance from a state
to the goal.
e
.
P r(i) =
F itness(j)
Tournament selection:
pick 2 random individ-
•
Rank selection:
sort hypothesis by tness,
probability is proportional to rank
•
Boltzman
selection:
P r(i)
=
Ppexp(F itness(i)/T )
j=1 exp(F itness(j)/T )
Elitism:
Best solution ever encountered in hill climb-
ing/simulated annealing/genetic algorithms are saved.
Constraint satisfaction problem:
a solution that
satises a set of contraints, basically a cost function
with minimum value at the solution, and max value
somewhere else. It is dened by:
•
A set of variables that can take values from a do-
A set of constraints specifying what combination
of values are allowed, they can be explicit (A¬3)
or implicit (A¬B )
still may not complete.
every night It's like depth-limited search but you in-
p
j=1
uals, compare them, the superior one is picked.
•
uration, go to its best successor, repeat until the best
What happens to your mom
•
Ways of selection:
Fitness proportionate
selection:
P
F itness(i)/
start from scratch, build a solu-
but cut o at a max depth. It always terminates, but
Iterative Deepening:
•
•
suboptimal solution, and improve it
path. Guaranteed to nd an optimal solution
Depth-limited search:
selection/mutation/crossover.
tion
in a priority queue, ordered by increasing cost of the
optimal, not complete.
a population. Populations change over generations by
main
Types of search methods:
When you enqueue the nodes
O(bd) space comp, O(bd ) time comp, not
described by a set of states
the best solution, and not the path.
est solution
searched rst,
that has the lowest f-
and an evaluation function, we are only interested in
how long is the path to the shallow-
Depth-rst search:
α
will never be expanded.
Optimization Problems:
how many operators at most can
Uniform cost search:
α
node costing more than
be applied to a state
Solution depth:
Maintain a value
A solution is called an individ-
ual, each individual has a tness, a set of individuals is
instead of looking for a path to
the goal, we just move in the direction of the best path.
Real-Time A*:
Genetic algorithms:
T decreases with time.
When T is high it's in
exploratory phase, when T is low it's in exploitation
variables such that all constraints are satised.
Binary CSP: each constraint relates at most two variables
Constraint Graph:
Nodes are variables, arcs are con-
straints
Preferences(Soft constraints):
represented using
costs, lead to constrained optimization problems
Backtracking search: Basically like DFS.
Forward checking: Assign value to X, look at each unassigned Y connected to X and delete from Y's domain
those values which are inconsistent with X's assignment
Complexity of CSP:
•
Worst-case is
ues and
phase. Simulated annealing is a randomized search or
Monte Carlo search.
A CSP solution is an assignment of values to the
•
n
O(dn ), d
is number of possible val-
is the number of variables
Tree constraint graphs are
O(nd2 )
•
Nearly-tree structured graphs are
where
c
O(dc (n − c)d2 )
is the number of variables which when
removed turns the graph into a tree.
Iterative improvement algorithm:
Start with a
less conicts occur
choose value that violates
the fewest constraints. It solves CSP in almost linear
time except for a very small subset of problems
Minimax search:
Expand a complete search tree,
then go back up picking the worst value at min levels
and best value at max levels. Complete if game tree is
nite, optimal against optimal opponent.
O(bm ),
plexity
space complexity
Time com-
O(bm).
Cope with
resource limitation by cutting o, and use heuristic to
estimate values at cuto.
pruning:
α−β
max as
α
We keep the best possible value for
and the best possible value for min as
if any node is lower we don't expand it.
β
and
It does not
aect the nal result.
Monte Carlo tree search:
t:
A sentence is valid if it's true in 1 interpretation,
satisable if in all, unsatisable if in none.
broken assignment, reassign conicted variables until
Min-conicts heuristic:
world with symbols in the sentence: a truth assignmen-
Play the game randomly
Entailment(KB
α ):
KB entails
α
i
α
Inference(KB
all worlds where KB is true.
can be derived from KB by inference
is true in
`i α): α
procedure i. i is
`i α, KB α. i is complete if when
`i α. Model checking: an inference
sound if when KB
KB
α,
KB
proof method by enumerating a truth table.
Conjunctive normal form:
conjunction of disjunc-
tion of literals: OR clauses connected by ANDs
Disjunctive normal form:
disjunction of conjunc-
tion of literals: And clauses connected by ORs
Horn form:
Clauses with
≤
1 positive literal, impli-
cations connected by ANDs
1
n
1
Plan:
A collection of actions for performing some task
when query q is asked, if q is in
α→β
Implication elimination: ¬α∨β
Planning graph: Proposition and
ranged in levels in which they alternate. Lines between
indicate mutual exclusions.
Predicates:
used to de-
objects.
Quantier: ∀ or ∃
Atomic sentences:
engine with general rules for deducing new facts
term1 = term2 , Term = function(term1 , . . . , termn ) or
Logic:
Formal language for representing information.
Complex sentences:
dene the meaning of sentences
using connectives
of
A way of matching objects in the
∀x∀y ↔ ∀y∀x, ∃x∃y ↔ ∃y∃x, ∃x∃y = ∃y∃x
∀xf (x) ↔ ¬∃x¬f (x), same with exists.
Epistemological Commitment:
What
states
knowledge are in the language: true/false/etc
STRIPS Operator:
preconditions are conjunctions
of positive literals, postconditions are in terms of an
Add-list and a Delete-list.
State-space planning:
nding a plan by looking
through state space looking for a path from start to
Goal Regression:
Pick action that satisfy (some of )
the goal's propositions, make a new goal by remov-
satised by the start state.
Variations of Goal Regression:
linear planning is a
stack of goals, not complete. non-linear (set of goals)
is complete but expensive.
Total vs Partial Order:
total:
plan is always a
unordered
Bayes rule:
P(H|e) = P(e|H)P(H)/P(e), P(e) = P
(e|H)P (H) + P (e|¬H)P(¬H). P(H|e) is posterior
probability, P(H) is prior probability, P(e|H) is likeli-
made from atomic sentences
Universal quantication: ∀xT aking(x, AI) →
Smart(x),
Existential
quantication:
∃xT aking(x, AI)Ŝmart(x) Quantier properties:
What exists in the lan-
guage: facts/objects/relations/time
Interpretation:
predicate(term1 , . . . , termn ) or
constant or variable
Syntax denes sentences in the language, semantics
Ontological Commitment:
eects, goals: conjunction of literals.
strict sequence of actions, partial: plan steps may be
facts expressed in formal/standard lang. An inference
A knowledge base which contains a set of
erators/actions dened in terms of preconditions and
preconditions of this action, repeat until goal state is
Action nodes ar-
of states.
two parts.
a set of typed objects, states:
ing conditions satised by this condition, adding the
scribe objects, properties, and relationships between
Build agents with
Domain:
rst-order predicates over objects in conjunction, op-
goal is reached.
Backward chaining:
with forms of knowledge representation to describe sets
Declarative approach:
STRIPS:
determine new content of knowledge base, repeat until
levels indicate pre/post conditions, lines within levels
of the move is the same no matter when it is played.
is a
skolem function.
KB. Data driven, eager.
KB and continue. Goal driven, lazy
Assume the value
∀xf (x) ← ∃yg(y) = ∀xf (x) ← g(H(x)). H(x)
KB, resolution happens, new sentences are added to
the value of each node is the average of the evaluations
Rapid Action-Value Estimate:
Skolemization
n
KB, return true, else resolve q with other sentences in
portion and a monte carlo portion.
α,α→β
αβ
, And Introduction
,
β
αβ̂
α∨β,¬β∨γ
∀xα
Universal elimination
α{x/τ } , Resolution α∨gamma
: ∃f (x) = Rich(G1), if ∃ is inside ∀:
Modus Ponens
goal. Progression planners start from start, regression
Resolution (for CNF): α∨β,¬β∨γ
α∨γ
planners start from goal.
Modus Ponens (Horn form): α ,...,α ,α β∨...∨α →β Progression (Forward) Planning: Determine all
Forward chaining: when a new sentence is added to applicable operators in the start state, apply operator,
according to some random policy for each player, then
after the simulation. usually you have a minimax pro-
Proofs:
hood, P(e) is normalizing constant.
Conditional
Independence:
P (x|y, z)
P (x|z), ∀x, y, z ,
Knowing
of
the
value
y
change the probability of x if z is known.
F
are conditionally independe,
to
P (C|B)P (F |B)P (B)
P (C, F, B)
=
does
not
C
and
If
decomposes