ftInteractT :: (Monad m, Ord i) =>
                 (c' -> c) -> (s -> s') -> Lens' u' u ->
                 InteractT i u c s m a -> InteractT i u' c' s' m a

liftInteractT cf sf uLens intx =
  case intx of
    Terminal a     -> Terminal a
    Talk send cont -> Talk (map (second sf) send)
                           (liftInteractT cf sf uLens . cont . map (second cf))
    Stateful cont  -> Stateful (\u' -> let (intx1, u1) = cont (view uLens u') in
                                 (liftInteractT cf sf uLens intx1, set uLens u1 u'))
    M cont         -> M $ fmap (liftInteractT cf sf uLens) cont

liftInteractT :: (Monad m, Ord i) =>
                 (c' -> c) -> (s -> s') -> Lens' u' u ->
                 InteractT i u c s m a -> InteractT i u' c' s' m a
liftInteractT cf sf uLens intx =
  case intx of
    Terminal a     -> Terminal a
    Talk send cont -> Talk (map (second sf) send)
                           (liftInteractT cf sf uLens . cont . map (second cf))
    Stateful cont  -> Stateful (\u' -> let (intx1, u1) = cont (view uLens u') in
                                 (liftInteractT cf sf uLens intx1, set uLens u1 u'))
    M cont         -> M $ fmap (liftInteractT cf sf uLens) cont
liftInteractT cf sf uLens intx =
  case intx of
    Terminal a     -> Terminal a
    Talk send cont -> Talk (map (second sf) send)
                           (liftInteractT cf sf uLens . cont . map (second cf))
    Stateful cont  -> Stateful (\u' -> let (intx1, u1) = cont (view uLens u') in
                                 (liftInteractT cf sf uLens intx1, set uLens u1 u'))
    M cont         -> M $ fmap (liftInteractT cf sf uLens) cont