create choose session and choose type function