Behavioural State Machines (programming modular agents) Peter Novák Clausthal University of Technology, Germany March 27th, 2008 AITA’08/AAAI SS 2008, Stanford University, USA Peter Novák · Clausthal University of Technology, Germany March 27th, 2008 AITA’08/AAAI SS 2008, Stanford University, USA 1/16
Outline 1 Motivation Behavioural State Machines 2 Jazzbot: case study 3 4 Summary & outlook Peter Novák · Clausthal University of Technology, Germany March 27th, 2008 AITA’08/AAAI SS 2008, Stanford University, USA 2/16
Motivation Agent programming Knowledge intensive/cognitive agents knowledge - attitudes, mental state, state of environment body - sensors/effectors � environment system dynamics - reasoning, behaviours and performing actions Challenges for programming frameworks: theoretical properties - insight into system properties � verification, analysis, design practical applicability - support of traditional SW development techniques, modularity, integration with external systems (Belief-Desire-Intention metaphor in mind ) Peter Novák · Clausthal University of Technology, Germany March 27th, 2008 AITA’08/AAAI SS 2008, Stanford University, USA 3/16
Motivation Agent programming Knowledge intensive/cognitive agents knowledge - attitudes, mental state, state of environment body - sensors/effectors � environment system dynamics - reasoning, behaviours and performing actions Challenges for programming frameworks: theoretical properties - insight into system properties � verification, analysis, design practical applicability - support of traditional SW development techniques, modularity, integration with external systems (Belief-Desire-Intention metaphor in mind ) Peter Novák · Clausthal University of Technology, Germany March 27th, 2008 AITA’08/AAAI SS 2008, Stanford University, USA 3/16
Motivation My way to go... Different programming languages are suitable for different knowledge representation tasks. Focus on encoding agent’s behaviours. Behavioural State Machines A programming framework with clear separation between knowledge representation and agent’s behaviours . Desiderata: clear semantics modularity (KR, source code) easy integration with external/legacy systems Peter Novák · Clausthal University of Technology, Germany March 27th, 2008 AITA’08/AAAI SS 2008, Stanford University, USA 4/16
Motivation My way to go... Different programming languages are suitable for different knowledge representation tasks. Focus on encoding agent’s behaviours. Behavioural State Machines A programming framework with clear separation between knowledge representation and agent’s behaviours . Desiderata: clear semantics modularity (KR, source code) easy integration with external/legacy systems Peter Novák · Clausthal University of Technology, Germany March 27th, 2008 AITA’08/AAAI SS 2008, Stanford University, USA 4/16
Motivation My way to go... Different programming languages are suitable for different knowledge representation tasks. Focus on encoding agent’s behaviours. Behavioural State Machines A programming framework with clear separation between knowledge representation and agent’s behaviours . Desiderata: clear semantics modularity (KR, source code) easy integration with external/legacy systems Peter Novák · Clausthal University of Technology, Germany March 27th, 2008 AITA’08/AAAI SS 2008, Stanford University, USA 4/16
Behavioural State Machines Theoretical framework BSM overview core concept : KR module M = ( L , Q , U ) L - a KR language, Q - a set of query operators | =: S × L → {⊤ , ⊥} , U - set of update operators ⊕ : S × L → S . BDI agent system beliefs desires intentions capabilities update query Environment events Q B U D Q I U C actions interaction rules interpreter Peter Novák · Clausthal University of Technology, Germany March 27th, 2008 AITA’08/AAAI SS 2008, Stanford University, USA 5/16
Behavioural State Machines Theoretical framework BSM Syntax: Query − → Update query formulae | = ϕ is a query ( ϕ ∈ L i , and | = ∈ U i of a KR module M i ) φ 1 ∧ φ 2 , φ 1 ∨ φ 2 and ¬ φ 1 are queries mental state transformer (mst) primitive skip is a mst primitive ⊕ ψ is a mst ( ⊕ ∈ U i , ψ ∈ L i of a module M i ) conditional φ − → τ is a mst ( φ is a query, and τ is a mst) choice τ | τ ′ sequence τ ◦ τ ′ Peter Novák · Clausthal University of Technology, Germany March 27th, 2008 AITA’08/AAAI SS 2008, Stanford University, USA 6/16
Behavioural State Machines Theoretical framework BSM Syntax: Query − → Update query formulae | = ϕ is a query ( ϕ ∈ L i , and | = ∈ U i of a KR module M i ) φ 1 ∧ φ 2 , φ 1 ∨ φ 2 and ¬ φ 1 are queries mental state transformer (mst) primitive skip is a mst primitive ⊕ ψ is a mst ( ⊕ ∈ U i , ψ ∈ L i of a module M i ) conditional φ − → τ is a mst ( φ is a query, and τ is a mst) choice τ | τ ′ sequence τ ◦ τ ′ Peter Novák · Clausthal University of Technology, Germany March 27th, 2008 AITA’08/AAAI SS 2008, Stanford University, USA 6/16
Behavioural State Machines Computational model Semantics: A = ( M 1 , . . . , M n , P ) ☛ ✟ transition system over states σ = � σ 1 , . . . , σ n � induced by updates ⊕ ψ yields ( τ, σ, ν ) ✡ ✠ ⊤ ⊤ update module [{...}] yields ( skip ,σ, ∅ ) yields ( ⊕ ψ,σ, { ( ⊕ ,ψ ) } ) yields ( τ,σ,ν ) , σ | = φ yields ( τ,σ,ν ) , σ �| = φ when query module [{...}] yields ( φ − → τ,σ,ν ) yields ( φ − → τ,σ, ∅ ) then {...} yields ( τ 1 ,σ,ν 1 ) , yields ( τ 2 ,σ,ν 2 ) {...} ; yields ( τ 1 | τ 2 ,σ,ν 1 ∪ ν 2 ) {...} yields ( τ 1 ,σ,ν 1 � = ∅ ) , ∀ ρ ∈ ν 1 : yields ( τ 2 ,σ � ρ,ν ρ ) // ν 1 = { ρ ν 1 1 , . . . ρ ν 1 n } • {...} , // ν 2 = { ρ ν 2 1 , . . . ρ ν 2 yields ( τ 1 ◦ τ 2 ,σ, � { ρ }• ν ρ ) {...} m } ∀ ρ ∈ ν 1 yields ( τ 1 ,σ, ∅ ) , yields ( τ 2 ,σ,ν 2 ) ν 1 • ν 2 = { ρ 1 • ρ 2 | ( ρ 1 , ρ 2 ) ∈ ν 1 × ν 2 } σ � ρ 1 • ρ 2 � ( σ � ρ 1 ) � ρ 2 yields ( τ 1 ◦ τ 2 ,σ,ν 2 ) Peter Novák · Clausthal University of Technology, Germany March 27th, 2008 AITA’08/AAAI SS 2008, Stanford University, USA 7/16
Behavioural State Machines Computational model Semantics: A = ( M 1 , . . . , M n , P ) ☛ ✟ transition system over states σ = � σ 1 , . . . , σ n � induced by updates ⊕ ψ yields ( τ, σ, ν ) ✡ ✠ ⊤ ⊤ update module [{...}] yields ( skip ,σ, ∅ ) yields ( ⊕ ψ,σ, { ( ⊕ ,ψ ) } ) yields ( τ,σ,ν ) , σ | = φ yields ( τ,σ,ν ) , σ �| = φ when query module [{...}] yields ( φ − → τ,σ,ν ) yields ( φ − → τ,σ, ∅ ) then {...} yields ( τ 1 ,σ,ν 1 ) , yields ( τ 2 ,σ,ν 2 ) {...} ; yields ( τ 1 | τ 2 ,σ,ν 1 ∪ ν 2 ) {...} yields ( τ 1 ,σ,ν 1 � = ∅ ) , ∀ ρ ∈ ν 1 : yields ( τ 2 ,σ � ρ,ν ρ ) // ν 1 = { ρ ν 1 1 , . . . ρ ν 1 n } • {...} , // ν 2 = { ρ ν 2 1 , . . . ρ ν 2 yields ( τ 1 ◦ τ 2 ,σ, � { ρ }• ν ρ ) {...} m } ∀ ρ ∈ ν 1 yields ( τ 1 ,σ, ∅ ) , yields ( τ 2 ,σ,ν 2 ) ν 1 • ν 2 = { ρ 1 • ρ 2 | ( ρ 1 , ρ 2 ) ∈ ν 1 × ν 2 } σ � ρ 1 • ρ 2 � ( σ � ρ 1 ) � ρ 2 yields ( τ 1 ◦ τ 2 ,σ,ν 2 ) Peter Novák · Clausthal University of Technology, Germany March 27th, 2008 AITA’08/AAAI SS 2008, Stanford University, USA 7/16
Behavioural State Machines Computational model Semantics: A = ( M 1 , . . . , M n , P ) ☛ ✟ transition system over states σ = � σ 1 , . . . , σ n � induced by updates ⊕ ψ yields ( τ, σ, ν ) ✡ ✠ ⊤ ⊤ update module [{...}] yields ( skip ,σ, ∅ ) yields ( ⊕ ψ,σ, { ( ⊕ ,ψ ) } ) yields ( τ,σ,ν ) , σ | = φ yields ( τ,σ,ν ) , σ �| = φ when query module [{...}] yields ( φ − → τ,σ,ν ) yields ( φ − → τ,σ, ∅ ) then {...} yields ( τ 1 ,σ,ν 1 ) , yields ( τ 2 ,σ,ν 2 ) {...} ; yields ( τ 1 | τ 2 ,σ,ν 1 ∪ ν 2 ) {...} yields ( τ 1 ,σ,ν 1 � = ∅ ) , ∀ ρ ∈ ν 1 : yields ( τ 2 ,σ � ρ,ν ρ ) // ν 1 = { ρ ν 1 1 , . . . ρ ν 1 n } • {...} , // ν 2 = { ρ ν 2 1 , . . . ρ ν 2 yields ( τ 1 ◦ τ 2 ,σ, � { ρ }• ν ρ ) {...} m } ∀ ρ ∈ ν 1 yields ( τ 1 ,σ, ∅ ) , yields ( τ 2 ,σ,ν 2 ) ν 1 • ν 2 = { ρ 1 • ρ 2 | ( ρ 1 , ρ 2 ) ∈ ν 1 × ν 2 } σ � ρ 1 • ρ 2 � ( σ � ρ 1 ) � ρ 2 yields ( τ 1 ◦ τ 2 ,σ,ν 2 ) Peter Novák · Clausthal University of Technology, Germany March 27th, 2008 AITA’08/AAAI SS 2008, Stanford University, USA 7/16
Recommend
More recommend