Prosecutors and the defense have agreed to recommend a sentence of two years’ probation, unspecified restitution and community service for McPhee, 49. Malloy could opt for a different sentence for McPhee, who remains free on bond and faces a maximum of five years in prison.

McPhee, who began at the Ames-based academy in 1998, assigned passing scores to exams without checking or correcting them for years. More than 2,400 firefighters and emergency personnel were granted nationally-recognized certifications despite failing tests.