Under Penal Code section 1210.1, subdivision (d)(1), the probation department can investigate, prepare, and file a petition for dismissal of charges on behalf of the probationer. The probation department sent defendants letters advising them that they may qualify for early termination of drug treatment probation granted under section 1210.1, and dismissal of charges, as well as a form letter they were asked to sign and return. After receiving the signed forms, the department filed petitions recommending termination of probation and dismissal of charges. The defendants were present and represented by counsel, at the hearing on the matter. The prosecution opposed granting the petitions on the grounds that the statute stated, “a defendant may petition . . .” but did not grant authority to the probation department to do so. The court denied the petitions without prejudice. The appellate court concluded the lower court took too literal a view of the statute, observing that literal construction of a statute should not prevail over its intent, and reversed with directions to the trial court for determination of the petitions on their merits.