"oh?" Hopefully that will beckon her/him to stop; since if they said the initial 'compliment' after they walked past you, by the time you respond they might've been out of
hearing range. And since you had to ask here, you're probably often victim to esprit descalier. But the "oh?" will hopefully make them turn around/slow down, and give you enough time to haul the wit back over the staircase....