Here is a basic format you might use:
The Honorable Judge John Doe
Judge of The Superior Court
County of Chatham
State of Georgia
Dear Judge Doe:
I am writing this letter on behalf of a former student of mine who is presently before you on criminal charges and is due to be sentenced shortly. I am James Wright and I am a member of the school board in Chatham County, Georgia. I have known Susan both personally and professionally for a period of 20 years.
Susan has a productive future ahead of her. (Describe here her accomplishments of the past, especially civic duties, volunteer positions. Explain why you believe that it would be in the best interest of both Susan, as well as the community she resides in as well, that she be granted probation or a reduced sentence.) I believe that both society, as well as Susan, would be better served by the imposition of a period of probation, along with court ordered service to her community; this will better assist her in becoming a more responsible, productive citizen than would any extended period of incarceration.
I was shocked and disappointed in her behavior as she has always been a good, law abiding person. This incident is very unlike Susan's character as I have known it for years.
Judge Doe, I am respectfully seeking the mercy of this Court when Susan is sentenced. I pray that you will give heartfelt consideration in making that decision and that you will take into consideration all of the good that Susan has accomplished in her life; as well as all that she can give back to society if given a second chance.
Thank you in advance for your time and for your consideration.
I trust that this format will be of assistance to you. Feel free to add any fact that might be persuasive in obtaining leniency for your friend.
I wish you the best.