Software Agents - PowerPoint PPT Presentation

1 / 22
About This Presentation
Title:

Software Agents

Description:

Software Agents. Catherine L. Hansen. Jessica C. Baker. CPS 001. What is an agent? ... But what do these words mean, and more importantly, how do they come ... – PowerPoint PPT presentation

Number of Views:58
Avg rating:3.0/5.0
Slides: 23
Provided by: defau182
Category:

less

Transcript and Presenter's Notes

Title: Software Agents


1
Software Agents
  • Catherine L. Hansen
  • Jessica C. Baker
  • CPS 001

2
What is an agent?
  • There are many possible definitions. There are
    also several characteristics that most agents
    possess.
  • -Autonomous
  • -Adaptive/Learning
  • -Mobile
  • -Persistent
  • -Goal-oriented
  • -Communicative/Collaborative
  • -Flexible -Active/Proactive
  • -Small in size
  • But what do these words mean, and more
    importantly, how do they come together to define
    the concept of an AGENT?

3
Agent Characteristics
  • Here is how a few computer scientists have
    defined agent -The AIMA Agent AIMA stands for
    Artificial Intelligence A Modern Approach by
    Russell and Norvig (1995.) They define an agent
    as Anything that can be viewed as perceiving its
    environment through sensors, and acting upon that
    environment through effectors. The problem with
    this definition its too general. It can apply
    to any organisms (including humans and most
    animals) that interact with their environment
    through sensation and perception. How about
    something more specific?
  • -The Maes Agent Maes (1995) describes autonomous
    agents as Computational systems that inhabit
    some complex, dynamic environment, sense and act
    autonomously in this environment, and by doing so
    realize a set of goals or tasks for which they
    are designed.

4
How is a software agent different from a program?
  • Using the Maes definition as a starting point,
    the difference between a software agent and a
    program is that an agent is designed to take
    action that is not necessarily anticipated by the
    programmer, in a complex and changing
    environment. It also interacts with its
    environment, and often learns from it. A program,
    in contrast, is designed to take a predictable
    action with known inputs, and to stop running
    after this action is completed.
  • An agent, on the other hand, is persistent.
  • Smith, Cypher, and Spohrer (1994) defines a
    software agent in this manner a persistent
    software entity dedicated to a specific purpose.
    Persistent distinguishes agents from
    subroutines agents have their own ideas about
    how to accomplish tasks, their own agendas.

5
More Definitions
  • As to learning from a dynamic environment,
    Hayes-Roth (1995) specifies three functions that
    an intelligent software agent must continuously
    perform perception of dynamic conditions in the
    environment action to effect conditions in the
    environment and reasoning to interpret
    perceptions, solve problems, draw inferences, and
    determine actions.
  • Next question How are different kinds of agents
    classified?

6
A Working Taxonomy of Agents
  • It may be easier to understand the concept of a
    software agent by keeping in mind that while all
    agents are programs, all programs are not
    necessarily agents.
  • Although by definition, all agents must be
    reactive, autonomous, goal-oriented and
    temporally continuous, they can also be
    sub-classified by other properties specifically
    assigned to a particular agent to help it reach
    its goals.
  • The computer scientist Brustolini (1991) designed
    a taxonomy of software agents based on three
    properties
  • Regulation Agents these agents only react to and
    regulate input, and neither plan nor learn. They
    can be said to come the closest to basic software
    programs, although their autonomous function
    prevents them from being classified as such.

7
A Working Taxonomy Continued
  • Planning Agents to put it simply, they plan.
    There are several methods of planning perhaps
    the most well-known of these is through
    artificial intelligence.
  • Adaptive Agents the highest level of agents
    they not only plan, but learn.
  • In addition, agents with multiple functions may
    be classified under more than one of these
    definitions.
  • Other methods of agent classification may be
    defined via control structures, applications,
    language employed, and environment. Keep in mind
    that none of these taxonomies will necessarily
    cover the waterfront there are as many
    possible ways to classify software agents as
    there are to classify biological organisms.
  • Next question In which types of environments do
    software agents function and communicate?

8
Dialogs and Multi-User Domains
  • Agents communicate with each other in specially
    designed forums.
  • Michael Cohen, the creator of SodaBot, a
    communication environment for software agents,
    defines agents as programs that engage in
    dialogs and negotiate and coordinate transfer of
    information.
  • Multi-user domains are another example of a
    communication environment.

9
MUD?
  • The first MUDs (multi-user domains) were
    interactive role-playing Dungeons and
    Dragons-type games online. Now, they are forums
    for communication and collaboration, a kind of
    virtual reality in real time, based on
    exchanges of texts. Agents use social
    environments similar to MUDs in order to interact
    with each other.
  • Next question how do agents communicate?

10
Communication Mechanisms
  • There are three commonly used communication
    mechanisms employed by software agents to
    interact and share information with each other
    within their environment. Communication is
    necessary because on their own, agents are
    relatively small and weak part of their
    usefulness is derived from the ability to share
    information over a network.
  • Keep in mind that these three mechanisms are
    employed by threads, programs and subroutines as
    well, but they will be discussed specifically as
    the basic building blocks of agent communication.

11
Procedure Call Mechanism
  • 1) A calls B and waits.
  • 2) B calls C and waits.
  • 3) C returns information for B.
  • 4) B returns information for A.
  • This method is fast and efficient, and allows the
    user to easily track the flow of execution.
  • Example Javas remote method invocation (RMI)
    system.

12
Callback Mechanism
  • 1) A calls B and returns.
  • 2) B calls C and returns.
  • 3) C calls back B with result.
  • 4) B calls back A with result.
  • Pro permits asynchronous processing agents can
    continue on with their tasks while waiting for
    callback.
  • Con agents must halt tasks when information
    arrives complicated and therefore harder for
    user to track flow of execution.
  • Examples Javas GUI toolkits (AWT and Swing)

13
Mailbox Mechanism
  • 1) A calls B and returns with mailbox.
  • 2) B calls C and returns with mailbox.
  • 3) C updates the mailbox.
  • 4) B updates the mailbox.
  • Cons more difficult to implement than other two.
  • Pros allows for asynchronous programming with
    less confusion (best of both worlds!)

14
Mobile Agents
  • Mobile agents do not merely pass information
    around like RMI communication does. They are able
    to navigate through networks and MUD-like
    environments, carrying state information with
    them and gathering new information from other
    agents, the environment and human users. This
    information will often affect the course of their
    future state and behaviorthus, they are
    artificial intelligence agents.
  • A successful mobile agent should be able to
    execute on every machine in a network using a
    mobile code system like Java.

15
Benefits of Mobile Agents
  • Network bandwidth is a valuable resource. If
    traditional communication mechanisms are employed
    and there are too many clients and servers
    executing transactions over the network,
    bandwidth may be exceeded.
  • Mobile network agents help solve this problem by
    handling client/server transactions the agent
    will carry the information as it moves and
    consume less bandwidth than if pieces of the
    information itself were sent.

16
Mobile Agent Architecture
  • An agent host allows multiple agents to co-exist,
    execute and communicate with one another
    simultaneously. It also prevents agents from
    interfering with the execution of other agents so
    that the network runs smoothly.
  • The system (think of it as the environment in
    which agents exist and interact) includes four
    classes
  • Agent class, which defines the agent and exists
    for each agent executing on the system.
  • AgentHost class, which defines the host and keeps
    track of all agents in the system.
  • AgentInterface class, the main conduit for
    communication between individual agents.
  • AgentIdentity class, which allows agents to
    identify other agents to collaborate with.

17
Java and Mobile Agents
  • So far, the Java system provides the best
    technology base for a mobile agent communication
    system. Java virtual machines are so ubiquitous
    that agent code will not have to be installed on
    every machine agents may visit the agent classes
    listed above need only be loaded at runtime over
    the network.
  • One major related issue being tackled by
    programmers is the problem of agent security in
    the face of such an extensive network. Is it
    possible to protect agents from servers in the
    system that deliberately mis-execute their code?

18
Agent Context
  • Agents live and operate within agent hosts. The
    agent hosts move individual agents around and
    enable them to operate on the system. However,
    they do not allow any one agent access to the
    entire application. Instead, they refer each
    agent to a more limited, specific class in which
    to operate, called the agent context.
  • The following code both shows what an agent
    context would look like on a Java machine, and
    provides a concrete (albeit small) example of
    actual agent code.

19
An Abbreviated Look at the Agent Class
  • Something like this would be used for an agent
    communication system.
  • Code source (http//www.javaworld.com/javaworld/j
    w-09-1998/jw-09-howto.html)
  • Abstract public class Agent
  • /
  • The following agent context class will provide
    the agents interface with its environment. The
    agent context is set by the agent host when the
    agent is transferred into a new environment.
  • /
  • Private transient AgentContext agentcontext
    null
  • / This gets the agent context. The reason the
    field is called transient is that a new context
    specific to the agent is created whenever an
    agent is transferred to a new environment.

20
Code for Implementing Agent Class
  • It looks something like this
  • class AgentContext
  • private AgentHost agenthost null
  • AgentContext (AgentHost agenthost )
  • this.agenthost agenthost
  • / The following will send a message and return
    the agents response to the message. The agent
    will call the sendMessage method in order to send
    a message to an agent specified by AgentIdentity.
    After this, the Message class will encapsulate
    the actual message that is sent.
  • /
  • public MessageResponse
  • sendMessage(AgentIdentity agentidentity, Message
    message)
  • return new MessageResponse(agenthost,
    agentidentity, message)

21
Conclusion/Summary
  • Almost anything that functions autonomously,
    interacting with its environment and other
    similar entities, can be classified as an agent.
    This includes humans, animals and some robots,
    all of which live in the real world. In
    contrast, software agents live on networks,
    computer operating systems, databases, MUDs and
    other virtual environments. Mobile agents, which
    we studied more closely, have a primarily
    communicative function, and make the process of
    network transactions much quicker and more
    efficient.

22
Sources Consulted
  • Franklin, Stan, and Art Graesser. Is it an
    Agent, or Just a Program? A Taxonomy for
    Autonomous Agents. University of Memphis
    Institute for Intelligent Systems, 1996.
    http//www.msci.memphis.edu/franklin/AgentProg.ht
    ml
  • Groves, Paul. MUDs, MOOs, WOOs and IRC.
    http//www.oucs.ox.ac.uk/ltg/projects/jtap/reports
    /teaching/chapter5.html
  • Minar, Nelson. Java as Technology Base for
    Mobile Agents. http//xenia.media.mit.edu/nelson
    /research/dc/node3.html
  • Sundsted, Todd. Agents Talking to Agents.
    http//www.javaworld.com/javaworld/jw-09-1998/jw-0
    9-howto.html
Write a Comment
User Comments (0)
About PowerShow.com