In any case in which an offender agrees to an intervention program, a specific agreement shall be made between the district attorney and the offender. This agreement shall include the terms of the intervention program, the length of the program, which shall not exceed three (3) years, and a section therein stating the period of time after which the prosecutor will either dismiss the charge or seek a conviction based upon that charge. The agreement shall be signed by the offender and his or her counsel and filed in the district attorney’s office. Before an offender is admitted to an intervention program, the court having jurisdiction of the charge must approve of the offender’s admission to the program and the terms of the agreement.