Download as pdf or txt
Download as pdf or txt
You are on page 1of 46

Fakultät

 für  Informa0k  
der  Technischen  Universität  München  

Cogni&ve  Systems  

A. Knoll, F. Röhrbein, A. Perzylo + his team,


R. Hostettler, D. Clarke

Robotics and Embedded Systems (Informatik VI, TUM)


fortiss GmbH

Cogni0ve  Systems    

SS  2014   1  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Cognitive Systems 2:
Cognitive Architectures

Cogni0ve  Systems    
SS  2014   2  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Key Publications

Langley,  P.:  Cogni&ve  architectures  and  general  intelligent  systems.  AI  Magazine  27(2),  33–44  
(2006).  
 
Sun,  R.:  Desiderata  for  cogni&ve  architectures.  Philosophical  Psychology  17(3),  341–373  (2004).  
 
Sun,  R.:  The  importance  of  cogni&ve  architectures:  an  analysis  based  on  clarion.  Journal  of  
Experimental  &  Theore0cal  Ar0ficial  Intelligence  19(2),  159–193  (2007).  
 
Vernon,  D.,  von  Hofsten,  C.,  and  Fadiga,  L.  A.  Roadmap  for  Cogni&ve  Development  in  Humanoid  
Robots,  Cogni0ve  Systems  Monographs,  Springer  (2010).  
 
Vernon,  D.  Cogni&ve  System,  Encyclopedia  of  Computer  Vision,  Springer  (2012)  

Cogni0ve  Systems  
SS  2014   3  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

What is a model?
Models are abstractions of real world systems or implementations
of hypothesis to investigate particular questions about, or to
demonstrate particular features of a system or hypothesis.

•  descriptive models what ?


•  mechanistic models how ?
•  interpretive models why ?

Cogni0ve  Systems    

SS  2014   4  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Models

o  Meaning of models in our context: mathematical representations of system dynamics


§  Models allow the dynamics to be simulated / analyzed without having to build the system
§  Models are never exact, but can be predictive

o  Models can be used in ways the system cannot


§  Certain types of analysis cannot be done in a real system
§  Resource efficiency

o  The model to use depends on the questions asked


§  A system has many models
§  Choice of time and space scale
§  Always formulate questions before building a model

Cognitive architectures as models of cognition

Cogni0ve  Systems    

SS  2014   5  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Motivation

It’s relatively easy to write software for isolated robot components …

vision
module
leg
module

?  

arm
module

… but how do we put these together?


Cogni0ve  Systems    

SS  2014   6  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

The Early Ages of Robotics

sensors

string  everything  together  in  a  single  program…  


if (...)
then ...
û not  good,  because  
û hard  to  maintain  
û no  flexibility  (hardware,  tasks,  …)  
û not  scalable  

motion

Cogni0ve  Systems   7  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

A better solution …
environment  

signalling  
controller  

seman0c  analysis  
motor  controller  
perceptual  system  

planning  system  
model  of  human  
state  of  mind  
aben0on  control  

decision  maker  
internal  state  

goal  manager  
environment  model  

…  build  a  system  based  on  a  Cogni0ve  Architecture!  

Cogni0ve  Systems   8  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Cogni0ve  Systems  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Cogni0ve  Systems  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Definitions: a cognitive architecture…

•  „... is a broadly-scoped, domain-generic computational cognitive model,


capturing the essential structure and process of the mind, to be used for a
broad, multiple-level, multiple-domain analysis of behavior.“
[Sun, 2004, Philosophical Psychology]

•  „... is a specification of the structure of the brain at a level of abstraction that


explains how it achieves the function of the mind.“
[Anderson, 2004, Psychological Review]

•  „... specifies the underlying infrastructure for an intelligent system. Briefly, an


architecture includes those aspects of a cognitive agent that are constant over
time and across different application domains.“
[Langley, 2007, Cognitive Systems Research]

Cogni0ve  Systems  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Types of Cognitive Architectures

“Mind  models”   “Technical  


  Architectures”  
•  abstrac0on  of  the   •  emula0on  of  human  
human  mind     cogni0on    
•  psychological  and  AI   •  focus  on  robo0cs  
background   applica0ons  
•  lots  of  research,  esp.   •  rela0vely  new  
in  psychology   research  topic  
•  research  goal:   •  research  goal:  
Theory  of  Cogni0on   Smarter  Robots  

Cogni0ve  Systems   12  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

CA Examples: ACT-R [Anderson el al., 2004]


•  cogni0vist  mental  model  
•  successor  of  ACT  (1980s!)  
•  integrates  several  major  
branches  of  current  
psychol.  AI  research.  
•  uses  “buffers”  to  store  and  
retrieve  rule-­‐based  
“produc0ons”  
•  no  parallel  processing  
•  percep0on  and  motor  
External   control  added  recently  
World  
Cogni0ve  Systems   13  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Cognitive Architecture Paradigms


•  Cogni&vists  treat  cogni0on  as  a  form  of  (possibly  stochas0c)  computa0on,  i.e.  the  
processing  of  (symbolic)  informa0on  by  means  of  algorithms  and  logic.    
•  Emergent  systems  are  mostly  based  on  the  principle  of  self-­‐organiza0on,  do  not  
rely  on  many  assump0ons  about  the  environment  and  develop  cogni0ve  
capabili0es  as  they  evolve.    
•  Hybrid  systems  exploit  the  speed  and  robustness  of  emergent  systems,  by  
complemen0ng  them  with  the  clear  structure  and  programmability  of  cogni0vist  
systems.    
[a?er  Vernon  et  al.  2007]  

Cogni0ve  Systems   14  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Different Approaches to Cognition

[a?er  Vernon    
et  al.  2007]  

Cogni0ve  Systems   15  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Paradigm Pros & Cons

Cogni&vist     Emergent     Hybrid    


•  easy  to  include  prior   •  closer  to  biology     •  “best  of  both  worlds”    
knowledge   •  few  assump0ons,   •  probably  most  
•  easy  analysis  of  “thought   evolve  capabili0es  on   suitable  for  future  
processes”   their  own     robots    
•  complex  tasks  possible   •  flexible,  robust  and  fast   •  difficult  to  find  
•  tend  to  be  less  flexible   •  hard  to  extract  learned   common  ground  of  
knowledge    and  rules   paradigms  
•  manual  programming  of  
facts  /  behaviours   •  prior  knowledge  hard   •  overall  behaviour  not  
to  include   well  understood  
•  slowed  down  a  lot  by  
accumulated  symbolic   •  complex  tasks  difficult  
knowledge  
Cogni0ve  Systems   16  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Example: Hierarchical Temporal Memory [Hawkins, 2004]

Emergent  mental  model  


 
•  not  really  a  complete  CA  (yet),  but  rather  a  „cortex  algorithm“  forming  the  
basis  of  a  new  theory  of  cogni0on  

•  main  idea:  cortex  is  a  hierarchical  associa0on  and  predic0on  engine  all  
signals  reaching  the  brain  (external  senses,    internal  reflec0on)  are  just  
paberns  hence  there  is  no  need  for  „ar0ficial“  func0onal  submodules,  
everything  is  treated  the  same  way  for  a  CA,  would  need  to  add  „old  
brain“  func0on,  esp.  drives  

Cogni0ve  Systems   17  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Cogni0ve  Systems  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Classical Examples of Cognitive Architectures


Some  cogni0ve  architectures  produced  over  30  years  include:  

§   ACTE  through  ACT-­‐R  (Anderson,  1976;  Anderson,  1993)  


§   Soar  (Laird,  Rosenbloom,  &  Newell,  1984;  Newell,  1990)  
§   PRODIGY  (Minton  &  Carbonell.,  1986;  Veloso  et  al.,  1995)  
§   PRS  (Georgeff    &  Lansky,  1987)  
§   3T  (Gat,  1991;  Bonasso  et  al.,  1997)  
§   EPIC  (Kieras  &  Meyer,  1997)  
§   APEX  (Freed  et  al.,  1998)  

However,  these  systems  cover  only  a  small  region  of  the  space  of  possible  
architectures.        
Cogni0ve  Systems  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems   19
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Cognitive Architecture ACT-R

Cogni0ve  Systems  
SS  2014   20
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Goals of this unit

ñ  To  get  an  overview  of  ACT-­‐R    


•  Main  concepts  and  background  
•  Implementa0on  
ñ  To  gain  basic  experience  in  cogni0ve  modeling  with  ACT-­‐R  

ñ  To  be  able  to  model  simple  chunks  and  produc0ons  

Cogni0ve  Systems  
SS  2014   21
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

CA Examples: ACT-R [Anderson el al., 2004]


•  cogni0vist  mental  model  
•  successor  of  ACT  (1980s!)  
•  integrates  several  major  
branches  of  current  
psychol.  AI  research.  
•  uses  “buffers”  to  store  and  
retrieve  rule-­‐based  
“produc0ons”  
•  no  parallel  processing  
•  percep0on  and  motor  
External   control  added  recently  
World  
Cogni0ve  Systems   22  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Declarative Memory - chunks

A  chunk  represents  a  fact  


Example  3+4=7  

Addition-fact

isa

Addend1 Addition- Addend2


3 4
fact34

sum

Cogni0ve  Systems  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
23
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Modeling of more complex facts

Example  fact:  The  black  cat  with  5  legs  sits  on  the  mat.  
  cat proposition

isa isa

legs
5 cat007 fact007 mat
agent object

color
action

black sits_on

Cogni0ve  Systems  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
24
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Knowledge  Representa&on:  Ontologies    

Image: John Sowa - http://www.jfsowa.com/ontology/index.htm


Cogni0ve  Systems  
SS  2014   25  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Productions

•  Rules  for  modifying  chunks  


 
 Buffer  tests  ==>  Buffer  modifica0ons  
 
•  Several  produc0ons  can  fullfil  the  test  condi0ons  
•  Selec0on  of  most  suitable  produc0on  needed  

•  Use  of  subsymbolic  mechanisms  

•  U0lity  equa0on  es0mates  the  rela0ve  cost  and  benefit  of  each  produc0on    

•  produc0on  with  the  highest  u0lity  is  selected  


 

Cogni0ve  Systems  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
26
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Productions

What,  if  more  than  one  chunk  fullfils  the  buffer  test  of  a  produc0on?  
Again,  subsymbolic  decision:  Chunk  ac0va0on  
 

Past  experiences  indicates  usefulness  at  the  par0cular  moment:  


•  Base-­‐level:  general  past  usefulness  

•  Associa0ve  Ac0va0on:  relevance  to  the  general  context  


•  Matching  Penalty:  relevance  to  the  specific  match  required  
•  Noise:  stochas0c  is  useful  to  avoid  gesng  stuck  in  local  minima  
 

Cogni0ve  Systems  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
27
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Implementation – practical use of the ACT-R software

Cogni0ve  Systems   28
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

ACT-R software

•   LISP-­‐based    
•   Platorm-­‐independent  (Linux/Unix,  Windows,  Mac)  
•   Stand-­‐alone  versions  for  Windows  and  Mac  
 hbp://act-­‐r.psy.cmu.edu/souware/  

•   Java  applet  
 hbp://cog.cs.drexel.edu/act-­‐r/applet.html  

•   Unit  based  on  ACT-­‐R  tutorial  unit  1:  


 hbp://act-­‐r.psy.cmu.edu/actr6/units.zip  
 

Cogni0ve  Systems   29
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

ACT-R Java Applet http://cog.cs.drexel.edu/act-r/applet.html

Cogni0ve  Systems   30
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Knowledge representation in ACT-R

Types  of  Knowledge:  


•   Declara0ve  knowledge  –  chunks    conscious,  facts  can  be  described  
•   Procedural  knowledge  –  produc0ons  unconscious,  like  use  of  language  
 
Chunks:  
•   Represent  facts  of  different  complexity,  such  as  “George  Washington  was  the  
first  president  of  the  United  States”  or  “1+1=2”  
•   Defined  by  a  
•  chunk-­‐type  (similar  to  category,  such  as  bird)  
•  slots  (abributes,  such  as  color  or  size)  
Syntax:  (chunk-­‐type  name  slot-­‐name-­‐1  slot-­‐name-­‐2  …  slot-­‐name-­‐n)  

Cogni0ve  Systems   31
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Knowledge representation in ACT-R (II)

Chunks  (cont’d):  
•  Special  slot  ISA  to  specify  the  type  of  a  chunk  
 
Action023            Defines  a  chunk  (fact)  named  Ac0on  023  
isa chase        Defines  the  chunk-­‐type  
agent dog
       Defines  the  slot  values  
object cat
Fact3+4
isa addition-fact
addend1 three
addend2 four
sum seven

Cogni0ve  Systems   32
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Knowledge representation in ACT-R (III)

Creating chunks:
•  First step: definition of chunk-types
(chunk-type bird species color size)
(chunk-type column row1 row2 row3)
(chunk-type count-order first second)

•  Second step: declaration of facts


(add-dm Add to declarative memory
(b ISA count-order first 1 second 2)
(c ISA count-order first 2 second 3)
(d ISA count-order first 3 second 4)
(first-goal ISA count-from start 2 end 4))

Cogni0ve  Systems   33
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Knowledge representation in ACT-R (IV)

Productions:
•  Statements that control behavior
•  Represented as IF .. THEN … rules

Examples in English:
IF the goal is to classify a person Conjunction of features to be tested
and he is unmarried
THEN classify him as a bachelor Operation to be performed, if selected

IF the goal is to add two digits d1 and d2 in a column


and d1 + d2 = d3
THEN set as a subgoal to write d3 in the column

Cogni0ve  Systems   34
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Modules  and  Buffers  


http://act-r.psy.cmu.edu/workshops/
workshop-2009/talks/overview-anderson.ppt
Modules:  
§  Represent  independent  units,  work  asynchronously   Goal  
§  Responsible  for  scheduling  its  own  events  
§  Main  modules  are:   Imaginal   Declara0ve  
§  Declara0ve  memory  
§  Visual  module  
Procedural  
§  Manual  module  
Visual   Aural  
 
Buffers:  
•  Can  hold  one  chunk  represen0ng  a  fact  
Manual   Vocal  
•  Interface  of  the  modules  
•  Chunk  is  copied  into  buffer  and  modified  locally  
  Cogni0ve  Systems  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
35
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Mapping of modules to brain areas

http://act-r.psy.cmu.edu/workshops/workshop-2009/
talks/overview-anderson.ppt

Cogni0ve  Systems  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
36
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Motivations for a Cognitive Architecture

o  Philosophy:    Provide  a  unified  understanding  of  the  mind  


o  Psychology:  Account  for  experimental  data  
o  Educa&on:  Provide  cogni0ve  models  for  intelligent  tutoring  systems  and  
other  learning  environments  
o  Human  Computer  Interac&on:  Evaluate  ar0facts  and  help  in  their  
design  
o  Neuroscience:  Provide  a  framework  for  interpre0ng  data  from  brain  
imaging.  

Cogni0ve  Systems  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
37
 
 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Cogni0ve  Systems  
SS  2014  
Lehrstuhl  Informa0k  VI  –  Robo0cs  and  Embedded  Systems  
 
 
Structure of Bayesian Networks

Likelihood functions à Encoding of sensory information


Priors à Constraints on possible scenes

P(c) P(d)
cupboard dishwasher
conditional
probability c d P(m|c,d)
table (CPT)
mug

m P(h|m) m P(o|m)
handle opening
Inference in Bayesian Networks

Causal reasoning Evidential reasoning à diagnosis: à perception:


(deduction) (abduction)

Cause Hypothesis

TD BU

TD BU

Consequence Observation

Task: compute posterior for a set of query variables given some event

query variables hidden variables


evidence variables
Exact Inference Procedures

Inference in Bayesian Networks is NP-hard


•  Critical: width of largest clique
•  Restrictions à e.g. polytrees
•  Approx. inference (anytime algo’s)

= Belief propagation, Message passing


= Clique-tree propagation
How Inference Works

π (INDOOR) π (OUTDOOR)
Which kind of knowledge enters
the Bayesian network?
•  Static information
- Structural dependencies

- Conditional probabilities
•  Dynamic information
- priors for root nodes
- Observation / measurements
What do you get?
•  posterior of all variables of
interest
λ (RED)
λ (SMALL)
Bayesian Belief Propagation

BEL( x) = αλ ( x)π ( x)

λ(x) = ∏ λY j (x) π ( x) = ∑ P( x | u1 , … , u n )∏ π X (ui )


j u1 ,…,un i

€ BU TD
λ
π

π Y j ( x) = BEL( x) / λY j ( x)

λ X (ui ) = β ∑ λ ( x) ∑ P( x | u1 , … , u n )∏ π X (u k )
x uk :k ≠i k ≠i
TD Saliency Modulation

resulting saliency
TD bias

spatial modulation
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

UPF  2014   Cogni0ve  Architectures  


 
Fakultät  für  Informa0k  
der  Technischen  Universität  München  

Thanks for your attention!


... and send your questions, comments etc. to
florian.roehrbein@in.tum.de

SS  2014   Cogni0ve  Architectures   46  


 

You might also like