There is a flashback with footage taken from the series pilot (in black & white) of Tony first uncorking Jeannie's bottle and she coming out. With the new addition of Tony's voice saying "Bonnie?"
The flashback of Tony playing the piano is from Jeannie at the Piano (1969), but the tune he is playing is particular to the present episode: the Scottish song "My Bonnie (lies over the ocean)". Part of Jeannie's obsessional thoughts about Tony's high school sweetheart, Bonnie.
In Tony's high school yearbook, next to the picture of Bonnie Crenshaw, her name and credits are given and underneath there is a drawing of Aladdin's lamp, home of another famous genie (who Jeannie has claimed to know).