Improvements to subject-verb agreement code