It's lunchtime in Room 510 of the Broward County Courthouse, and the judge is clearly worried about the disheveled prisoner with matted hair and glassy eyes sitting shackled before her.

The man has been languishing in the county jail for days on a minor trespassing charge. He's a schizophrenic and alcoholic who says he's been living on the streets and not taking medication for his illness.

In the middle of the hearing, Judge Ginger Lerner-Wren picks up the phone and dials a local mental health program. At first she cajoles the administrator. Then she becomes stern and emphasizes that "the court" really wants this man to get treatment and shelter.

Lerner-Wren hangs up the phone and announces that a bed is waiting for him.

"God bless you, judge," the man yells.

She smiles and calls the next case.

That's a typical scene at the Broward County Mental Health Court, a unique blend of justice and social services, or as Lerner-Wren often calls it, "therapeutic jurisprudence."

The county court, the first in the nation when it was created in 1997, has become a model for more than two dozen communities from Anchorage, Alaska, to Brooklyn, N.Y.

In Florida, mental health courts have cropped up in Sarasota, Osceola, Lee and Alachua counties. Palm Beach and Orange counties are seeking funding to start courts and Okaloosa County is launching one in January.

Law enforcement officials estimate the court has saved the Broward jail system at least a million dollars a year.

The goal is to stop mentally ill defendants arrested on misdemeanors such as disorderly conduct, loitering, petty theft and public drinking from rotating in and out of jail and get treatment for them. In its five years of operation, the court has offered help to hundreds of offenders who otherwise would have been in jail, records show.

"The court needs to give our people a sense that somebody with authority cares," Lerner-Wren says. "On a daily basis, that's what we're striving for."

For defendants who participate, criminal charges are put on hold. The judge evaluates the case, consults with the court's social workers and issues an order specifying treatment and rules they must follow. "This is not a trial court. This is a treatment court for people who have some kind of mental health condition," the judge tells new defendants. "It is purely voluntary."

Some defendants need a case manager. Others require a live-in program and intensive therapy. Many also are substance abusers needing drug or alcohol treatment.

It's a heavy load, especially because it's a part-time court. Lerner-Wren maintains her regular criminal docket and holds mental health court hearings during her lunch hour on weekdays. On Thursdays, she schedules a full afternoon of status conferences to monitor defendants' progress.

The court has no budget and operates with only two employees: a $40,000-a-year county-funded court monitor from Henderson Mental Health Center and a $45,000-a-year licensed clinical social worker from the Florida Department of Children & Families.

Unlike most courts, where a hush falls as the judge appears, mental health court is often a free-for-all. Attorneys and social workers mill about in front of the judge, chatting about defendants' histories. Nova Southeastern University psychology doctoral student interns screen prisoners who are in manacles, jail jumpsuits and black flip-flops, and report their findings to the judge.

"How many times have you been in the hospital for mental health reasons?" the students ask.

"Do you have a place to live?"