191 research outputs found
Operational Semantics of Process Monitors
CSPe is a specification language for runtime monitors that can directly
express concurrency in a bottom-up manner that composes the system from
simpler, interacting components. It includes constructs to explicitly flag
failures to the monitor, which unlike deadlocks and livelocks in conventional
process algebras, propagate globally and aborts the whole system's execution.
Although CSPe has a trace semantics along with an implementation demonstrating
acceptable performance, it lacks an operational semantics. An operational
semantics is not only more accessible than trace semantics but also
indispensable for ensuring the correctness of the implementation. Furthermore,
a process algebra like CSPe admits multiple denotational semantics appropriate
for different purposes, and an operational semantics is the basis for
justifying such semantics' integrity and relevance. In this paper, we develop
an SOS-style operational semantics for CSPe, which properly accounts for
explicit failures and will serve as a basis for further study of its
properties, its optimization, and its use in runtime verification
Combining computational effects: commutativity and sum
We begin to develop a unified account of modularity for computational effects. We use the notion of enriched Lawvere theory, together with its relationship with strong monads, to reformulate Moggi’s
paradigm for modelling computational effects; we emphasise the importance here of the operations that induce computational effects. Effects
qua theories are then combined by appropriate bifunctors (on the category of theories). We give a theory of the commutative combination of
effects, which in particular yields Moggi’s side-effects monad transformer
(an application is the combination of side-effects with nondeterminism).
And we give a theory for the sum of computational effects, which in particular yields Moggi’s exceptions monad transformer (an application is
the combination of exceptions with other effects)
Handling polymorphic algebraic effects
Algebraic effects and handlers are a powerful abstraction mechanism to
represent and implement control effects. In this work, we study their extension
with parametric polymorphism that allows abstracting not only expressions but
also effects and handlers. Although polymorphism makes it possible to reuse and
reason about effect implementations more effectively, it has long been known
that a naive combination of polymorphic effects and let-polymorphism breaks
type safety. Although type safety can often be gained by restricting let-bound
expressions---e.g., by adopting value restriction or weak polymorphism---we
propose a complementary approach that restricts handlers instead of let-bound
expressions. Our key observation is that, informally speaking, a handler is
safe if resumptions from the handler do not interfere with each other. To
formalize our idea, we define a call-by-value lambda calculus that supports
let-polymorphism and polymorphic algebraic effects and handlers, design a type
system that rejects interfering handlers, and prove type safety of our
calculus.Comment: Added the errata for the ESOP'19 paper (page 28
Proof Relevant Corecursive Resolution
Resolution lies at the foundation of both logic programming and type class
context reduction in functional languages. Terminating derivations by
resolution have well-defined inductive meaning, whereas some non-terminating
derivations can be understood coinductively. Cycle detection is a popular
method to capture a small subset of such derivations. We show that in fact
cycle detection is a restricted form of coinductive proof, in which the atomic
formula forming the cycle plays the role of coinductive hypothesis.
This paper introduces a heuristic method for obtaining richer coinductive
hypotheses in the form of Horn formulas. Our approach subsumes cycle detection
and gives coinductive meaning to a larger class of derivations. For this
purpose we extend resolution with Horn formula resolvents and corecursive
evidence generation. We illustrate our method on non-terminating type class
resolution problems.Comment: 23 pages, with appendices in FLOPS 201
Towards meta-interpretive learning of programming language semantics
We introduce a new application for inductive logic programming: learning the
semantics of programming languages from example evaluations. In this short
paper, we explored a simplified task in this domain using the Metagol
meta-interpretive learning system. We highlighted the challenging aspects of
this scenario, including abstracting over function symbols, nonterminating
examples, and learning non-observed predicates, and proposed extensions to
Metagol helpful for overcoming these challenges, which may prove useful in
other domains.Comment: ILP 2019, to appea
Notions of Bidirectional Computation and Entangled State Monads
Bidirectional transformations (bx) support principled consistency maintenance between data sources. Each data source corresponds to one perspective on a composite system, manifested by operations to ‘get’ and ‘set’ a view of the whole from that particular perspective. Bx are important in a wide range of settings, including databases, interactive applications, and model-driven development. We show that bx are naturally modelled in terms of mutable state; in particular, the ‘set’ operations are stateful functions. This leads naturally to considering bx that exploit other computational effects too, such as I/O, nondeterminism, and failure, all largely ignored in the bx literature to date. We present a semantic foundation for symmetric bidirectional transformations with effects. We build on the mature theory of monadic encapsulation of effects in functional programming, develop the equational theory and important combinators for effectful bx, and provide a prototype implementation in Haskell along with several illustrative examples
Automatic inference of indexing rules for MEDLINE
This paper describes the use and customization of Inductive Logic Programming (ILP) to infer indexing rules from MEDLINE citations. Preliminary results suggest this method may enhance the subheading attachment module of the Medical Text Indexer, a system for assisting MEDLINE indexers.
- …