Add version based on free monads