Get a smallish metal washer (½" ??)
Tie a short piece of cotton to it
Tie a long piece of cotton to it (length dictated by the distance needed to hide)
Tape the short piece of cotton to their window (up in a top corner)
Run the long length to your chosen place of concealment
Pull on cotton and release (tap repeat tap)
Continue until they go mad
In case of detection pull real hard on the long cotton, it should slide out from under the tape, then run like hell.
Warning: Don't leave your fingerprints on the adhesive side of the tape
We used to do this when i was at boarding school, the persistent tap tap tap was annoying, the fact that when you looked out the window there was nothing to be seen was worse, but the killer is when you lie down again and switch the lights off the bloody tapping starts again.