Title: Multi-Agent Systems Lecture 3 University
1Multi-Agent SystemsLecture 3University
Politehnica of Bucarest2005-2006Adina Magda
Floreaadina_at_cs.pub.rohttp//turing.cs.pub.ro/bl
ia_06
2Agent communicationLecture outline
- The nature of communication
- Indirect communication
- Direct communication
- Agent Communication Languages
- Content languages
- Ontologies
- Theory of speech acts
- KQML
- FIPA and FIPA-ACL
- Interaction protocols
31. The nature of communication
- 1.1 Human communication
- Communication is the intentional exchange of
information brought about by the production and
perception of signs drawn from a shared system of
conventional signs (AIMA, RussellNorvig) ?
language - Action (communicative act) intentional stance
- 1.2 Component steps of communication
- Speaker Hearer
- ? Intention ? Perception
- ? Generation ? Analysis
- ? Synthesis ? Disambiguation
- ? Incorporation
3
4- 1.3 Artificial Communication
- low-level language vs high-level languages
- direct communication vs. indirect communication
- Agent communication/ MAS communication
- low-level communication simple signals, traces,
low-level languages - high-level communication - cognitive agents,
mostly seen as intentional systems - Communication in MAS
- Implies interaction
- The environment provides a computational
infrastructure where interactions among agents
take place. - The infrastructure includes protocols for agents
to communicate and protocols for agents to
interact
4
5- Communication protocols enables agents to
exchange and understand messages - Interaction protocols enable agents to have
conversations, i.e., structured exchanges of
messages - Aim ? Communication enables agents to
- coordinate their actions and behavior, a
property of a MAS performing some activity in a
shared environment - attempt to change state of the other agents
- attempt to make the other agents perform some
actions
5
62. Indirect communication
- 2.1 Signal propagation - Manta, A. Drogoul 1993
- An agent sends a signal, which is broadcast into
the environment, and whose intensity decreases as
the distance decreases - At a point x, the signal may have one of the
following intensities - V(x)V(x0)/dist(x,x0) or V(x)V(x0)/dist(x,x0)2
?
Reactive agents
- 2.2 Trails - L. Steels, 1995
- agents drop "radioactive crumbs" making trails
- an agent following a trail makes the trail faint
until it disappears
6
7- 2.3 Blackboard systems, Barbara Hayes-Roth, 1985
- Blackboard a common area (shared memory) in
which agents can exchange information, data,
knowledge - Agents initiates communication by writing info on
the blackboard - Agents are looking for new info, they may filter
it - Agents must register with a central site to
receive an access authorization to the blackboard - Blackboard a distributed knowledge computation
paradigm - Agents Knowledge sources (KS)
Blackboard
Cognitive agents
7
83. Direct communication
- Sending messages
- method invocation Actors
- exchange of partial plans coordination of
cooperative agents -
- ACL Agent Communication Languages
- Need to communicate knowledge ? knowledge
representation - Need to understand the message in a context ?
ontologies - Communication is seen as an action -
communicative acts
8
93.1 Agent Communication Languages
- Concepts (distinguish ACLs from RPC, RMI or
CORBA, ORB) - An ACL message describes a desired state in a
declarative language, rather than a procedure or
method invocation - ACLs handle propositions, rules, and actions
instead of objects with no associated semantics -
KR - ACLs are mainly based on BDI theories BDI agents
attempt to communicate their BDI states or
attempt to alter interlocutor's BDI state
Cognitive Agents - ACLs are based on Speech Act Theory
Communicative Acts - ACLs refer to shared Ontologies
- Agent behavior and strategy drive communication
and lead to conversations - Protocols
9
10- Origins of ACLs
- Knowledge Sharing Effort - DARPA, 1990
- External Interface Group - interaction between
KBS - KQML - Interlingua - common language of KB - KIF
- Shared, Reusable Knowledge Bases - Ontolingua
- Communication primitives
- and protocols
- Content languages
- KIF
- Prolog
- Clips
- SQL
- FIPA-SL, FIPA-KIF
- Ontologies
- DAML
- OWL
DARPA Agent Markup Language (August 2000). The
goal of the DAML effort is to develop a
language and tools to facilitate the concept of
the Semantic Web.
10
11- 3.2 Content languages for ACL
- (Knowledge representation)
- Description Logics (DL) - a formalism for
expressing concepts and their interrelationships. - In DL, concepts are organized into IS-A
hierarchies. - Concepts are specifications such that given an
individual (object instance) a DL system can
recognize the individual and determine which
concepts it belongs to. - DL systems also perform subsumption checking.
- Knowledge Interchange Format (KIF) - is based
on first order predicate logic and has a
LISP-like prefix syntax. - KIF is capable of expressing facts and rules.
- KIF provides constructs for describing
procedures, i.e. programs to (possibly) be
executed by an agent.
11
12- Knowledge Interchange Format (KIF)
- Facts
- (salary 015-46-3946 john 72000)
- (salary 026-40-9152 michael 36000)
- (salary 415-32-4707 sam 42000)
- Asserted relation
- (gt ( (width chip1) (length chip1))
- ( (width chip2) (length chip2)))
- Rule
- (gt (and (real-number ?x)
- (even-number ?n))
- (gt (expt ?x ?n) 0))
- Procedure
- (progn (fresh-line t)
- (print "Hello!")
- (fresh-line t))
12
13- 3.3 Ontologies
- Ontology a specification of objects, concepts,
and relationships in a particular domain -
- It comprises a vocabulary, a domain theory and a
conceptual schemata to describe organization and
interpretation - Lexicalized ontologies (WordNet, EuroWordNet,
BalkanNet, FrameNet, MikroKosmos). - Ontologies for knowledge representation
Person
Pupil
Stud
Empl
Sun_E
IBM_E
Joe
Alice
Person
Woman
Man
Empl
Stud
Joe
Alice
13
14Ontology Languages
- Wide variety of languages for Explicit
Specification - Graphical notations
- Semantic networks
15Ontology Languages
- Wide variety of languages for Explicit
Specification - Graphical notations
- Topic Maps
16Ontology Languages
- Wide variety of languages for Explicit
Specification - Graphical notations
- UML
17Ontology Languages
- Wide variety of languages for Explicit
Specification - Graphical notations
- RDF
18Ontology Languages
- Wide variety of languages for Explicit
Specification - Logic based
- Description Logics (e.g., OIL, DAMLOIL, OWL)
- Rules (e.g., RuleML, LP/Prolog)
- First Order Logic (e.g., KIF)
19Many languages use object oriented model based
on
- Objects/Instances/Individuals
- Elements of the domain of discourse
- Equivalent to constants in FOL
- Types/Classes/Concepts
- Sets of objects sharing certain characteristics
- Equivalent to unary predicates in FOL
- Relations/Properties/Roles
- Sets of pairs (tuples) of objects
- Equivalent to binary predicates in FOL
- Such languages are/can be
- Well understood
- Formally specified
- (Relatively) easy to use
- Amenable to machine processing
20Web Schema Languages
- Existing Web languages extended to facilitate
content description - XML ? XML Schema (XMLS)
- RDF ? RDF Schema (RDFS)
- XMLS not an ontology language
- Changes format of DTDs (document schemas) to be
XML - Adds an extensible type hierarchy
- Integers, Strings, etc.
- Can define sub-types, e.g., positive integers
- RDFS is recognisable as an ontology language
- Classes and properties
- Sub/super-classes (and properties)
- Range and domain (of properties)
21RDF and RDFS
- RDF stands for Resource Description Framework
- It is a W3C candidate recommendation
(http//www.w3.org/RDF) - RDF is graphical formalism ( XML syntax
semantics) - for representing metadata
- for describing the semantics of information in a
machine- accessible way - RDFS extends RDF with schema vocabulary, e.g.
- Class, Property
- type, subClassOf, subPropertyOf
- range, domain
22Problems with RDFS
- RDFS too weak to describe resources in sufficient
detail - No localised range and domain constraints
- Cant say that the range of hasChild is person
when applied to persons and elephant when applied
to elephants - No existence/cardinality constraints
- Cant say that all instances of person have a
mother that is also a person, or that persons
have exactly 2 parents - No transitive, inverse or symmetrical properties
- Cant say that isPartOf is a transitive property,
that hasPart is the inverse of isPartOf or that
touches is symmetrical -
- Difficult to provide reasoning support
- No native reasoners for non-standard semantics
- May be possible to reason via axiomatisation
23Web Ontology Language Requirements
- Desirable features identified for Web Ontology
Language - Extends existing Web standards
- Such as XML, RDF, RDFS
- Easy to understand and use
- Should be based on familiar KR idioms
- Formally specified
- Of adequate expressive power
- Possible to provide automated reasoning support
24OWL - Web Ontology Language
- W3C
- OWL - designed for use by applications that need
to process the content of information instead of
just presenting information to humans. - OWL facilitates greater machine interpretability
of Web content than that supported by XML, RDF,
and RDF Schema (RDF-S) by providing additional
vocabulary along with a formal semantics. - OWL has three increasingly-expressive
sublanguages - OWL Lite supports a classification hierarchy and
simple constraints. - OWL DL supports maximum expressiveness while
retaining computational completeness (all
conclusions are guaranteed to be computed) and
decidability (all computations will finish in
finite time). - OWL Full supports maximum expressiveness and the
syntactic freedom of RDF with no computational
guarantees.
25OWL - Web Ontology Language
- Ontology header
- ltowlOntology rdfabout""gt
- ltrdfscommentgtAn example OWL
ontologylt/rdfscommentgt - ltowlpriorVersion rdfresource"http//www.w
3.org/TR/2003/CR-owl-guide-20030818/wine"/gt - ltowlimports rdfresource"http//www.w3.org
/TR/2003/PR-owl-guide-20031215/food"/gt - ltrdfslabelgtWine Ontologylt/rdfslabelgt
-
- Simple Named Classes
- Class, rdfssubClassOf
- ltowlClass rdfID"Winery"/gt
- ltowlClass rdfID"Region"/gt
- ltowlClass rdfID"ConsumableThing"/gt
26- 3.4 Theory of Speech Acts
- J. Austin - How to do things with words, 1962,
J. Searle - Speech acts, 1969 - A speech act has 3 aspects
- locution physical utterance by the speaker
- illocution the intended meaning of the
utterance by the speaker (performative) - prelocution the action that results from the
locution - Alice told Tom "Would you please close the
door" - locution illocution content
- prelocution door closed (hopefully!)
- Illocutionary aspect - several categories
- Assertives, which inform the door is shut
- Directives, which request shut the door, can
pelicans fly? - Commissives, which promise something I will shut
the door - Permissive, which gives permission for an act
you may shut the door - Prohibitives, which ban some act do not shut the
door - Declaratives, which causes events I name you
king of Ruritania - Expressives, which express emotions and
evaluations I am happy
26
27- 3.5 KQML - Knowledge Query and Manipulation
Language - A high-level, message-oriented communication
language and protocol for information exchange,
independent of content syntax (KIF, SQL,
Prolog,) and application ontology - KQML separates
- semantics of the communication protocol (domain
independent) - semantics of the message (domain dependent)
- 3 (conceptual) layers
Core of KQML - identity of the network
protocol with which to deliver the message -
speech act or performative Optional - content
language - ontology
Describes low level communication parameters -
identity of sender and receiver - an unique id
associated with the communication
27
28- Syntax S-expressions used in LISP
- KQML performatives are classified
- Queries - These performatives are used to send
questions for evaluation somewhere. - Generative - Used for controlling and initiating
the exchange of messages. - Response - Used by a agent in order reply to
queries. - Informational - Informational performatives are
used to transfer information. - Capability definition - Allows an agent to learn
about the capabilities of other agents and to
announce its own to the agent community. - Networking - Networking performatives make it
possible to pass directives to underlying
communication layers. - Example
- (ask-one sender joe
- receiver ibm-stock
- reply-with ibm-stock
- language PROLOG
- ontology NYSE-TICKS
- content (price ibm ?price) )
(tell sender willie receiver
joe reply-with block1 language
KIF ontology BlockWorld content (AND (Block
A)(Block B) (On A B)) )
28
291. Query performatives ask-one, ask-all,
ask-if, stream-all,...
(stream-all sender willie receiver
ibm-stock content (price ?VL ?price ) )
A
ask-one(P)
B
tell(P)
B
A
stream-all(P)
B
tell(P1)
A
tell(P2)
eos
29
302. Generative performatives standby, ready,
next, rest, discard, generate,...
3. Response performatives reply, sorry ...
B
A
4. Generic informational performatives tell,
untell, insert, delete, ...
5. Capability performatives advartise,
subscribe, recommend...
A
B
6. Network performatives register, unregister,
forward, route, ...
Facilitator
In fact, KQML contains only 2 types of
illocutionary acts assertives and directives
facilitator and network-related performatives (no
necessarily speech acts)
30
31- Facilitator agent
- an agent that performs various useful
communication services - maintaining a registry of service names (Agent
Name Server) - forwarding messages to named services
- routing messages based on content
- matchmaking between information providers and
clients - providing mediation and translation services
point-to-point
B
A
A
B
B
A
A
B
31
32- Semantics of KQML (Labrou Finin)
- Use preconditions and postconditions that govern
the use of a performative the final state for
the successful performance of the performative - Uses propositional attitudes belief, knowledge,
desire, intentions - Preconditions the necessary states for an agent
to send a performative and for the receiver to
accept it and successfully process it if the
precondition does not hold, the most likely
response is error or sorry - Postconditions - describe the state of the sender
after successful utterance of a performative and
of the receiver after the receipt and processing
of a message - Completion condition - the final state after a
conversation has taken place and that the
intention associated with the performative that
started the conversation has been fulfilled - Propositional attitudes
- Bel(A,P) Know(A,S) Want(A,S) Int(A,S)
- Instances of action
- Proc(A,M) SendMsg(A,B,M)
32
33 tell(A,B,X) A states to B that A believes the
content X to be true, Bel(A,X) Pre(A) Bel(A,X)
? Know(A, Want(B, Know(B, Bel(A,X)))) Pre(B)
Int(B, Know(B, Bel(A,X))) or
?Bel(A,X) Post(A) Know(A, Know(B, Bel(A,X)))
no unsolicited information Post(B)
Know(B, Bel(A,X)) Completion Know(B,
Bel(A,X)) advertise(A,B,M) A states to B that A
can and will process the message M from B, if it
receives one Int(A, Proc(A,M)) commisive
act Pre(A) Int(Proc(A,M)) Pre(B)
NONE Post(A) Know(A, Know(B, Int(A,
Proc(A,M))) Post(B) Know(B, Int(A,
Proc(A,M))) Completion Know(B, Int(A,
Proc(A,M)))
33
34- 3.6 FIPA and FIPA - ACL
- Foundation for Intelligent Physical Agents,
1996 - Goal of FIPA make available specifications that
maximize interoperability across agent-based
systems - FIPA Committees ACL, agent specification,
agent-software interaction - As KQML, FIPA ACL is based on speech act theory
it sees messages as communication acts (CA)
syntax similar to KQML - Differs in the names of CAs, set of CAs, and
semantics
34
35- FIPA standard define normative specifications
for - agent management (or agent platform services)
- white pages via an Agent Name Server (ANS)
- yellow pages via a Directory Facilitator (DF)
- registration in a given DF defines a domain
(agent community) - an Agent Platform defines a logical "place"
containing an ANS, DF, management tools, and a
collection of agents - interplatform communication takes place via an
Agent Communication Channel (ACC), which defaults
to CORBA IIOP - agent communication language - FIPA ACL
- based on speech acts
- has a formal semantics
- also included are several predefined protocols
(e.g., contract-net negotiation and auction
protocols), and the concept of application-specifi
c protocols
35
36- agent-software integration
- defines Agent Request Broker and Wrapper roles
- allows an agent system to integrate non-agent
software - details of how wrapper communicates with wrapped
software are left to the implementor (a Wrapper
is an agent, and communicates with other agents
via ACL) - several reference applications for
- personal travel assistance
- personal assistant
- network provisioning and management
- audio/video entertainment and broadcasting
36
37- FIPA has extended these specifications, including
work on - agent management support for mobility
(identifying the relationship between this work
and MASIF is explicitly targeted) - an ontology service, supporting
- - translation of terms between different
ontologies - - downloading meanings of terms, axioms, and
relationships between terms - - querying for relationships between ontologies
- uploading and updating of ontologies
- additional applications, e.g., product design and
manufacturing agents - FIPA does not currently constrain the low-level
implementation of agents to any great extent,
nor, except for defining agent platform services,
does it constrain the infrastructure a great
deal.
37
38FIPA - ACL
FIPA communicative acts Informatives -
query_if, subscribe, inform, inform_if, confirm,
disconfirm, not_understood Task distribution -
request, request_whenever, cancel, agree, refuse,
failure Negotiation - cfp, propose,
accept_proposal, reject_proposal
38
39- FIPA-SL
- (inform sender Agent1
- receiver Agent2
- content (price good2 150)
- in-reply-to round-1
- reply-with bid03
- language S1
- ontology hp-auction
- reply-by 10
- protocol offer
- conversation-id conv-1 )
39
40- FIPA-SL
- (request sender (agent-identifier name i)
- receiver (set (agent-identifer
name j) - content ((action (agent-identifier name
j) - (deliver box7 (loc 10 15))))
- protocol fipa-request
- language fipa-sl
- reply-with order56 )
- (agree sender (agent-identifier name j)
- receiver (set (agent-identifer
name i) - content ((action (agent-identifier name
j) - (deliver box7 (loc 10 15))) (priority
order56 low)) - protocol fipa-request
- language fipa-sl
- in-reply-to order56 )
40
41- FIPA - Semantics
- SL (Semantic Language) - a quantified,
multi-modal logic, with modal operators - Allows to represent
- beliefs
- uncertain beliefs
- desires
- intentions
- B ? - belief D ? - desire U ? - uncertain belief
- PG ? - intention
- Bif ? - express whether an agent has a definite
opinion one way or another about the truth or
falsity of ? - Uif ? - the agent is uncertain about ?
41
42- FIPA - Semantics
- The semantics of a CA is specified as a set of
SL's formulae that describe - Feasibility preconditions - the necessary
conditions for the sender - the sender is not
obliged to perform the CA - Rational effect - the effect that an agent can
expect to occur as a result of performing the
action it also typically specifies conditions
that should hold true of the recipient - The receiving agent is not required to ensure
that the expected effect comes about - The sender can not assume that the rational
effect will necessary follow - ltA, inform(B, ?)gt
- Pre BA ? ? ?BA (BifB ? ? UifB ?)
- Post BB ?
42
43- KQML and FIPA ACL
- The two ACLs are essentially the same
- Although FIPA ACL requires agents to have a
limited knowledge of SL, both the ACLs do not
have fixed semantics. - The FIPA ACL does not provide for facilitator
agents. - This is a major drawback as using facilitator is
one of the best way to overcome different systems
using different content language and providing
matchmaking service. - KQML provides for brokering and recommendation
service, whereas FIPA ACL don't really take this
into account.
43
444. Interaction protocols
- Interaction protocols enable agents to have
conversations, i.e., structured exchanges of
messages - Finite automata
- Conversations in KQML
- Petri nets
- FIPA IP standards
- FIPA-query, FIPA-request, FIPA-contract-net, ...
454.1 Finite state automata
COOL, Barbuceanu,95
ABltltask(do P)
BAltltaccept(do P)
proposeS(P)
BAltltrefuse(do P)
acceptR(P)
rejectR(P)
BAltltresult(do P)
BAltltfail(do P)
counterR(P)
counterS(P)
Winograd, Flores, 1986
rejectS(P)
acceptS(P)
45
46- 4.2 Conversations in KQML
- Use Definite Clause Grammars (DCG) formalism for
the specification of conversation policies for
KQML performatives - DCGs extend Context Free Grammars in the
following way - non-terminals may be compound terms
- the body of the rule may contain procedural
attachments, written as "" and "" that express
extra conditions that must be satisfied for the
rule to be valid - Ex noun(N) ? W, RootForm(W,N),
is_noun(N) - S ? s(Conv, P, S, R, inR, Rw, IO, Content),
member(P, advertise, ask-if - s(Conv, ask-if, S, R, inR, Rw, IO, Content) ?
- ask-if, S, R, inR, Rw, IO, Content
- ask-if, S, R, inR, Rw, IO, Content, OI is
inv(IO), - r(Conv, ask-if, S, R, _, Rw, OI, Content)
- r(Conv, ask-if, R, S, _, inR, IO, Content) ?
- tell, S, R, inR, Rw, IO, Content
- problem(Conv, R, S, inR, _, IO)
Labrou, Finin, 1998
46
47 4.3 Petri nets
Ferber, 1997
Petri net oriented graph with 2 type of
nodesplaces and transitions there are moving
tokens through the net - representation of
dynamic aspect of processes. Tokens are moved
from place to place, following firing rules. A
transition T is enabled if all the input places P
of T posses a token (several other rules may be
defined). A marking is a distribution of tokens
over places. Colored Petri-nets
B does not want to do(P)
A wants to do P, A cannot do P
B is willing to do(P)
Request do(P)
Refuse do(P)
Accept/request do(P)
Success
Completed(P)
Fail to do(P)
Impossible to do(P)
Notification of end(P)
FB
FA1
47
Failure
FA2
Satisfaction
48- References
- M. Huhns, L. Stephens. Multiagent systems and
societies of agents. In Multiagent Systems - A
Modern Approach to Distributed Artificial
Intelligence, G. Weiss (Ed.), The MIT Press,
2001, p.79-120. - M. Wooldrige. Reasoning about Rational Agents.
The MIT Press, 2000, Chapter 7 - Y. Labrou, T. Finin. Semantics and conversations
for an agent communication language. In Readings
in Agents, M. Huhns M. Singh (Eds.), Morgan
Kaufmann, 1998, p.235-242. - J. Ferber - Multi-Agent Systems. Addison-Wesley,
1999, Chapter 6 - T. Finnin, R. Fritzson - KQML as an agent
communication language. In Proc. of the Third
International Conference on Information and
Knowledge Management (CIKM'94), ACM Press, 1994. - M. Singh. Agent communication languages
Rethinking the principles. IEEE Computer, Dec.
1998, p.40-47. - Y. Labrou, T. Finnin, Y. Peng. Agent
communication languages The current Landscape.
IEEE Computer, March/April 1999, p. 45-52. - FIPA97. "Agent Communication Language"
Specification FIPA, 11/28/97 -
48
49- Web References
- DARPA KSE http//www-ksl.stanford.edu/knowledge-s
haring/ - KQML http//www.cs.umbc.edu/kqml/
- KIF http//logic.stanford.edu/kif/
- Ontolingua http//www-ksl-svc.stanford.edu5915/
serviceframe-editor - FIPA http//www.fipa.org/
- DAML http//www.daml.org/
- OWL http//www.w3.org/TR/owl-guide/
- References for Ontologies (due to prof. Stefan
Trausan) - Constandache, G.G., Stefan Trausan-Matu,
Ontologia si hermeneutica calculatoarelor, Ed.
Tehnica, 2001 - Gruber, T., What is an Ontology,
http//www.kr.org/top/definitions.html - J. Sowa, Ontologia si reprezentarea
cunostintelor, în (Constandache si Trausan-Matu,
2001) - http//www.w3.org/2001/sw/WebOnt/
- http//www.cs.man.ac.uk/horrocks/Slides/index.htm
l
49