Theory of Mind + Abduction
A Jason agent combining Theory of Mind with abductive reasoning
|
Public Member Functions | |
final Literal[] | tomAbductionTask (List< Term > obsAgentLevel, Atom actor, Atom action) throws JasonException |
int | buf (Collection< Literal > percepts) |
void | euf () |
Object[] | selectAction () throws JasonException |
Private Member Functions | |
final void | backUpBeliefs () throws JasonException |
final void | recoverBeliefs () throws JasonException |
final void | adoptViewpoint (List< Term > viewpoint) throws JasonException |
ListTermImpl | removeUninformativeFacts (ListTermImpl e) |
boolean | checkImpossibleExplanation (ListTermImpl e) |
ListTermImpl | erf (ListTermImpl expls) |
Rule | buildAbductiveIC (ListTermImpl explanations) |
Literal | buildTomRule (List< Term > viewpoint, Rule abductiveIC) |
ListTermImpl | removeRedundantExplanations (ListTermImpl rawExpls) |
List< Literal > | getBeliefsWithSource (Term source) |
Object[] | getAbdToMRuleComponents (Literal l) |
Collection< Rule > | getSortedActionRules () |
List< Term > | getAbducibles (LogExpr logicalFormula) |
Object[] | queryAction () |
boolean | checkActionsInPossibleWorlds (double priority, Atom action, List< Object[]> actionsInPossWorlds) |
LogicalFormula | list2formula (List< Term > args, LogExpr.LogicalOp operator, boolean negateArgs) |
Private Attributes | |
DefaultBeliefBase | backUp = new DefaultBeliefBase() |
Represent a Jason agent capable of Theory of Mind, i.e. switching its perspective to the estimated perspective of other agents (possibly in a recursive fashion).
|
inlineprivate |
Adopt a different viewpoint for the agent.
viewpoint |
JasonException |
|
inlineprivate |
Make a copy of the current belief base in the back-up.
JasonException | if the back-up belief base is not empty. |
|
inline |
The Jason default belief update function is overridden to include a call to the explanation update function.
percepts |
|
inlineprivate |
Build an abductive impossibility constraint clause from a set of explanations.
explanations |
|
inlineprivate |
Given a viewpoint and an abductive \(\texttt{imp}\) clause, build the corresponding recursive believes/2
literal.
viewpoint | |
abductiveIC |
|
inlineprivate |
For a set of possible worlds, check that the selected action in each of them matches the input.
priority | |
action | |
actionsInPossWorlds |
|
inlineprivate |
Check whether an explanation \(\Phi\) is incompatible with the current belief base.
e |
|
inlineprivate |
Explanation revision function. In this default implementation, it returns an explanation where:
expls |
|
inline |
Explanation update function. Remove abductive explanations that are no longer informative in the viewpoint where they held.
|
inlineprivate |
Get the viewpoint and the set of explanations of an abductive IC or believes/2
literal.
l |
|
inlineprivate |
Get the set of abducibles in a logical conjunction.
logicalFormula |
|
inlineprivate |
Get the beliefs with the given source
annotation.
source |
|
inlineprivate |
Get the set of action selection rules sorted by their priority
annotation in descending order.
|
inlineprivate |
Convert a set of explanation from list of lists form to disjunctive normal form (a logical formula).
args | |
operator | |
negateArgs |
|
inlineprivate |
Query the action selection rules in ascending order of priority.
|
inlineprivate |
Copy the beliefs in the back-up back into the main belief base.
JasonException | if the back-up belief base is empty or the main belief base is not clear. |
|
inlineprivate |
Remove duplicates from a set of explanations.
rawExpls |
|
inlineprivate |
Get the subset of facts that are not entailed by the current belief base.
e |
|
inline |
Interpret the default action selection function, considering abductive impossibility constraints and literals.
JasonException |
|
inline |
Perform a complete Theory of Mind + abductive reasoning task.
obsAgentLevel | |
actor | |
action |
JasonException |
|
private |
Store a copy of the current belief base while adopting a different viewpoint.