fix annotation detection