Improve docs on grammar class recognition callbacks