First make a fifo
$ export fifopath=$PWD/chat.fifo
$ mkfifo "$fifopath"Then start reading from the fifo and looking for the ^G ding escape code.
cat -u -e "$fifopath" | while read line; do
  if echo "$line" | grep -q '\^G'; then
    echo "DING: $line"  # <- Replace this with your fav notify command
  fi
doneMake sure you start reading the fifo before you start writing to it.
Now join ssh-chat and fork the output into our fifo (in a different terminal):
$ ssh -t chat.shazow.net | tee -a "$fifopath"  # Don't forget to set the $fifopathYou might be able to achieve the same thing inline (without using a separate watcher process and a fifo), but maybe this way it's more fun?
Made it better, hosting it on a new repository here