If the defendant has been previously convicted or assigned to an alcohol or controlled substance education, treatment, or rehabilitation program by a court of the commonwealth, or any other jurisdiction because of a like offense two times preceding the date of the commission of the offense for which he has been convicted, the defendant shall be punished by a fine of not less than one thousand nor more than fifteen thousand dollars and by imprisonment for not less than one hundred and eighty days nor more than two and one-half years or by a fine of not less than one thousand nor more than fifteen thousand dollars and by imprisonment in the state prison for not less than two and one-half years nor more than five years; provided, however, that the sentence imposed upon such person shall not be reduced to less than one hundred and fifty days, nor suspended, nor shall any such person be eligible for probation, parole, or furlough or receive any deduction from his sentence for good conduct until he shall have served one hundred and fifty days of such sentence; provided, further, that the commissioner of correction may, on the recommendation of the warden, superintendent, or other person in charge of a correctional institution, or the administrator of a county correctional institution, grant to an offender committed under this subdivision a temporary release in the custody of an officer of such institution for the following purposes only: to attend the funeral of a relative, to visit a critically ill relative; to obtain emergency medical or psychiatric services unavailable at said institution; to engage in employment pursuant to a work release program; or for the purposes of an aftercare program designed to support the recovery of an offender who has completed an alcohol or controlled substance education, treatment or rehabilitation program operated by the department of correction; and provided, further, that the defendant may serve all or part of such one hundred and fifty days sentence to the extent such resources are available in a correctional facility specifically designated by the department of correction for the incarceration and rehabilitation of drinking drivers.

If the defendant has been previously convicted or assigned to an alcohol or controlled substance education, treatment, or rehabilitation program by a court of the commonwealth or any other jurisdiction because of a like offense three times preceding the date of the commission of the offense for which he has been convicted the defendant shall be punished by a fine of not less than one thousand five hundred nor more than twenty-five thousand dollars and by imprisonment for not less than two years nor more than two and one-half years, or by a fine of not less than one thousand five hundred nor more than twenty-five thousand dollars and by imprisonment in the state prison for not less than two and one-half years nor more than five years; provided, however, that the sentence imposed upon such person shall not be reduced to less than twelve months, nor suspended, nor shall any such person be eligible for probation, parole, or furlough or receive any deduction from his sentence for good conduct until such person has served twelve months of such sentence; provided, further, that the commissioner of correction may, on the recommendation of the warden, superintendent, or other person in charge of a correctional institution, or the administrator of a county correctional institution, grant to an offender committed under this subdivision a temporary release in the custody of an officer of such institution for the following purposes only: to attend the funeral of a relative; to visit a critically ill relative; to obtain emergency medical or psychiatric services unavailable at said institution; to engage in employment pursuant to a work release program; or for the purposes of an aftercare program designed to support the recovery of an offender who has completed an alcohol or controlled substance education, treatment or rehabilitation program operated by the department of correction; and provided, further, that the defendant may serve all or part of such twelve months sentence to the extent that resources are available in a correctional facility specifically designated by the department of correction for the incarceration and rehabilitation of drinking

If the defendant has been previously convicted or assigned to an alcohol or controlled substance education, treatment or rehabilitation program by a court of the commonwealth or any other jurisdiction because of a like offense four or more times preceding the date of the commission of the offense for which he has been convicted, the defendant shall be punished by a fine of not less than two thousand nor more than fifty thousand dollars and by imprisonment for not less than two and one-half years or by a fine of not less than two thousand nor more than fifty thousand dollars and by imprisonment in the state prison for not less than two and one-half years nor more than five years; provided, however, that the sentence imposed upon such person shall not be reduced to less than twenty-four months, nor suspended, nor shall any such person be eligible for probation, parole, or furlough or receive any deduction from his sentence for good conduct until he shall have served twenty-four months of such sentence; provided, further, that the commissioner of correction may, on the recommendation of the warden, superintendent, or other person in charge of a correctional institution, or the administrator of a county correctional institution, grant to an offender committed under this subdivision a temporary release in the custody of an officer of such institution for the following purposes only: to attend the funeral of a relative; to visit a critically ill relative; to obtain emergency medical or psychiatric services unavailable at said institution; to engage in employment pursuant to a work release program; or for the purposes of an aftercare program designed to support the recovery of an offender who has completed an alcohol or controlled substance education, treatment or rehabilitation program operated by the department of correction; and provided, further, that the defendant may serve all or part of such twenty-four months sentence to the extent that resources are available in a correctional facility specifically designated by the department of correction for the incarceration and rehabilitation of drinking drivers.

(Taken from Drunk Driving Defense in Massachusetts, pg. 3-4)