relay: keep tweaking session interface details and move relevant classes to internal package