warmup

From the prep exercises you did for today:

Write down


today


exam followups


course standards


hw followups


FOL

From today’s prep. Share your questions etc with others at your table. With a partner: check in about:

Likes(Rex, Ada)

Owns(Roommate(Ben), Tab)

∀x Likes(Ada, x)

what are relations, objects, functions, symbols, predicates?

Translate English ↔︎ FOL:

∀x (Dog(x) ∧ Likes(Cy, x))

∀x (Dog(x) ⇒ Likes(Cy, x))

at least two people own Tab.

only Ada owns Tab.


from your algorithms course

f is O(g):

∃ N : ∃ c : ∀ n : n > N ⇒ f(n) < c · g(n)

Negate that!


inference in FOL

our first approach to inference with FOL is the classic CS move: reduce to a solved problem: PL inference


A ⇒ B true when A false

AIMA example: 5 objects.


All greedy kings are evil: ∀ x King(x) ∧ Greedy(x) ⇒ Evil(x)

Five objects: x = Richard, LeftLeg(Richard), John, Crown, LeftLeg(John)

All are true PL sentences, so “∀ x (…)” is a true FOL sentence


rule of universal instantiation

It’s what we just did: FOL model with n objects. Take “∀ x S” and replace with n PL sentences, replacing x with each object in the model

If g is a ground term in the model: {x/g} is the substitution of g for x; subst(x/g, S) is the result of applying that subst to S.

Rule of UI:  ∀ x  Ssubst(x/g, S)


existential instantiation

If ∃ x S, then, well, there exists an object making S true. Give it a name that’s different from all the existing symbols (Skolem constant)

∃ x Crown(x) ∧ OnHead(x, John)

Use C1 for such an x: then

Crown(C1) ∧ OnHead(C1, John)

is a true PL sentence


why propositionalization isn’t always great


inference in FOL

Main tool: generalized modus ponens. A formalization of UI, in some ways. KB: objects John, Richard, and sentences:

How to conclude ‘Evil(John)’?


formalizing our common sense thought process


usual equivalences:

King(John), Greedy(John) King(John) ∧ Greedy(John)

so by modus ponens:

King(John) ∧ Greedy(John), (King(John) ∧ Greedy(John) ⇒ Evil(John)) Evil(John)


ingredients

result: the above collectively entails the antecedent of the implication, so by modus ponens, q.


how do you find θ?

need to go from pile of KB sentences to pi′ that “match” or “align with” the pi

that’s unification


Beyond the Text

See the description on Moodle.

Spend some time thinking, chatting with classmates, etc.

Submit a couple ideas to the Moodle assignment (due tomorrow)


on the prep exercises

  1. still need a better name. +99999 magic internet points to anyone with a good suggestion

1.5. actual credit to suggestions & feedback on them

  1. goal: address a failure mode: student who doesn’t think about or study anything between class meetings, just shows up to have knowledge poured into their head. (baby bird metaphor)

  2. also to obviate the firehose / tsunami of content in AIMA

  3. accountability mechanism?

didn’t get to the following..


forward chaining:

with this KB:

what can you say about Q?