CS156
Chris Pollett
Oct 17, 2022
Below is pseudo-code for a knowledge-based agent. As with all of our agents, it receives percepts about its environment, and returns actions. It maintains a KB, which initially may contain some background knowledge.
function KB-Agent(percept) returns an action
persistent KB, a knowledge base
t, a counter, initially 0, indicating time
// store the percept into the KB
Tell(KB, Make-Percept-Sentence(percept, t))
// choose an action
action := Ask(KB, Make-Action-Query(t))
// tell the KB, we did that action at time t
Tell(KB, Make-Action-Sentence(action, t))
t++
return action
Which of the following is true?
The logical connectives are:
Sentence := AtomicSentence | ComplexSentence
AtomicSentence := True | False | P | Q | R |...
ComplexSentence := (Sentence) | [Sentence]
| `neg` Sentence
| Sentence `^^` Sentence
| Sentence `vv` Sentence
| Sentence `=>` Sentence
| Sentence `<=>` Sentence