Tecnologie ad Agenti: problemi e applicazioni Stefania Costantini Dip. Di Informatica, Univ. degli Studi di L’Aquila nov.

Download Report

Transcript Tecnologie ad Agenti: problemi e applicazioni Stefania Costantini Dip. Di Informatica, Univ. degli Studi di L’Aquila nov.

apr. ’20

Tecnologie ad Agenti: problemi e applicazioni

Stefania Costantini Dip. Di Informatica, Univ. degli Studi di L’Aquila 1

Where do agents come from?

• Seminal work on agents: Carl Hewitt’s actor model (1977) – “a self-contained, interactive and

concurrently-executing object, with some encapsulated internal state and which could respond to messages from other similar objects”

apr. ’20 2

What is an Agent?

• Webster Dictionary: “one who is authorised to act for or in place of another” • Software agents are programs that are able to act on behalf or either a user or another agent in order to perform specific task and/or achieve given goals. apr. ’20 3

Agents

• Systems that can (must) decide by themselves what they need to do in order to satisfy their design objectives.

– Situated in some environment – Have partial control on the environment – Capable of autonomous action • Examples: – Control systems – Software daemons apr. ’20 4

Agents and objects

• Objects are computational entities that encapsulate some state, are able to perform some actions (methods) on this state, and communicate by message passing.

• Differences between agents and objects: 1. Agents do not invoke methods upon one another, but rather request actions to be performed.

2. Objects do not have flexible autonomous behavior.

3. Each agent have its own thread of control.

• OOP could be used for implementing agents, with some modifications apr. ’20 5

Related Approaches

• Distributed Objects – COM (MS Windows DNA) – COM+ • CORBA • JavaBeans/EJBs apr. ’20 6

Why Agents?

•More usable and understandable structure (e.g. spaghetti code vs structure modules).

• (Almost) essential in large distributed systems where all “subsystems” need to be continually interchanging information to collectively achieve or to maintain some desired state apr. ’20 Multi-Agent Systems 7

“Intelligent” Agents

• Agents that operate in a rapidly changing, unpredictable or open environments - where there is a high possibility that actions can fail.

• Then, these agents must be capable of “flexible” autonomous actions – Reactivity – Pro-activeness – Social ability apr. ’20 8

Agent Features

• Autonomous • Reactive • Proactive • Adaptive • Social (in multi-agent systems) • … apr. ’20 9

Abstract architectures for intelligent agents

1. Reactive agents action : S -> A 2. Perception and action see : S -> P action : P* -> A 3. Agents with state see : S -> P action : I -> A next : I X P -> I see next Agent action state Environment apr. ’20 10

Overview of an Agent (by R.A. Kowalski)

Highest level maintenance goals Achievement goals

Forward reasoning

Intermediate level consequences

Forward reasoning

Intermediate level sub-goals

Backward reasoning

Observations

Perceptual processing Motor processing

Actions The world apr. ’20 11

What Kinds of Agents?

Knowledge Agent

Expert in an area of knowledge (human or artificial)

Knowledge Server

and Artificial agent with major capabilities for storing retrieving knowledge (eventually reasoning).

Interface Agent

Intelligent assistant.

apr. ’20 Multi-Agent Systems 12

Coach or Tutor Agent

Intelligent coach or tutor.

Information Search Agent

‘Travelling’ searcher, e.g. knowbots, infobots.

Knowledge Management Agent

High-level coordination of knowledge activities for an individual or collaborative group (e.g. ‘Mediator’, ‘Yellow-pages’, ‘Directory’ agent).

Mediator Agent

Coordinates other agents and resolves conflicts.

apr. ’20 Multi-Agent Systems 13

Directory Agent

‘Points’ when queried ‘Where is XXX?’

Mentor Agent

For higher level expertise or strategy.

Autonomous Agents

Hardware + Software e.g. Autonomous vehicles, robots, etc.

apr. ’20

Other Agents

Citation and document retrieval Dictionaries Atlases (Geographic Information Systems) etc.

etc.

Multi-Agent Systems 14

Multi-agent System (MAS)

• Collection of agents that interact with each other – Cooperation – Competition – Negotiation – ...

apr. ’20 15

Distributed Artificial Intelligence – Definition

• A multiagent system (MAS) is a system in which several interacting, intelligent agents pursue some set of goals or tasks that are beyond their individual capabilities.

• Distributed problem solving considers how the task of solving a particular problem can be divided among a number of agents that cooperate in dividing and sharing knowledge about the problem and about its evolving solutions • DAI is the study, construction and application of MAS.

apr. ’20 16

Multi-Agent Systems (MAS) in DAI

“Software systems in which program modules are given autonomy and intelligence and which interact to attain system objectives” • MAS are major part of Distributed Artificial Intelligence (DAI) • Fastest growing area in Computer Sciences • Rapidly being applied to real-life technological problems (air traffic control, battle simulation, manufacturing, e-commerce, etc.) apr. ’20 17

Agent Languages

An agent language is a language for programming software or hardware agents or agent systems. It should provide for at least some structural agent features and may also allow agency attributes to be directly programmed. It may be incorporated in a

development environment

with user-friendly editors, browsers, etc. which facilitate the programming.

apr. ’20 Multi-Agent Systems 18

Elements of the Agent-Oriented Paradigm Metaphor: autonomous entities

• Events (reactivity and proactivity) • Actions • Time (past events and actions) • Objectives/Goals • Communication apr. ’20 19

In Practice

• Languages: Agent0, Concurrent METATEM, AgentSpeak, DALI, April, ecc.

• Frameworks: Open-Agent Architecture, Impact, KGP, Jade (Java-based), Eclipse, ecc.

apr. ’20 20

Agent Frameworks

• Language + agents and application structure • Es. Open-agent architecture (SRI-International) – Meta-agent to manage goals – Facilitator Agent, to assign subgoals – Agents that execute subgoals based on specific capabilities.

• Es. IMPACT – Agentize new/legacy code – Interface specification of heterogeneous agents apr. ’20 21

apr. ’20

Agent Functions

22

Agent Functions

• Knowledge representation and reasoning – Coping with incomplete information – Planning – Learning • Communication • Coordination • Negotiation • ...

apr. ’20 23

Reasoning

Data is a set of simple descriptions; • information includes interpretations of data; •Knowledge is information about information; • Meta-knowledge is knowledge about knowledge.

The process of using knowledge to create further knowledge is reasoning.

apr. ’20 Multi-Agent Systems 24

Knowledge Base Rules Facts Working Memory SHELL Inference Engine Inference Control Knowledge Acquisition Sub-System Expert Knowledge Engineer Explanation Sub-System User Interface User

apr. ’20

Architecture of a Knowledge-Based Expert System

Multi-Agent Systems 25

Reasoning in Agents

• Coping with incomplete information (assumption-based reasoning) • Planning for reaching objectives • Integration of rationality and reactivity • Learning apr. ’20 26

• • • apr. ’20

Agent communications coordination

Agents communicate in order to achieve better the goals of themselves or of the society in which they exist.

MAS to maintain global coherence (behaving as a unit) without explicit global control.

Agents determine common goals and common tasks, avoid conflicts and pool knowledge and evidence.

Planning Coordination Cooperation Centralized Distributed Competition Negotiation 27

Communications - meaning

• Three aspects to the formal study of communication: 1. Syntax: how the symbols of communication are structured 2. Semantics: what the symbols denote 3. Pragmatics: how the symbols are interpreted – Meaning is a combination of semantics and pragmatics.

apr. ’20 28

Message types

• Communication could be active, passive or both (agent is master, slave or peer) • Two message types: assertions and queries.

• All agents accept information by means of assertions.

• Passive agent: accepts queries, sends replies • Active agent: issue queries, make assertions • Peer agent: all of the above.

apr. ’20 29

Coordination

• DAI involves distributed control and distributed data.

• Agents have a degree of autonomy in generating new actions and deciding which goal to pursue next.

• Knowledge of the system's overall state is dispersed throughout the system.

• Coordination is achieved by means of Coordination Protocols apr. ’20 30

Cooperation

• Basic strategy is to decompose and then distribute tasks • Decomposition done by system designer or by agents • Distribution criteria according to a Cooperation Protocol – Avoid overloading critical resources – Assign tasks to agents with matching capabilities – Make an agent assign tasks to other agents – Reassign tasks if necessary for completing urgent tasks … apr. ’20 31

Cooperation protocols

• Distribution mechanisms: – Market mechanism: generalized agreements or mutual selection – Contract net: announce, bid and award cycles – Multiagent planning: planning agents perform task assignment – Organizational structure: agents have fixed responsibilities apr. ’20 32

Negotiation

• Inter-agent cooperation • Occurs among agents with different goals to reach a joint decision • Conflict resolution • Agents communicate respective desires • Compromise to mutually beneficial agreement apr. ’20 33

Reaching Agreements

• How do agents

reach agreements

when they are self interested?

• In an extreme case (zero sum encounter) no agreement is possible — but in most scenarios, there is potential for

mutually beneficial agreement

on matters of common interest apr. ’20 34

Reaching Agreements

• The capabilities of

negotiation

and

argumentation

ability of an agent to reach such agreements are central to the • There are various Negotiation Strategies apr. ’20 35

Negotiation Strategies

• Desirable properties: – Convergence/guaranteed successMaximizing social welfarePareto efficiencyIndividual rationalityStabilitySimplicityDistribution apr. ’20 36

Agents In Computational Logic

apr. ’20 37

Agents in Computational Logic

• Declarative languages: modular definition and composition of behaviors • Fast prototipyng • Formal semantics • Reasoning capabilities • + New active/reactive capabilities apr. ’20 38

DALI: a general-purpose Agent-Oriented language

patent-pending joint work with Arianna Tocchio • Logical language,extends prolog • Supports the agent-oriented paradigm – different classes of events and their interaction; – advanced proactivity features; – a concept of time.

apr. ’20 39

• •

DALI:Communication

Communication primitives = FIPA-compliant set + Others (implemented in DALI on Linda Tuple Space) Communication Architecture – Primitives tell/told for message filtering – Procedure meta for understanding (possibly by taking advantage of ontologies) apr. ’20 40

Procedural Semantics (Computational Model) Enhanced Resolution Procedure

• Extends prolog resolution • Interleaves different activities: • Can be tuned by the user via directives: Program = Logic + Control apr. ’20 41

apr. ’20 DALI Agents on Sw Components 42

Thank you again for your attention...

apr. ’20 43