Mark the ad-hoc pattern as completed only after all the notes have been processed.