Rename `then` to `chain` and change the monad hierarchy

Also capitalise names of the algebras