A continuation-based, backtracking, logic programming monad. An adaptation of the two-continuation implementation found in the paper Backtracking, Interleaving, and Terminating Monad Transformers available here: http://okmij.org/ Control.Monad.Logic.Class
Comonads are an abstraction from category theory dualing many qualities of Monads. They are conceptually much simpler than arrows but seem to offer a solution to some problems not easily solved by monads. The ideas presented here are not novel except for the comonadic combinators for a nicer syntax. Typeclass Combinators Reader State Stream Writer Links