add choose dict function and test swipe