200 likes | 351 Views
Monitoring Agents. Ying Qian Zhang/ Jürgen Dix The University of Manchester Thomas Eiter/Michael Fink/Alex Polleres Technical University of Vienna. Outline. Motivation Monitoring Agents in Multi-Agent System Proposed idea IMPACT Agents Model an IMPACT Multi-agent System:
E N D
Monitoring Agents Ying Qian Zhang/ Jürgen Dix The University of Manchester Thomas Eiter/Michael Fink/Alex Polleres Technical University of Vienna
Outline • Motivation • Monitoring Agents in Multi-Agent System • Proposed idea • IMPACT Agents • Model an IMPACT Multi-agent System: • K-Planning Language • Build a Monitoring Agent: • exploit DLV^K • Implementation and Demo • Monitoring a Gofish Post Office MAS • Perspective and Discussion Dagstuhl, 26 November
Motivation • How to model/specify a multi-agent system in order to reach the desired goal? • How to guarantee the MAS is working in a good state? How to “verify” it? • How to make a MAS intelligent so that it can detect/diagnose/recover from the failure? • The performance of the communication of agents is critical to a Multi-agent System. • In a MAS, convert the modelling problem to a planning problem. • Use the planning system to specify/monitor the agents’ collaborationfor a particular application. Dagstuhl, 26 November
Monitoring Agents: Idea • Goal: • Exploit planning systems to model and monitor thecollaboration of agents in a MAS • How? for a particular application • Actions in the plan Messages sent between agents • Check the consistency of actions Monitor the collaboration of agents Dagstuhl, 26 November
formulate monitor model Monitoring Agents: Idea • Goal: model/monitor a good collaboration of agents in a MAS Action Language K DLV^K Multi-Agent System A Monitor Agent Planning Problem • The idea of monitoring is independent of • A MAS ( IMPACT ) or • Planning language ( language K) Is MAS in good states? Dagstuhl, 26 November
IMPACT • IMPACT: Interactive Maryland Platform for Agents Collaborating Together (Subrahmanian/Bonatti/Dix/Eiter/Kraus/Özcan/Ross) how can it help? • Access to distributed, heterogeneous data sources • Seamless interoperability between different software capabilities • Ability to coordinate multiple agents Dagstuhl, 26 November
IMPACT Agents: Data Access • Code Call: d:f( arg_1,…,arg_k ) • Code Call Atom: in( X,d:f(arg_1,…,arg_k) ) Execute function f defined in agent d on the specified arguments.Returns a set of objects. • Kplan-->Kplan:calcKplan ( “D:\bin\DLV\Kplan\gofish.plan”, “D:\bin\DLV\Kplan\gofish.bk”, • "-FPsec", 14, "-silent" ) Succeeds if X is in the set of objects returned • in (plan, Kplan-->Kplan:calcKplan("D:\bin\DLV\Kplan\gofish.plan", "D:\bin\DLV\Kplan\gofish.bk", "-FPsec", 14, "-silent" ) ) Dagstuhl, 26 November
IMPACT Agents • An IMPACT agent consists of: • a set of data types • a set of API functions implemented in any language manipulating those types • a set of actions implemented in any language • a notion of concurrency • a set of action constraints • a set of integrity constraints • an agent program Dagstuhl, 26 November
Action Language K: for formulating a planning problem • The language K (Eiter et al.2000) • a logic-based planning language, syntactically similar to the action language C, but semantically closer to answer set programming • is well-suited for representing incomplete knowledge • with parallel and sequential actions • constructs optimistic and secure plans Dagstuhl, 26 November
DLV^K Planning:exploited by a particular monitor agent • DLV (http://www.dbai.tuwien.ac.at/proj/dlv) A deductive database system, based on disjunctive logic programming, which offers front-ends to several advanced KR formalisms • (http://www.dbai.tuwien.ac.at/proj/dlv/K) • A front-end of DLV for K-planning language • K-Planning frontend option: • -FPsec: generate secure plans • -FPopt: generate optimistic plans Dagstuhl, 26 November
Monitoring Agents • Just starts • Application specific • A small application is implemented in IMPACT • Monitoring Gofish Post Office MAS, which simulates the package delivery service Dagstuhl, 26 November
Action Language K formulate Planning Problem model Multi-Agent System specify a MAS DLV^K monitor Is MAS in good states? A Monitor Agent Monitoring: Gofish Package Delivery • Gofish Post Office: Allows citizens to send certain kinds of packages to other citizens in Gofish. Packages are dropped, shipped, and delivered. • Gofish plan problem formulation using Language K (A.Polleres et al.) Dagstuhl, 26 November
Background description Gofish: Plan description Monitoring: Gofish Package Delivery “gofish.bk” ev(dropoff). ev(distcenter). ev(delivery). ev(truck). location(“DropOff”).location(“ontheway”). location(“DistCenter”). location(“Truck”). location(“Dest”). package(pidVar,pTypeiVar, wtVar, volVar, lSenderVol, fSenderVol, lRecipVar, fRecipVar, recipTelVar, recipEmailVar, origZipVar, destZipVar, destStreetVar, destNumVar, priorityVar, costVar, dropTimeVar, delivTimeVar). “gofish.plan” fluents: undelivered. packageAt(Pid, L) requires package(Pid,PType,Wt, ...,DelivTime), location(L). delivered(Pid) requires package(……) …… actions:DropOff(Pid, PType,…) requires package(Pid… ...)… always: caused undelivered if not stats_sent(Pid). …… inertial packageAt(Pid,L). inertial added(Pid). …… noConcurrency. …… goal: not undelivered? PLAN: DropOff(Pid,…); add_package(…); send_ziptozip(…); DistCenter(…); send_centertohouse(…); get_recipient_info(…); recipient_info(…); Truck(…); send_trucktohouse(…); get_recipient_info(…); Delivery(…); set_delivery_time(…); statistic_info(…). command line: DLV gofish.plan gofish.bk–FPsec –planlength=14 Dagstuhl, 26 November
Notification Agent add_package DropOff Package Agent Event Manager Agent Dispatcher Agent Monitoring: Gofish MAS Design • Gofish Multi-Agent System • Developed to simulate the package delivery service of Gofish Post Office (TU students) Package Agent; Notification Agent; Zip Monitor Agent; Event Manager Agent; Dispatcher Agent; Package Dropper Agent • Agents’ Asynchronous interaction via message exchange Gofish message protocol Dagstuhl, 26 November
Action Language K formulate Planning Problem model Multi-Agent System DLV^K monitor/verify monitor Is MAS in good states? A Monitor Agent A Monitoring Agent: how to work • Some functions: • obtain a set of plans from DLV^K • at regular interval, read messages sent between agents in Gofish MAS from the actions log file • compare messages with actions in the plan, if inconsistent, give out “failure” message; otherwise, continue monitoring Dagstuhl, 26 November
Software Code: new connection data type definitions API function calls Agent Actions actions that can be executed by agent Agent Program: a set of rules “K-planning”: exploits DLV K-planning frontend Plan type Code-calls: get plans from DLV^K; read log file of Gofish MAS; check the state of Gofish MAS … … consider a plan; reduce a plan; failure message; success message … … A Monitoring Agent: Implementation Dagstuhl, 26 November
Demo Monitoring Gofish Multi-agent System Dagstuhl, 26 November
Future Work & Discussion • Monitoring • The monitoring agent should monitor several tasks in parallel • We only detect/report the failure of the MAS • Recovery/re-schedule may be considered • A debugging tool to the MAS • Plan Types • We used secure plans in our first application • Consider other types of plan, i.e. optimistic plan Dagstuhl, 26 November
Future Work & Discussion • Collaboration of Agents in MAS • The monitoring agent only watches the communication between agents • Other actions executed “inside” agent(s) may be monitored in the future • Could it be a feasible approach towards verification of a MAS? Dagstuhl, 26 November