Extending Equational Monadic Reasoning with Monad Transformers

11/06/2020
by   Reynald Affeldt, et al.
0

There is a recent interest for the verification of monadic programs using proof assistants. This line of research raises the question of the integration of monad transformers, a standard technique to combine monads. In this paper, we extend Monae, a Coq library for monadic equational reasoning, with monad transformers and we explain the benefits of this extension. Our starting point is the existing theory of modular monad transformers, which provides a uniform treatment of operations. Using this theory, we simplify the formalization of models in Monae and we propose an approach to support monadic equational reasoning in the presence of monad transformers. We also use Monae to revisit the lifting theorems of modular monad transformers by providing equational proofs and explaining how to patch a known bug with a non-standard use of Coq that combines impredicative polymorphism and parametricity.

READ FULL TEXT

page 1

page 2

page 3

page 4

research
03/23/2022

AbductionRules: Training Transformers to Explain Unexpected Inputs

Transformers have recently been shown to be capable of reliably performi...
research
03/19/2022

FaiRR: Faithful and Robust Deductive Reasoning over Natural Language

Transformers have been shown to be able to perform deductive reasoning o...
research
11/22/2022

Simplicity Bias in Transformers and their Ability to Learn Sparse Boolean Functions

Despite the widespread success of Transformers on NLP tasks, recent work...
research
03/04/2019

Dijkstra Monads for All

This paper proposes a general semantic framework for verifying programs ...
research
04/28/2022

A Probabilistic Interpretation of Transformers

We propose a probabilistic interpretation of exponential dot product att...
research
06/12/2023

Transformers learn through gradual rank increase

We identify incremental learning dynamics in transformers, where the dif...
research
04/29/2021

Analyzing the Nuances of Transformers' Polynomial Simplification Abilities

Symbolic Mathematical tasks such as integration often require multiple w...

Please sign up or login with your details

Forgot password? Click here to reset