<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta />
    <article-meta>
      <title-group>
        <article-title>Runtime Self-Checking via Temporal (Meta-)Axioms for Assurance of Logical Agent Systems</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Stefania Costantini</string-name>
          <email>stefania.costantini@univaq.it</email>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Giovanni De Gasperis</string-name>
          <email>giovanni.degasperis@univaq.it</email>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>Dip. di Ingegneria e Scienze dell'Informazione e Matematica (DISIM), Universita` di L'Aquila</institution>
          ,
          <addr-line>Coppito 67100, L'Aquila</addr-line>
          ,
          <country country="IT">Italy</country>
        </aff>
      </contrib-group>
      <fpage>241</fpage>
      <lpage>255</lpage>
      <abstract>
        <p>This paper deals with assurance of logical agent systems via runtime self-monitoring and checking. We adopt temporal-logic-based special constraints to be dynamically checked at a certain (customizable) frequency. These constraints are based upon a simple interval temporal logic particularly tailored to the agent realm, A-ILTL ('Agent-Oriented Interval LTL', LTL standing as customary for 'Linear Temporal Logic').</p>
      </abstract>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>-</title>
      <p>
        Introduction
Certification and assurance of agent systems constitute crucial and far-from-trivial
issues, as agents represent a particularly complex case of dynamic, adaptive and reactive
software systems. Certification is aimed at producing evidence indicating that deploying
a given system in a given context involves the lowest possible level of risk of adverse
consequences (which level of risk can be considered sufficiently “low” depends upon
the application at hand). Assurance is related to dependability, i.e., to ensuring (or at
least obtaining a reasonable confidence) that system users can rely upon the system.
The issue is nicely discussed in [
        <xref ref-type="bibr" rid="ref1">1</xref>
        ], where it is noted that:
      </p>
      <p>
        The term [assurance] is used in a broad (and somewhat imprecise) sense.
Where there is a clear specification (which is not always the case!) then we can
use the two standard terms “verification” and “validation”. Verification in this
context refers to checking whether software meets its specification, and
validation refers to checking whether the specification meets the user’s requirements.
It is widely acknowledged that industrial adoption of agents systems finds a serious
obstacle in the stakeholders lack of confidence about reliability of runtime behavior of
such systems. Citing [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ],
      </p>
      <p>. . . the use of adaptive systems for greater resilience create situations where
runtime verification and monitoring could be particularly valuable. . . . Within
suitable new frameworks, some of the evidence required for certification can
be achieved by runtime monitoring - by analogy with runtime verification, this
approach can, somewhat provocatively, be named “runtime certification”.</p>
      <p>In this paper, we propose methods for runtime monitoring of agent systems. These
methods are not in alternative but rather complementary to the many existing
verification and testing methodologies.</p>
      <p>
        Pre-deployment assurance and certification techniques for agent systems include
verification and testing. Since we do not have room for an extensive illustration we
can provide just few pointers to recent literature, so we invite the reader to refer to
the recent book [
        <xref ref-type="bibr" rid="ref3">3</xref>
        ] and to the references therein. Most verification methods rely upon
model-checking, and some (e.g., [
        <xref ref-type="bibr" rid="ref4">4</xref>
        ]) upon theorem proving. Among recent
interesting work about agent systems (pre-deployment) assurance we particularly mention [
        <xref ref-type="bibr" rid="ref1">1</xref>
        ]
which proposes (though in a preliminary way) a method that alternates the application
of testing with formal verification techniques applied within a “Shallow Scope”, i.e,
with a limited scope of variable values. The outcome of each phase should be taken as
a guidance for the other phase. Thus, different techniques are used in synergy so as to
improve the overall level of assurance. About fault detection and recovery a particularly
interesting work is that of [
        <xref ref-type="bibr" rid="ref5">5</xref>
        ], that opens a new promising direction in
model-checkingbased verification techniques. This approach allows for CTL specifications that express
injection and eventual recovery from a fault.
      </p>
      <p>For formalizing and implementing runtime self-checking in logical agents while
coping with unanticipated circumstances, we propose temporal-logic-based special
constraints to be dynamically checked at a certain (customizable) frequency. These
constraints are based upon a simple interval temporal logic particularly tailored to the agent
realm, A-ILTL (‘Agent-Oriented Interval LTL’, LTL standing as customary for ‘Linear
Temporal Logic’). In this setting, properties can be defined that should hold according
to events that have happened and to events which are supposed to happen or not to
happen in the future. This also considering partially specified event sequences, unexpected
events or event order. The adoption of an interval logics allows for the specification
of time-bounded properties: it makes it possible to specify that some property should
occur within a certain time frame or before/after a certain time, where the interval can
also be conditionally defined. A-ILTL constraints are contextual, i.e., they can be
specified in a general form and each time they are checked they are instantiated (via suitable
preconditions) to the present agent’s state.</p>
      <p>
        In [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ], it is advocated that for adaptive systems (of which agents are clearly a
particularly interesting case) assurance methodologies should whenever possible imply not
only detection but also recovery from software failures. In fact, though (at least in
principle) a certified software should not fail, in practice serious software-induced incidents
have been observed in certified critical systems. In [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ] examples are produced
concerning airplane and air traffic control, where failures are often due on the one hand to
incomplete specifications and on the other hand to unpredictability of the environment.
      </p>
      <p>
        In [
        <xref ref-type="bibr" rid="ref6">6</xref>
        ], which discusses medical robotic applications in human telesurgery, it is
emphasized how such systems should be fail safe in the sense that, in the event of failure,
should proactively respond so as to limit harm to other devices or danger to users.
      </p>
      <p>
        Our methods in fact provide the possibility of correcting and/or improving agent’s
functioning: the behavior can be corrected whenever an anomaly is detected, but can
also be improved whenever it is acceptable, yet there is room for getting a better
performance. Counter measures can be object-level, i.e., related to the application, or
metalevel, e.g., replacing (as suggested in [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ]) a software component by a diverse alternate.
      </p>
      <p>
        A-ILTL constraints are defined over formulas of any underlying logic language L,
and are rooted in the Evolutionary Semantics of agent programs [
        <xref ref-type="bibr" rid="ref7">7</xref>
        ]. We thus obtain a
fairly general setting, that could be adopted in several logic agent-oriented languages
and formalisms, such as, e.g., AgentSpeak (cf. [
        <xref ref-type="bibr" rid="ref8 ref9">8, 9</xref>
        ] and the references therein), DALI
[
        <xref ref-type="bibr" rid="ref10 ref11 ref12">10–12</xref>
        ]), GOAL [
        <xref ref-type="bibr" rid="ref13 ref14">13, 14</xref>
        ], and 3APL [
        <xref ref-type="bibr" rid="ref15 ref16">15, 16</xref>
        ].
      </p>
      <p>In this paper, we show how A-ILTL temporal constraints may be used to check
for critical situations and to enforce suitable reaction patterns for achieving recovery.
The novelty of the approach is in the following aspects. (i) A-ILTL temporal constraints
constitute a device for run-time self-monitoring which can be completely integrated into
agent programs and their semantics. I.e., there is no separate monitor which examines
a “trace” of observations performed on the agent’s behavior. (ii) Self-recovery/repair
is encompassed in the approach. (iii) The semantic integration into the Evolutionary
semantics is devised such that there is no need to implement a full temporal-logic
inference engine, at least if keeping the expressions to be checked reasonably simple. (iv)
Consequently, the complexity of check is reasonably low.</p>
      <p>The paper is organized as follows. In Section 2 we recall the Evolutionary
Semantics. In Sections 3- 4 we introduce the A-ILTL logic, also in relation to the Evolutionary
Semantics. In Section 5 we illustrate A-ILTL constraints and show by means of
examples how such constraints can be exploited for runtime monitoring and self-repair
of agent systems. In Section 6 we briefly discuss the complexity related to run-time
constraint checking. Finally, in Section 7 we discuss related work and propose some
concluding remarks.
2</p>
      <p>
        Evolutionary Semantics
The Evolutionary semantics (introduced in [
        <xref ref-type="bibr" rid="ref7">7</xref>
        ]) is meant at providing a high-level
general account of evolving agents, trying to abstract away from the details of specific
agent-oriented frameworks. We define, in very general terms, an agent as the tuple Ag
= &lt; PA, E &gt; where A is the agent name and PA (that we call “agent program”, but
can be in turn a tuple) describes the agent according to some agent-oriented formalism
L. E is the set of the events that the agent is able to recognize or determine (so, E
includes actions that the agent is able to perform), according to the specific agent-oriented
framework.
      </p>
      <p>Let H be the history of an agent as recorded by the agent itself (in a form that
will depend upon the specific agent-oriented framework), i.e., H includes agent’s
perceptions and memories. For instance, in DALI the history consists of: the set Ev of
external and internal events, that represent respectively events that the agent presently
perceives of its environment, and events that the agent has raised by its own internal
reasoning processes; the set Act of the actions that the agent is enabled to perform at
its present stage of operation; the set P of most recent versions “past events”, which
include: previously perceived events, but also actions that the agent has performed
(notice that elements of Ev and Act will be transferred into P at the next stage); the set
P N V of previous instances of past events (e.g., P may contain the last measurements
of temperature while P N V may contain older ones), plus past constraints that specify
interaction between P and P N V .</p>
      <p>We assume that program PA as written by the programmer is in general transformed
into an initial agent program P0 by means of an initialization step. When agent A
is activated P0 will go into execution, and will evolve according to events that either
happen or are generated internally, to actions which are performed, etc., i.e., according
to the evolution of H.</p>
      <p>Evolution in this setting is represented via program-transformation steps, each one
transforming Pi into Pi+1 according to Hi, which is the partial history up to stage i.
The choice of which elements of Hi do actually trigger an evolution step is part of the
definition of a specific agent framework.</p>
      <p>Thus, we obtain a Program Evolution Sequence P E = [P0, . . . , Pn, . . .]. The
program evolution sequence will imply a corresponding Semantic Evolution Sequence
M E = [M0, . . . , Mn, . . .] where Mi is the semantics of Pi according to L. Notice
in fact that the approach is parametric w.r.t L.</p>
      <p>Definition 1 (Evolutionary semantics). Let Ag be an agent. The evolutionary
semantics " Ag of Ag is a tuple hH, P E, M Ei, where H is the history of Ag , and P E and
M E are respectively its program and semantic evolution sequences.</p>
      <p>The next definition introduces the notion of instant view of " Ag, at a certain stage
of the evolution (which is in principle of unlimited length).</p>
      <p>Definition 2 (Evolutionary semantics snapshot). Let Ag be an agent, with
evolutionary semantics " Ag = hH, P E, M Ei. The snapshot at stage i of " iAg is the tuple
hHi, Pi, Mii, where Hi is the history up to the events that have determined the
transition from Pi 1 to Pi.</p>
      <p>
        In [
        <xref ref-type="bibr" rid="ref7">7</xref>
        ], program transformation steps associated with DALI language constructs are
defined in detail. They can easily be adapted to AgentSpeak [
        <xref ref-type="bibr" rid="ref8 ref9">8, 9</xref>
        ] as the two languages
share a number of similarities. More generally however, in the specific agent setting
under consideration an evolution step will occur at least whenever new events are
perceived, reacted to, and recorded, and whenever an agent proactively undertakes
measures to pursue its goals. An evolution step will possibly determine an update of the
history, which is a part of the agent’s belief base1. Thus, each evolution step affects
the belief or “mental” state of an agent. The evolutionary semantics may express for
instance the notion of trace of a GOAL agent [
        <xref ref-type="bibr" rid="ref13 ref14">13, 14</xref>
        ] where agent program Pi
encompasses the agent’s mental state and each evolution step, which in GOAL is called
computation step is determined by a conditional action. For 3APL [
        <xref ref-type="bibr" rid="ref15 ref16">15, 16</xref>
        ], agent
program Pi encompasses the agent’s initial configuration, and the related sets GR of goal
rules, PR of plan rules, IR of interactive rules; the evolutionary semantics corresponds
to a 3APL agent computation run, and evolution steps are determined by the 3APL
transition system.
      </p>
      <p>
        The semantics presented in [
        <xref ref-type="bibr" rid="ref17">17</xref>
        ] for Reactive Answer Set Programming, based upon
“incremental logic programs” and “online progression”, brings some conceptual
similarity with the (pre-existing) Evolutionary Semantics.
1 Equivalently, according to the specific agent framework with its own terminology, one may
talk of an agent’s knowledge base
3
      </p>
      <p>
        A-ILTL
For defining properties that are supposed to be respected by an evolving system, a
wellestablished approach is that of Temporal Logic, and in particular of Linear-time
Temporal Logics (LTL, cf., e.g., [
        <xref ref-type="bibr" rid="ref18">18</xref>
        ]). These logics are called ‘linear’ because (in contrast
to ‘branching time’ logics) they evaluate each formula with respect to a vertex-labeled
infinite path (or “state sequence”) s0s1 . . . where each vertex si in the path corresponds
to a point in time (or “time instant” or “state”). In what follows, we use the standard
notation for the best-known LTL operators.
      </p>
      <p>
        An interval-based extension to the well-known linear temporal logic LTL is formally
introduced in [
        <xref ref-type="bibr" rid="ref19">19</xref>
        ] where it is called A-ILTL for ‘Agent-Oriented Interval LTL’. Though,
as discussed in [
        <xref ref-type="bibr" rid="ref19">19</xref>
        ], several “metric” and interval temporal logic exist, the introduction
of A-ILTL is useful in the agent realm because the underlying discrete linear model
of time and the complexity of the logic remains unchanged with respect to LTL. This
simple formulation can thus be efficiently implemented, and is nevertheless sufficient
for expressing and checking a number of interesting properties of agent systems.
      </p>
      <p>
        Formal syntax and semantics of A-ILTL operators (also called below “Interval
Operators”) are fully defined in [
        <xref ref-type="bibr" rid="ref19">19</xref>
        ]. A-ILTL expressions are (like plain LTL ones)
interpreted in a discrete, linear model of time. Formally, this structure is represented by
M = hN, Ii where, given countable set ⌃ of atomic propositions, interpretation
function I : N 7! 2⌃ maps each natural number i (representing state si) to a subset of ⌃ .
Given set F of formulas built out of classical connectives and of LTL and A-ILTL
operators (where however nesting of A-ILTL operators is not allowed), the semantics of a
temporal formula is provided by a satisfaction relation: for ' 2 F and i 2 N we write
M, i |= ' if, in the satisfaction relation, ' is true w.r.t. M, i. We can also say (leaving
M implicit) that ' holds at i, or equivalently in state si, or that state si satisfies ' . A
structure M = hN, Ii is a model of ' if M, i |= ' for some i 2 N.
      </p>
      <p>Some among the A-ILTL operators are the following.</p>
      <p>Definition 3. Let ' 2 F and let m, n be positive integer numbers.</p>
      <p>Fm,n (eventually (or “finally”) in time interval). Fm,n' states that ' has to hold
sometime on the path from state sm to state sn. I.e., M, i |= Fm,n' if there exists j such
that j m and j  n and M, j |= ' . Can be customized into Fm, bounded
eventually (or “finally”), where ' should become true somewhere on the path from the current
state to the (m)-th state after the current one.</p>
      <p>Gm,n (always in time interval). Gm,n' states that ' should become true at most at
state sm and then hold at least until state sn. I.e., M, i |= Gm,n' if for all j such that
j m and j  n M, j |= ' . Can be customized into Gm, bounded always, where '
should become true at most at state sm.</p>
      <p>Nm,n (never in time interval). Nm,n' states that ' should not be true in any state
between sm and sn, i.e., M, i |= Nm,n' if there not exists j such that j m and
j  n and M, j |= ' .
4</p>
      <p>
        A-ILTL and Evolutionary Semantics
In this section, we refine A-ILTL so as to operate on a sequence of states that
corresponds to the Evolutionary Semantics defined before. In fact, states in our case are not
simply intended as time instants. Rather, they correspond to stages of the agent
evolution. Time in this setting is considered to be local to the agent, where with some sort of
“internal clock” is able to time-stamp events and state changes. We borrow from [
        <xref ref-type="bibr" rid="ref20">20</xref>
        ]
the following definition of timed state sequence, that we tailor to our setting.
Definition 4. Let be a (finite or infinite) sequence of states, where the ith state ei, ei
0, is the semantic snapshots at stage i "iAg of given agent Ag . Let T be a corresponding
sequence of time instants ti, ti 0. A timed state sequence for agent Ag is the couple
⇢ Ag = (, T ). Let ⇢ i be the i-th state, i 0, where ⇢ i = hei, tii = h"iAg , tii.
      </p>
      <p>We in particular consider timed state sequences which are monotonic, i.e., if ei+1 6=
ei then ti+1 &gt; ti. In our setting, it will always be the case that ei+1 6= ei as there is no
point in semantically considering a static situation: as mentioned, a transition from ei
to ei+1 will in fact occur when something happens, externally or internally, that affects
the agent.</p>
      <p>
        Then, in the above definition of A-ILTL operators, it is immediate to let si = ⇢ i.
This requires however a refinement: in fact, in a writing Opm or Opm,n occurring in an
agent program parameters m and n will not necessarily coincide with time instants of
the above-defined timed state sequence. To fill this gap, in [
        <xref ref-type="bibr" rid="ref19">19</xref>
        ] a suitable approximation
is introduced.
      </p>
      <p>We need to adapt the interpretation function I of LTL to our setting. In fact, we
intend to employ A-ILTL within agent-oriented languages, where we restrict ourselves
to logic-based languages for which an evolutionary semantics and a notion of logical
consequence can be defined. Thus, given agent-oriented language L at hand, the set
⌃ of propositional letters used to define an A-ILTL semantic framework will coincide
with all ground expressions of L (an expression is ground if it contains no variables,
and each expression of L has a possibly infinite number of ground versions). A given
agent program can be taken as standing for its (possibly infinite) ground version, as
it is customarily done in many approaches. Notice that we have to distinguish between
logical consequence in L, that we indicate as |=L, from logical consequence in A-ILTL,
indicated above simply as |=. However, the correspondence between the two notions
can be quite simply stated by specifying that in each state si the propositional letters
implied by the interpretation function I correspond to the logical consequences of agent
program Pi:
Definition 5. Let L be a logic language. Let Expr L be the set of ground expressions
that can be built from the alphabet of L. Let ⇢ Ag be a timed state sequence for agent Ag ,
and let ⇢ i = h"iAg , tii be the ith state, with "iAg = hHi, Pi, Mii. An A-ILTL formula ⌧
is defined over sequence ⇢ Ag if in its interpretation structure M = hN, Ii, index i 2 N
refers to ⇢ i, which means that ⌃ = Expr L and I : N 7! 2⌃ is defined such that, given
p 2 ⌃ , p 2 I (i) iff Pi |=L p. Such an interpretation structure will be indicated with
MAg . We will thus say that ⌧ holds/does not hold w.r.t. ⇢ Ag .</p>
      <p>A-ILTL properties will be verified at run-time, and thus they act as constraints over
the agent behavior2. In an implementation, verification may not occur at every state
(of the given interval). Rather, sometimes properties need to be verified with a certain
frequency, that can be specifically tuned to the various cases. Then, we have introduced
a further extension that consists in defining subsequences of the sequence of all states: if
Op is any of the operators introduced in A-ILTL and k &gt; 1, Opk is a semantic variation
of Op where the sequence of states ⇢ Ag of given agent is replaced by the subsequence
s0, sk1 , sk2 , . . . where for each kr, r 1, kr mod k = 0, i.e., kr = g ⇥ k for some
g 1.</p>
      <p>A-ILTL formulas to be associated to given agent can be defined within the agent
program, though they constitute an additional but separate layer, composed of formulas
{⌧ 1, . . . , ⌧ l}. Agent evolution can be considered to be “satisfactory” if it obeys all these
properties.</p>
      <p>Definition 6. Given agent Ag and given a set of A-ILTL expressions A = {⌧ 1, . . . , ⌧ l},
timed state sequence ⇢ Ag is coherent w.r.t. A if A-ILTL formula G⇣ with ⇣ = ⌧ 1^ . . .^ ⌧ n
holds.</p>
      <p>
        Notice that the expression G⇣ is an invariance property in the sense of [
        <xref ref-type="bibr" rid="ref21">21</xref>
        ]. In fact,
coherence requires this property to hold for the whole agent’s “life”. In the formulation
Gm,n⇣ that A-ILTL allows for, one can express temporally limited coherence,
concerning for instance “critical” parts of an agent’s operation. Or also, one might express forms
of partial coherence concerning only some properties.
      </p>
      <p>An “ideal” agent will have a coherent evolution, whatever its interactions with the
environment can be, i.e., whatever sequence of events arrives to the agent from the
external “world”. However, in practical situations such a favorable case will seldom be
the case, unless static verification has been able to ensure total correctness of agent’s
behavior. Instead, violations will occasionally occur, and actions should be undertaken
so as to attempt to regain coherence for the future.</p>
      <p>
        A-ILTL rules may imply asserting and retracting rules or sets of object rules
(“modules”). In this setting, assert and retract can be considered as special A-ILTL operators,
for which a formal semantics is provided (cf. [
        <xref ref-type="bibr" rid="ref19">19</xref>
        ]).
5
      </p>
      <p>
        A-ILTL for Monitoring Liveness and Safety Properties
In this section we illustrate the usefulness of A-ILTL constraints for defining and
verifying liveness and safety properties in agent systems. In software engineering, liveness
properties concern the progress that an agent makes and express that a (good) state
eventually will be reached, while safety properties express that some (bad) state will never
be entered. This implies that liveness is concerned with the evolution of a system, while
in general safety is not: notice in fact that, paradoxically, doing nothing prevents bad
states from being reached. Notice however that in our setting we restricted ourselves to
monotonic state sequences based upon the evolutionary semantics, so that our agents
evolve by definition. Notice that, if violated, liveness properties are violated in infinite
2 By abuse of notation we will indifferently talk about A-ILTL rules, expressions, or constraints.
time (a good state not yet reached might be in principle reached in the future) while
safety properties are violated in finite time, in case a “bad” state is reached. It is widely
acknowledged (cf., e.g., [
        <xref ref-type="bibr" rid="ref22">22</xref>
        ]) that any property can be expressed as a conjunction of a
safety and a liveness property. In agents, “bounded” liveness is often more interesting
than “pure” liveness: in fact, sometimes it does not suffice that a certain state might
be reached in an indefinite future, as agents are situated real-time working entities that
operate with limited computational resources and within deadlines. Bounded liveness
properties are equivalent to safety properties that are violated whenever the desirable
state is not reach withing the deadline. However, expressing such properties in the form
of liveness properties is often more intuitive. A-ILTL operators can be defined either
on finite intervals and then, to any practical extent, they define safety properties, or to
infinite intervals (with no upper bound) thus defining liveness properties.
      </p>
      <p>We employ in the examples a pragmatic form for A-ILTL expressions related to
logic agent-oriented languages. In particular, we represent an A-ILTL expression in the
form OP (m, n; k ) ' where: m, n define the time interval where (or since when, if n
is omitted) expression OP ' is required to hold, and k (optional) is the frequency (in
terms of states, or time instants) for checking whether the expression actually holds.</p>
      <p>For instance, EVENTUALLY (m, n; k ) ' states that ' should become true at some
point between time instants (states) m and n.</p>
      <p>In rule-based logic programming languages, we may reasonably restrict ' to be
a conjunction of literals. In pragmatic A-ILTL formulas, ' must be ground when the
formula is checked. In fact, we allow variables to occur in an A-ILTL formula, to be
instantiated via a context (we then talk about contextual A-ILTL formulas). Notice
that, for the evaluation of ' and , we rely upon the procedural semantics of the ‘host’
language.</p>
      <p>
        In the following, a contextual A-ILTL formula ⌧ will implicitly stand for the ground
A-ILTL formula obtained via evaluating the context. In [
        <xref ref-type="bibr" rid="ref19">19</xref>
        ] it is specified how to
operationally check whether such a formula holds. This by observing that A-ILTL operators
defined over finite intervals there is a crucial state where it is definitely possible to
assess whether a related formula holds or not in given state sequence, by observing the
sequence up to that point and ignoring the rest.
      </p>
      <p>
        In runtime self-checking, as discussed above, an issue of particular importance in
case of violation of a property is that of undertaking suitable measures in order to
recover or at least mitigate the critical situation. Actions to be undertaken in such
circumstances can be seen as an internal reaction to criticalities. More effective reaction
can be defined if complex reactive features are available in the underlying language.
In non-trivial cases, the issue of runtime recovery has a significant intersection (that
had not been identified so far) with “Complex Event Processing” (CEP), which is an
emergent relevant new field of software engineering and computer science [
        <xref ref-type="bibr" rid="ref23">23</xref>
        ]. In fact,
a lot of practical applications have the need to actively monitor vast quantities of event
data to make automated decisions and take time-critical actions [
        <xref ref-type="bibr" rid="ref24 ref25 ref26 ref27">24–27</xref>
        ] (cf. also the
Proceedings of the RuleML Workshop Series). Many of the current approaches to CEP
are declarative and based on rules, and often on logic-programming-like languages and
semantics: for instance, [
        <xref ref-type="bibr" rid="ref24">24</xref>
        ] is based upon a specifically defined interval-based Event
Calculus [
        <xref ref-type="bibr" rid="ref28">28</xref>
        ]. In logical agents, [
        <xref ref-type="bibr" rid="ref29 ref30 ref31">29–31</xref>
        ] tackled the issue of complex reactivity, by
considering the possibility of choosing among different possible reactive patterns also
by means of complex preferences. In the present paper, we show by means of examples
how kinds of A-ILTL constraints exploiting complex reactivity can be useful in runtime
recovery. For lack of space reactive patterns will be discussed informally in relation to
examples.
      </p>
      <p>Below is the general form of an A-ILTL constraint with a reactive component that
we call recovery pattern.</p>
      <p>Definition 7. A reactive A-ILTL rule is of the form (where M, N, K can be either
variables or constants)</p>
      <p>OP (M , N ; K )' :: ÷ ⇢
where:(i) OP (M , N ; K )' :: is a contextual A-ILTL formula, called the monitoring
condition, that should involve the observation of either external or internal events; (ii)
⇢ is called the recovery component of the rule, and it consists of a complex reactive
pattern.</p>
      <p>Whenever the monitoring condition (automatically checked at frequency K) is
violated (i.e., it does not hold) within given interval, then the recovery component ⇢ is
executed. Syntax and semantics of reactive patterns usable in the recovery component
will depend upon the underlying language L. In the examples, we adopt a sample syntax
suitable for logic-programming-based settings.</p>
      <p>
        Consider for instance the example of a controller agent that has to keep the
temperature in a certain time frame (say between 8 a.m. and 5 p.m.) in the range 19–21
(Celsius degrees). In this case, the measure temperature of temperature implies
sensing actions to be performed with a sampling period by the agent. If the condition is
violated, a reaction should try to restore the wished-for situation. We assume in fact to
be in a smart building, where the temperature is monitored by intelligent agents, and
where each agent tries to select, in order to modify the temperature, the best suitable
energy source: for instance, according to present circumstances, an agent might select
the less expensive font of energy or, in case of a measure significantly different from
wished-for values, the font which guarantees the most efficient correction. Notice that
in the course of time different fonts of energy can be deemed to be the best choice. At
each check (where in fact the A-ILTL constraints is dynamically checked at the
specified frequency, or at a default frequency in case none is provided) we assume that the
best choice can determined by means of an application-dependent decision procedure.
So, in given interval, the monitoring condition will sometimes succeed (the temperature
is within range, then nothing is done) and will sometimes fail. In the latter case, the font
of energy S which is deemed more effective (in terms of cost and/or efficiency) in that
moment is determined, and used in order to suitably affect the temperature and try to
keep it within the specified range (where modify temperatureG (S ) is a goal,
involving appropriate actions). In A-ILTL, this can be formalized as follows by exploiting
complex preferences introduced in [
        <xref ref-type="bibr" rid="ref32">32</xref>
        ]. As there are no variables, context is omitted.
      </p>
      <p>ALWAYS (8 : 00 a.m., 5 : 00 p.m.; 10m) 19  temperature  21 ÷
modify temperatureG (S ),
S IN {external electricity , gas, solar panel electricity : most e↵ective }</p>
      <p>
        The next example is a meta-statement expressing the capability of an agent to
modify its own behavior. In case a goal G has not been achieved (in a certain context)
because the allotted time has elapsed, then the recovery component implies replacing
the planning module (assuming that more than one is available) and retrying the goal.
We suppose that the possibility of achieving a goal G is evaluated w.r.t. a module M that
represents the context for G (notation P (G, M ), P standing for ’possible’). Necessity
and possibility evaluation within a reasonably complex framework has been discussed
in [
        <xref ref-type="bibr" rid="ref30">30</xref>
        ]. In case the goal is still deemed to be possible but has not been achieved before
a certain deadline, the reaction consists in substituting the present planning module and
re-trying the goal.
      </p>
      <p>NEVER goal (G ),
eval context (G , M ), P (G , M ), timed out (G ), not achieved (G )÷</p>
      <p>replace planning module, retry (G )</p>
      <p>
        It can be useful to define properties to be checked upon arrival of event sequences,
of which however only relevant events (and their order) should be considered. To this
aim we introduce a new kind of A-ILTL constraints, that we call Evolutionary A-ILTL
Expressions. To define partially known sequences of any length, on the line of dynamic
logic [
        <xref ref-type="bibr" rid="ref33">33</xref>
        ] we admit for event sequences a syntax reminiscent of regular expressions
so as to specify irrelevant/unknown events, and repetitions. In particular, event
expressions (and, analogously, action expressions) may be primitive events e, sequences of
event expressions e1 ; e2 , . . ., zero or more iterations of an event expression e⇤ , or a
choice among event expressions e1 + e2 + . . .. We also admit “wild cards”, i.e.,
variables (starting with uppercase) to stand for unknown events/actions.
      </p>
      <p>Definition 8 (Evolutionary A-LTL Expressions). Let SEvp be a sequence of past
events, and SF and J J be sequences of events. Let ⌧ be a contextual A-ILTL formula
Op ' :: . An Evolutionary LTL Expression $ is of the form SEvp : ⌧ ::: SF ::::
J J where: (i) SEvp denotes the sequence of relevant events which are supposed to
have happened, and in which order, for the rule to be checked; i.e., these events act as
preconditions: whenever one or more of them happen in given order, ⌧ will be checked;
(ii) SF denotes the events that are expected to happen in the future without affecting ⌧ ;
(iii) J J denotes the events that are expected not to happen in the future; i.e., whenever
any of them should happen, ' is not required to hold any longer, as these are “breaking
events”.</p>
      <p>An Evolutionary LTL Expression can be evaluated w.r.t. a state si which includes
among its components the history of the agent, i.e., the list of past events perceived by
the agent. A history H satisfies an event sequence S whenever all events in S occur in
H, in the order specified by S itself.</p>
      <p>Definition 9. An Evolutionary A-ILTL Expression $, of the form specified in
Definition 8: (1) holds in state si whenever (i) history Hi satisfies SEvp and SF and does not
include any event in J J , and ⌧ holds or (ii) Hi includes any event occurring in J J
(the expression is broken); (2) is violated in state si whenever Hi satisfies SEvp and
SF and does not include any event in J J , and ⌧ does not hold.</p>
      <p>Operationally, an Evolutionary A-ILTL Expression can be finally deemed to hold if
either the critical state has been reached and ⌧ holds, or an unwanted event has occurred.
Instead, an expression can be deemed not to hold (or, as we say, to be violated as far
as it expresses a wished-for property) whenever ⌧ is false at some point without the
occurrence of breaking events.</p>
      <p>The following is an example of Evolutionary A-ILTL Expression that might occur
in an agent program installed on an autonomous robot working on batteries, and able
to check its own charge level. The robot moves in some environment to perform some
task. The following A-ILTL axiom states that after a battery recharge (indicated as a
past event, postfix ’P ’) at time T , the charge level should be sufficient for 6 hours
despite a sequence of actions which can be considered to be ’normal’ in relation to the
robot’s task. These actions may for instance involve moving around, cleaning rubbish,
delivering packages, etc. Instead, the charge level can be expected to be low in case of
extensive usage actions, for instance in case of an exceptional unexpected event that
requires the robot to increase its activities (e.g., drying water in case of a flooding from
a broken pipe). There is a classification of what should be intended by ’normal’ and
’extensive’ usage.</p>
      <p>recharge batteryP : T :</p>
      <p>ALWAYS (T, T + 6hour) charge level(L), L &gt; low
::: normal usage action(Act )⇤ :::: extensive usage action(Act )⇤</p>
      <p>The above expression should be combined with another A-ILTL expression
forcing recharge every six hours. The latter should state that if the last battery recharge
recharge batteryP has occurred at time T which is more than six hours different from
present time now , then as a recovery the goal recharge batteryG must be set. Achieving
this goal may require, for instance, reaching the nearest recharge station. Notice that,
in this case, we have used an A-ILTL constraint as a programming construct, which
however has a role in terms of assurance since it forces the agent to respect a timing
which is essential for the system good functioning.</p>
      <p>ALWAYS
recharge batteryP : T , now</p>
      <p>T &gt; 6hour ÷ recharge batteryG</p>
      <p>Whenever an Evolutionary A-ILTL expression is either violated or broken, a
reaction can be attempted aiming at recovering a desirable or at least acceptable agent’s
state.</p>
      <p>Definition 10. An evolutionary LTL expression with repair $r is of the form $|⌘ 1||⌘ 2
where $ is an Evolutionary LTL Expression adopted in language L, and ⌘ 1, ⌘ 2 are
atoms of L. ⌘ 1 will be executed (according to L’s procedural semantics) whenever
$ is violated, and ⌘ 2 will be executed whenever $ is broken. ⌘ 1 and ⌘ 2 are called
countermeasures.</p>
      <p>In previous example, whenever the robot detects a low level of charge,
countermeasure ⌘ 1, taken in case of low battery under normal usage, may for instance imply alerting
the user, as a fault either in the battery or in the recharge station can be hypothesized.
Instead ⌘ 2, taken in case of low battery under exceptional usage, will simply imply the
robot to resort to the recharge station. The overall expression will take the form:
recharge batteryP : T :</p>
      <p>ALWAYS (T, T + 6hour) charge level(L), L &gt; low
| alert user possible faultA || recharge batteryG
6</p>
    </sec>
    <sec id="sec-2">
      <title>Complexity of Check and Discussion</title>
      <p>In this section we synthetically analyze the complexity of checking A-ILTL expressions.
For lack of space, we cannot provide a detailed account. We make the simplifying
assumption that all expressions are checked at the same frequency: i.e., the agent devotes
with a certain periodicity some amount time to perform the check. Here we evaluate
this amount. Let us assume to have f A-ILTL expressions, and that the time for
retrieving each expression from the computer memory is m. Thus, retrieving all expressions
to be evaluated is O(f ? m). Let k be the number of the different A-ILTL operator
occurring in the f expressions. Let if eval be the time needed in order to understand
whether each expression needs to be evaluated at the present state: this includes
checking w.r.t. the crucial state and, in case of Evolutionary A-ILTL Expressions, checking
the event sequence SEvp w.r.t. current agent’s history. Let max eval be the maximum
time needed for the evaluation of each contextual A-ILTL formula Op ' :: . Let
if viol or broken be the maximum time needed to state whether each Evolutionary
A-ILTL Expressions is either violated or broken: this implies checking event sequences
SF and J J w.r.t. current agent’s history.</p>
      <p>Therefore, the total time to be spent for checking all A-ILTL Expression (in the
worst case, where all of them are of the Evolutionary kind, and each of them needs to
be evaluated at the present state) can be estimated to:</p>
      <p>O((f ? m) + (f ? (if eval + max eval + if viol or broken)))</p>
      <p>Then, for each expression which is either violated or broken, there will be a time
spent in the recovery and countermeasure actions.</p>
      <p>The relatively low complexity of check (which however requires to keep the number
of A-ILTL expressions as low as possible, and to tune frequency carefully, according
to the environment change rate) is due to the definition of A-ILTL in relation to the
Evolutionary semantics: in fact, it is not needed to implement a temporal logic inference
engine, rather to periodically check Op ' :: . This in the case of simple non-nested
A-ILTL expressions. Introducing more complex expressions is a subject of future work.
7</p>
    </sec>
    <sec id="sec-3">
      <title>Related Work and Concluding Remarks</title>
      <p>
        In this paper, we have proposed A-ILTL runtime constraints for agents’ self-checking
and monitoring. We have shown how to express via these constraints a number of useful
liveness and safety properties. We have provided a semantic framework general enough
for accommodating a number of agent-oriented languages, so as to allow A-ILTL
constraints to be adopted in different settings. This work has been influenced by [
        <xref ref-type="bibr" rid="ref19 ref34 ref35 ref36">34, 19,
35, 36</xref>
        ].
      </p>
      <p>
        We may easily notice similarities between A-ILTL constraints and event-calculus
formulations [
        <xref ref-type="bibr" rid="ref28">28</xref>
        ]. Also, approaches based on abductive logic programming such as,
SCIFF (cf. [
        <xref ref-type="bibr" rid="ref37">37</xref>
        ] and the references therein) allow one to model dynamically upcoming
events, and specify positive and negative expectations, and the concepts of fulfillment
and violation of expectations. Reactive Event Calculus (REC) stems from SCIFF [
        <xref ref-type="bibr" rid="ref38">38</xref>
        ]
and adds more flexibility by reacting to new events by extending and revising previously
computed results. However, these approaches have been devised for static or dynamic
checking when performed by a third party. Event sequences, the concepts of violated
and broken expressions, complex reaction patterns, and independence of the underlying
logic are however distinguished features of the proposed approach.
      </p>
      <p>
        A well-established line of work concerning the use of temporal logic in order to
define run-time monitors is discussed in [
        <xref ref-type="bibr" rid="ref39">39</xref>
        ] and the references therein. However, this
work is not related to agents, and does not concern self-checking: in fact, they propose a
rule-based temporal language for defining “monitors” which examine either on-line or
off-line some kind of “observable trace” generated by the program under check. There
is no notion of recovery in case malfunctioning should be detected.
      </p>
      <p>
        The proposed approach has been experimented in the context of energy management
in smart buildings [
        <xref ref-type="bibr" rid="ref40">40</xref>
        ]. Such intelligent control is dynamic by nature, and must fulfill
real-time requirements: in fact, each building has its own dynamical thermo-physical
behavior and is immersed in a dynamic environment where weather events change its
energy footprint in function of time. The outcome of the experiments is encouraging,
in the sense that adopting agents equipped with the proposed features allows for not
only general but also local (room-by-room or area-by-area) control of energy saving
according to user comfort requirements and preferences.
      </p>
      <p>
        Future work includes refining A-ILTL constraints to adapt to different self-checking
issues and contexts. As suggested in [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ], a very interesting line of investigation concerns
automated synthesis of runtime constraints from specifications but also from test results,
extracting invariants expressing correct or critical situations.
      </p>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          1.
          <string-name>
            <surname>Winikoff</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          :
          <article-title>Assurance of agent systems: What role should formal verification play? (</article-title>
          <year>2010</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          2.
          <string-name>
            <surname>Rushby</surname>
            ,
            <given-names>J.M.:</given-names>
          </string-name>
          <article-title>Runtime certification</article-title>
          . In Leucker, M., ed.: Runtime Verification, 8th International Workshop,
          <string-name>
            <surname>RV</surname>
          </string-name>
          <year>2008</year>
          .
          <article-title>Selected Papers</article-title>
          . Volume
          <volume>5289</volume>
          of Lecture Notes in Computer Science. Springer (
          <year>2008</year>
          )
          <fpage>21</fpage>
          -
          <lpage>35</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          3.
          <string-name>
            <surname>Dastani</surname>
            ,
            <given-names>M.M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Hindriks</surname>
            ,
            <given-names>K.</given-names>
          </string-name>
          , Meyer, J.J.C., eds.
          <source>: Specification and Verification of Multiagent Systems</source>
          . Springer US (
          <year>2010</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          4.
          <string-name>
            <surname>Shapiro</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Lesprance</surname>
            ,
            <given-names>Y.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Levesque</surname>
          </string-name>
          , H.:
          <article-title>The cognitive agents specification language and verification environment (</article-title>
          <year>2010</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          5.
          <string-name>
            <surname>Ezekiel</surname>
            ,
            <given-names>J.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Lomuscio</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          :
          <article-title>Combining fault injection and model checking to verify fault tolerance in multi-agent systems</article-title>
          . In Sierra,
          <string-name>
            <given-names>C.</given-names>
            ,
            <surname>Castelfranchi</surname>
          </string-name>
          ,
          <string-name>
            <given-names>C.</given-names>
            ,
            <surname>Decker</surname>
          </string-name>
          ,
          <string-name>
            <given-names>K.S.</given-names>
            ,
            <surname>Sichman</surname>
          </string-name>
          , J.S., eds.
          <source>: 8th International Joint Conference on Autonomous Agents and Multiagent Systems (AAMAS</source>
          <year>2009</year>
          ), Proceedings, Volume
          <volume>1</volume>
          ,
          <string-name>
            <surname>IFAAMAS</surname>
          </string-name>
          (
          <year>2009</year>
          )
          <fpage>113</fpage>
          -
          <lpage>120</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          6.
          <string-name>
            <surname>Butner</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Ghodoussi</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          :
          <article-title>Transforming a surgical robot for human telesurgery</article-title>
          .
          <source>IEEE Transactions on Robotics and Automation</source>
          <volume>19</volume>
          (
          <issue>5</issue>
          ) (
          <year>2003</year>
          )
          <fpage>818</fpage>
          -
          <lpage>824</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref7">
        <mixed-citation>
          7.
          <string-name>
            <surname>Costantini</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Tocchio</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          :
          <article-title>About declarative semantics of logic-based agent languages</article-title>
          . In Baldoni,
          <string-name>
            <given-names>M.</given-names>
            ,
            <surname>Endriss</surname>
          </string-name>
          ,
          <string-name>
            <given-names>U.</given-names>
            ,
            <surname>Omicini</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            ,
            <surname>Torroni</surname>
          </string-name>
          , P., eds.: Declarative Agent Languages and
          <string-name>
            <surname>Technologies</surname>
            <given-names>III</given-names>
          </string-name>
          , Third International Workshop, DALT 2005,
          <article-title>Selected</article-title>
          and
          <string-name>
            <given-names>Revised</given-names>
            <surname>Papers</surname>
          </string-name>
          . Volume
          <volume>3904</volume>
          <source>of LNAI</source>
          . Springer (
          <year>2006</year>
          )
          <fpage>106</fpage>
          -
          <lpage>123</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref8">
        <mixed-citation>
          8.
          <string-name>
            <surname>Rao</surname>
            ,
            <given-names>A.S.</given-names>
          </string-name>
          : Agentspeak(l):
          <article-title>Bdi agents speak out in a logical computable language</article-title>
          . In de Velde,
          <string-name>
            <given-names>W.V.</given-names>
            ,
            <surname>Perram</surname>
          </string-name>
          , J.W., eds.:
          <source>Agents Breaking Away, 7th European Workshop on Modelling Autonomous Agents in a Multi-Agent World, Proceedings. Volume 1038 of Lecture Notes in Computer Science</source>
          ., Springer (
          <year>1996</year>
          )
          <fpage>42</fpage>
          -
          <lpage>55</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref9">
        <mixed-citation>
          9.
          <string-name>
            <surname>Bordini</surname>
            ,
            <given-names>R.H.</given-names>
          </string-name>
          , Hu¨ bner,
          <string-name>
            <surname>J.F.</surname>
          </string-name>
          :
          <article-title>Semantics for the jason variant of agentspeak (plan failure and some internal actions)</article-title>
          . In Coelho, H.,
          <string-name>
            <surname>Studer</surname>
            ,
            <given-names>R.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Wooldridge</surname>
          </string-name>
          , M., eds.
          <source>: ECAI 2010 - 19th European Conference on Artificial Intelligence, Proceedings. Volume 215 of Frontiers in Artificial Intelligence and Applications</source>
          ., IOS Press (
          <year>2010</year>
          )
          <fpage>635</fpage>
          -
          <lpage>640</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref10">
        <mixed-citation>
          10.
          <string-name>
            <surname>Costantini</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Tocchio</surname>
            ,
            <given-names>A.:</given-names>
          </string-name>
          <article-title>A logic programming language for multi-agent systems</article-title>
          .
          <source>In: Logics in Artificial Intelligence, Proc. of the 8th Europ. Conf.,JELIA 2002. LNAI 2424</source>
          , Springer-Verlag, Berlin (
          <year>2002</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref11">
        <mixed-citation>
          11.
          <string-name>
            <surname>Costantini</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Tocchio</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          :
          <article-title>The DALI logic programming agent-oriented language</article-title>
          .
          <source>In: Logics in Artificial Intelligence, Proc. of the 9th European Conference, Jelia 2004. LNAI 3229</source>
          , Springer-Verlag, Berlin (
          <year>2004</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref12">
        <mixed-citation>
          12.
          <string-name>
            <surname>Costantini</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>D'Alessandro</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Lanti</surname>
            ,
            <given-names>D.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Tocchio</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          , al.:
          <article-title>DALI web site, download of the interpreter (2012) Released: basic DALI features. For beta versions please ask the authors</article-title>
          .
        </mixed-citation>
      </ref>
      <ref id="ref13">
        <mixed-citation>
          13.
          <string-name>
            <surname>Hindriks</surname>
            ,
            <given-names>K.V.</given-names>
          </string-name>
          :
          <article-title>Programming rationalagents in goal</article-title>
          . In El Fallah Seghrouchni,
          <string-name>
            <given-names>A.</given-names>
            ,
            <surname>Dix</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            ,
            <surname>Dastani</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
            ,
            <surname>Bordini</surname>
          </string-name>
          , R.H., eds.:
          <string-name>
            <surname>Multi-Agent</surname>
            <given-names>Programming</given-names>
          </string-name>
          :. Springer US (
          <year>2009</year>
          )
          <fpage>119</fpage>
          -
          <lpage>157</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref14">
        <mixed-citation>
          14.
          <string-name>
            <surname>Hindriks</surname>
            ,
            <given-names>K.</given-names>
          </string-name>
          :
          <article-title>A verification logic for goal agents (</article-title>
          <year>2010</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref15">
        <mixed-citation>
          15.
          <string-name>
            <surname>Dastani</surname>
          </string-name>
          , M.,
          <string-name>
            <surname>van Riemsdijk</surname>
            ,
            <given-names>B.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Dignum</surname>
          </string-name>
          , F., Meyer, J.J.C.
          <article-title>: A programming language for cognitive agents goal directed 3apl</article-title>
          . In Dastani,
          <string-name>
            <given-names>M.</given-names>
            ,
            <surname>Dix</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            ,
            <surname>Fallah-Seghrouchni</surname>
          </string-name>
          , A.E., eds.: Programming
          <string-name>
            <surname>Multi-Agent</surname>
            <given-names>Systems</given-names>
          </string-name>
          , First International Workshop, PROMAS 2003,
          <string-name>
            <given-names>Selected</given-names>
            <surname>Revised</surname>
          </string-name>
          and
          <string-name>
            <given-names>Invited</given-names>
            <surname>Papers</surname>
          </string-name>
          . Volume
          <volume>3067</volume>
          of Lecture Notes in Computer Science., Springer (
          <year>2004</year>
          )
          <fpage>111</fpage>
          -
          <lpage>130</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref16">
        <mixed-citation>
          16.
          <string-name>
            <surname>Dastani</surname>
          </string-name>
          , M.,
          <string-name>
            <surname>van Riemsdijk</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          <article-title>B</article-title>
          ., Meyer,
          <string-name>
            <surname>J.J.C.</surname>
          </string-name>
          :
          <article-title>Programming multi-agent systems in 3apl</article-title>
          . In Bordini, R.H.,
          <string-name>
            <surname>Dastani</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Dix</surname>
            ,
            <given-names>J.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Fallah-Seghrouchni</surname>
          </string-name>
          , A.E., eds.:
          <string-name>
            <surname>Multi-Agent</surname>
            <given-names>Programming</given-names>
          </string-name>
          :
          <article-title>Languages, Platforms and Applications</article-title>
          . Volume
          <volume>15</volume>
          of
          <string-name>
            <surname>Multiagent</surname>
            <given-names>Systems</given-names>
          </string-name>
          ,
          <source>Artificial Societies, and Simulated Organizations</source>
          . Springer (
          <year>2005</year>
          )
          <fpage>39</fpage>
          -
          <lpage>67</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref17">
        <mixed-citation>
          17.
          <string-name>
            <surname>Gebser</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Grote</surname>
            ,
            <given-names>T.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Kaminski</surname>
            ,
            <given-names>R.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Schaub</surname>
            ,
            <given-names>T.</given-names>
          </string-name>
          :
          <article-title>Reactive answer set programming</article-title>
          . In Delgrande,
          <string-name>
            <given-names>J.P.</given-names>
            ,
            <surname>Faber</surname>
          </string-name>
          , W., eds.:
          <source>Logic Programming and Nonmonotonic Reasoning - 11th International Conference, LPNMR</source>
          <year>2011</year>
          ,
          <article-title>Proceedings</article-title>
          . Volume
          <volume>6645</volume>
          of Lecture Notes in Computer Science., Springer (
          <year>2011</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref18">
        <mixed-citation>
          18.
          <string-name>
            <surname>Emerson</surname>
            ,
            <given-names>E.A.</given-names>
          </string-name>
          :
          <article-title>Temporal and modal logic</article-title>
          . In van Leeuwen, J., ed.:
          <source>Handbook of Theoretical Computer Science</source>
          , vol. B. MIT Press (
          <year>1990</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref19">
        <mixed-citation>
          19.
          <string-name>
            <surname>Costantini</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          :
          <article-title>Self-checking logical agents</article-title>
          .
          <source>In: Proc. of LA-NMR 2012</source>
          . Volume
          <volume>911</volume>
          .,
          <source>CEUR Workshop Proceedings (CEUR-WS.org)</source>
          (
          <year>2012</year>
          )
          <article-title>Invited paper</article-title>
          .
        </mixed-citation>
      </ref>
      <ref id="ref20">
        <mixed-citation>
          20.
          <string-name>
            <surname>Henzinger</surname>
            ,
            <given-names>T.A.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Manna</surname>
            ,
            <given-names>Z.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Pnueli</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          :
          <article-title>Timed transition systems</article-title>
          . In de Bakker,
          <string-name>
            <given-names>J.W.</given-names>
            ,
            <surname>Huizing</surname>
          </string-name>
          ,
          <string-name>
            <given-names>C.</given-names>
            ,
            <surname>de Roever</surname>
          </string-name>
          ,
          <string-name>
            <given-names>W.P.</given-names>
            ,
            <surname>Rozenberg</surname>
          </string-name>
          , G., eds.:
          <article-title>Real-Time: Theory in Practice</article-title>
          , REX Workshop, Mook, The Netherlands, June 3-7,
          <year>1991</year>
          , Proceedings. Volume
          <volume>600</volume>
          of Lecture Notes in Computer Science., Springer (
          <year>1992</year>
          )
          <fpage>226</fpage>
          -
          <lpage>251</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref21">
        <mixed-citation>
          21.
          <string-name>
            <surname>Manna</surname>
            ,
            <given-names>Z.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Pnueli</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          :
          <article-title>Adequate proof principles for invariance and liveness properties of concurrent programs</article-title>
          .
          <source>Sci. Comput. Program</source>
          .
          <volume>4</volume>
          (
          <issue>3</issue>
          ) (
          <year>1984</year>
          )
          <fpage>257</fpage>
          -
          <lpage>289</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref22">
        <mixed-citation>
          22.
          <string-name>
            <surname>Dederichs</surname>
            ,
            <given-names>F.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Weber</surname>
            ,
            <given-names>R.</given-names>
          </string-name>
          :
          <article-title>Safety and liveness from a methodological point of view</article-title>
          .
          <source>Inf. Process. Lett</source>
          .
          <volume>36</volume>
          (
          <issue>1</issue>
          ) (
          <year>1990</year>
          )
          <fpage>25</fpage>
          -
          <lpage>30</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref23">
        <mixed-citation>
          23.
          <string-name>
            <surname>Chandy</surname>
            ,
            <given-names>M.K.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Etzion</surname>
            ,
            <given-names>O.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>von</surname>
            <given-names>Ammon</given-names>
          </string-name>
          , R.: 10201
          <string-name>
            <given-names>Executive</given-names>
            <surname>Summary and Manifesto - Event Processing</surname>
          </string-name>
          . In Chandy,
          <string-name>
            <given-names>K.M.</given-names>
            ,
            <surname>Etzion</surname>
          </string-name>
          ,
          <string-name>
            <given-names>O.</given-names>
            ,
            <surname>von</surname>
          </string-name>
          <string-name>
            <surname>Ammon</surname>
          </string-name>
          , R., eds.
          <source>: Event Processing. Number 10201 in Dagstuhl Seminar Proceedings</source>
          , Dagstuhl, Germany, Schloss Dagstuhl - Leibniz-Zentrum fuer Informatik, Germany (
          <year>2011</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref24">
        <mixed-citation>
          24.
          <string-name>
            <surname>Paschke</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Kozlenkov</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          :
          <article-title>Rule-based event processing and reaction rules</article-title>
          .
          <source>In: RuleML</source>
          . Volume
          <volume>5858</volume>
          of Lecture Notes in Computer Science., Springer (
          <year>2009</year>
          )
          <fpage>53</fpage>
          -
          <lpage>66</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref25">
        <mixed-citation>
          25.
          <string-name>
            <surname>Etzion</surname>
            ,
            <given-names>O.</given-names>
          </string-name>
          :
          <article-title>Event processing - past, present and future</article-title>
          .
          <source>Proceedings of the VLDB Endowment</source>
          ,
          <source>PVLDB Journal 3(2)</source>
          (
          <year>2010</year>
          )
          <fpage>1651</fpage>
          -
          <lpage>1652</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref26">
        <mixed-citation>
          26.
          <string-name>
            <surname>Paschke</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Vincent</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          , Springer, F.:
          <article-title>Standards for complex event processing and reaction rules</article-title>
          . In
          <string-name>
            <surname>Olken</surname>
          </string-name>
          , F.,
          <string-name>
            <surname>Palmirani</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Sottara</surname>
          </string-name>
          , D., eds.:
          <source>RuleML America</source>
          . Volume
          <volume>7018</volume>
          of Lecture Notes in Computer Science., Springer (
          <year>2011</year>
          )
          <fpage>128</fpage>
          -
          <lpage>139</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref27">
        <mixed-citation>
          27.
          <string-name>
            <surname>Vincent</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          :
          <article-title>Event-driven rules: Experiences in cep</article-title>
          . In Olken, F.,
          <string-name>
            <surname>Palmirani</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Sottara</surname>
          </string-name>
          , D., eds.:
          <source>RuleML America</source>
          . Volume
          <volume>7018</volume>
          of Lecture Notes in Computer Science., Springer (
          <year>2011</year>
          )
          <fpage>11</fpage>
        </mixed-citation>
      </ref>
      <ref id="ref28">
        <mixed-citation>
          28.
          <string-name>
            <surname>Kowalski</surname>
            ,
            <given-names>R.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Sergot</surname>
            ,
            <given-names>M.:</given-names>
          </string-name>
          <article-title>A logic-based calculus of events</article-title>
          .
          <source>New Generation Computing</source>
          <volume>4</volume>
          (
          <year>1986</year>
          )
          <fpage>67</fpage>
          -
          <lpage>95</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref29">
        <mixed-citation>
          29.
          <string-name>
            <surname>Costantini</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Dell'Acqua</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Tocchio</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          :
          <article-title>Expressing preferences declaratively in logicbased agent languages</article-title>
          .
          <source>In: Proc. of Commonsense'07, the 8th International Symposium on Logical Formalizations of Commonsense Reasoning</source>
          , AAAI Press (
          <year>2007</year>
          )
          <article-title>Event in honor of the 80th birthday of John McCarthy</article-title>
          .
        </mixed-citation>
      </ref>
      <ref id="ref30">
        <mixed-citation>
          30.
          <string-name>
            <surname>Costantini</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          :
          <article-title>Answer set modules for logical agents</article-title>
          . In de Moor,
          <string-name>
            <given-names>O.</given-names>
            ,
            <surname>Gottlob</surname>
          </string-name>
          ,
          <string-name>
            <given-names>G.</given-names>
            ,
            <surname>Furche</surname>
          </string-name>
          ,
          <string-name>
            <given-names>T.</given-names>
            ,
            <surname>Sellers</surname>
          </string-name>
          , A., eds.: Datalog Reloaded: First International Workshop,
          <year>Datalog 2010</year>
          . Volume 6702 of LNCS. Springer (
          <year>2011</year>
          )
          <article-title>Revised selected papers</article-title>
          .
        </mixed-citation>
      </ref>
      <ref id="ref31">
        <mixed-citation>
          31.
          <string-name>
            <surname>Costantini</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>De Gasperis</surname>
          </string-name>
          , G.:
          <article-title>Complex reactivity with preferences in rule-based agents</article-title>
          . In Bikakis,
          <string-name>
            <given-names>A.</given-names>
            ,
            <surname>Giurca</surname>
          </string-name>
          , A., eds.
          <source>: Rules on the Web: Research and Applications</source>
          , RuleML 2012 - Europe, Montpellier, France,
          <source>August 27-29</source>
          ,
          <year>2012</year>
          . Proceedings. Volume
          <volume>6826</volume>
          of Lecture Notes in Computer Science., Springer (
          <year>2012</year>
          )
          <fpage>167</fpage>
          -
          <lpage>181</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref32">
        <mixed-citation>
          32.
          <string-name>
            <surname>Costantini</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Formisano</surname>
            ,
            <given-names>A.</given-names>
          </string-name>
          :
          <article-title>Modeling preferences and conditional preferences on resource consumption and production in asp</article-title>
          .
          <source>J. Algorithms</source>
          <volume>64</volume>
          (
          <issue>1</issue>
          ) (
          <year>2009</year>
          )
          <fpage>3</fpage>
          -
          <lpage>15</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref33">
        <mixed-citation>
          33.
          <string-name>
            <surname>Pratt</surname>
            ,
            <given-names>V.R.</given-names>
          </string-name>
          :
          <article-title>Semantical considerations on floyd-hoare logic</article-title>
          .
          <source>In: 17th Annual IEEE Symposium on Foundations of Computer Science, Proceedings, IEEE Computer Society</source>
          (
          <year>1976</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref34">
        <mixed-citation>
          34.
          <string-name>
            <surname>Costantini</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Dell'Acqua</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Pereira</surname>
            ,
            <given-names>L.M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Tsintza</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          :
          <article-title>Runtime verification of agent properties</article-title>
          .
          <source>In: Proc. of the Int. Conf. on Applications of Declarative Programming and Knowledge Management (INAP09)</source>
          . (
          <year>2009</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref35">
        <mixed-citation>
          35.
          <string-name>
            <surname>Costantini</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          :
          <article-title>Self-checking logical agents</article-title>
          . In Gini,
          <string-name>
            <given-names>M.L.</given-names>
            ,
            <surname>Shehory</surname>
          </string-name>
          ,
          <string-name>
            <given-names>O.</given-names>
            ,
            <surname>Ito</surname>
          </string-name>
          ,
          <string-name>
            <given-names>T.</given-names>
            ,
            <surname>Jonker</surname>
          </string-name>
          , C.M., eds.: International conference on Autonomous Agents and
          <string-name>
            <surname>Multi-Agent</surname>
            <given-names>Systems</given-names>
          </string-name>
          , AAMAS '
          <fpage>13</fpage>
          ,
          <string-name>
            <surname>Proceedings</surname>
          </string-name>
          , IFAAMAS (
          <year>2013</year>
          )
          <fpage>1329</fpage>
          -
          <lpage>1330</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref36">
        <mixed-citation>
          36.
          <string-name>
            <surname>Costantini</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Gasperis</surname>
          </string-name>
          , G.D.:
          <article-title>Meta-level constraints for complex event processing in logical agents</article-title>
          .
          <source>In: Informal Proc. of Commonsense</source>
          <year>2013</year>
          ,
          <source>11th International Symposium on Logical Formalizations of Commonsense Reasoning</source>
          . (
          <year>2013</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref37">
        <mixed-citation>
          37.
          <string-name>
            <surname>Montali</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Chesani</surname>
            ,
            <given-names>F.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Mello</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Torroni</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          :
          <article-title>Modeling and verifying business processes and choreographies through the abductive proof procedure sciff and its extensions</article-title>
          .
          <source>Intelligenza Artificiale, Intl. J. of the Italian Association AI*IA</source>
          <volume>5</volume>
          (
          <issue>1</issue>
          ) (
          <year>2011</year>
          )
        </mixed-citation>
      </ref>
      <ref id="ref38">
        <mixed-citation>
          38.
          <string-name>
            <surname>Bragaglia</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Chesani</surname>
            ,
            <given-names>F.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Mello</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Montali</surname>
            ,
            <given-names>M.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Torroni</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          :
          <article-title>Reactive event calculus for monitoring global computing applications</article-title>
          . In Artikis,
          <string-name>
            <given-names>A.</given-names>
            ,
            <surname>Craven</surname>
          </string-name>
          ,
          <string-name>
            <given-names>R.</given-names>
            ,
            <surname>Cicekli</surname>
          </string-name>
          ,
          <string-name>
            <given-names>N.K.</given-names>
            ,
            <surname>Sadighi</surname>
          </string-name>
          ,
          <string-name>
            <given-names>B.</given-names>
            ,
            <surname>Stathis</surname>
          </string-name>
          , K., eds.: Logic Programs, Norms and Action - Essays
          <source>in Honor of Marek J. Sergot on the Occasion of His 60th Birthday</source>
          . Volume
          <volume>7360</volume>
          of Lecture Notes in Computer Science., Springer (
          <year>2012</year>
          )
          <fpage>123</fpage>
          -
          <lpage>146</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref39">
        <mixed-citation>
          39.
          <string-name>
            <surname>Barringer</surname>
            ,
            <given-names>H.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Rydeheard</surname>
            ,
            <given-names>D.E.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Havelund</surname>
            ,
            <given-names>K.</given-names>
          </string-name>
          :
          <article-title>Rule systems for run-time monitoring: from eagle to ruler</article-title>
          .
          <source>J. Log. Comput</source>
          .
          <volume>20</volume>
          (
          <issue>3</issue>
          ) (
          <year>2010</year>
          )
          <fpage>675</fpage>
          -
          <lpage>706</lpage>
        </mixed-citation>
      </ref>
      <ref id="ref40">
        <mixed-citation>
          40.
          <string-name>
            <surname>Caianiello</surname>
            ,
            <given-names>P.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Costantini</surname>
            ,
            <given-names>S.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Gasperis</surname>
            ,
            <given-names>G.D.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Florio</surname>
            ,
            <given-names>N.</given-names>
          </string-name>
          ,
          <string-name>
            <surname>Gobbo</surname>
            ,
            <given-names>F.</given-names>
          </string-name>
          :
          <article-title>Application of hybrid agents to smart energy management of a prosumer node</article-title>
          .
          <source>In: Proc. of DCAI</source>
          <year>2013</year>
          ,
          <source>10th International Symposium on Distributed Computing and Artificial Intelligence. Volume 217 of Advances in Intelligent and Soft Computing</source>
          ., Springer (
          <year>2013</year>
          )
          <fpage>597</fpage>
          -
          <lpage>607</lpage>
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>