For indispensable reporting on the coronavirus crisis, the election, and more, subscribe to the Mother Jones Daily newsletter.

When Derrick Thomas, a veteran in his 50s who’s been diagnosed with post-traumatic stress disorder, paranoid schizophrenia, and traumatic brain injury, was released from the Los Angeles County jail at 2 a.m. a few years ago, officers told him he’d be rearrested if he didn’t get off jail property. Thomas did not have a place to go, but just a short walk away from the looming jail buildings was Skid Row, the city’s roughly 50-block homelessness “containment” zone. That’s where he spent the night, under cardboard.

“It was cold as hell,” Thomas recalled in a video published by the pro bono law firm Public Counsel. On the night that he was let out of jail, Thomas received no information about community resources like counseling or housing assistance. He needed medication for his PTSD, but he’d lost his ID, and it took weeks before he could get a prescription filled. “We just get pushed to the curb,” he said.

In 2015, attorneys representing Thomas and seven other on-and-off-again inmates intervened in a federal lawsuit over the LA County jail’s treatment of inmates with mental health issues. They argued that even after the county had settled with the federal government, it was still not planning to do enough to help these inmates break out of the jail-to-Skid Row cycle.

Last Thursday, as part of a new settlement in the case, LA County agreed to start fixing some of those problems as part of an expanded “release planning” service for inmates, many of them homeless, with moderate to severe mental illness or dementia. The LA County jail holds roughly 16,000 inmates on any given night, and about a third require mental health care—about 25 percent of men and 40 percent of women, according to journalist Alisa Roth, author of Insane: America’s Criminal Treatment of Mental Illness.

“As soon as a person with a mental illness and disability are incarcerated, there needs to be thinking about the release of that person,” says Alisa Hartz, a Public Counsel attorney who has been participating in negotiations with the county for the last two and a half years. “There needs to be a lot more coordination between the jail and the community in order to break the cycle of homelessness and recidivism and incarceration.”

Hartz hopes that people like Thomas now will stop falling through the cracks. “When they’re coming out of jail, which is a really vulnerable moment, they don’t have to figure out, ‘Okay, I have no place to live, and no money, and now I have to figure out how to identify someone who can refill my prescription,'” she says. Figuring out all these things is “really difficult for anybody,” she adds. “But if a person has a mental illness that impairs their executive functioning, it’s, you know, it’s even harder—if not impossible.”

“There needs to be a lot more coordination between the jail and the community in order to break the cycle of homelessness and recidivism and incarceration.”

Under the settlement, LA County will hire and train staff members to work with inmates who need moderate to intensive mental health care during their incarceration. An estimated 1,875 to 2,250 people released each month will qualify, Hartz says, many of whom have been arrested for minor crimes. The county will begin release planning with these inmates as soon as they are locked up, beginning by evaluating their family situation, housing, and support networks.

Once an inmate’s needs have been identified, the county will put together a plan for his or her eventual transition out of jail. Many of those release plans will include connections to social workers, advocates, or nonprofit agencies that can help newly released inmates navigate the confusing world of public benefits, substance abuse services, doctors’ appointments, and housing.

Crucially, that work will begin while people are still behind bars. The county will help inmates apply for public benefits and identification and make post-release appointments with outside mental health providers. If inmates need transportation to get to a shelter or other housing when they are released, the county will provide it. If they need medication, they’ll get a “clinically appropriate” supply—typically, 14 days’ worth. And when they finally do get out, they’ll have a copy of their release plan in hand, so they know where to go and how to get there.

“We know if you leave the jail with a place to stay and your next follow-up appointment, you’re less likely to reoffend,” LA County jail mental health director Timothy Belavich told the Los Angeles Times. “We really do believe this will reduce our recidivism, especially among the mentally ill.”

The LA County jail’s mental health system has been the subject of complaints and federal inspections for more than two decades. When Roth visited, she found inmates wearing heavy “suicide gowns” being transported in handcuffs and leg shackles, cells smeared with feces, and officers threatening a man with solitary confinement because they believed he was faking mental illness. “The sense of us and them, the divide between the prisoners and the officers, or really the prisoners and the rest of us, is especially pronounced on mental health units like this one, where many people are either openly aggressive—growling, snarling, yelling, banging on doors—or completely unresponsive,” Roth wrote.

In 2015, the federal government sued LA County over concerns about suicide prevention, mental health care, and the use of excessive force against inmates with mental illness. On the same day that the suit was filed, the Justice Department proposed a settlement agreement, which a judge quickly approved. A few weeks later, attorneys for Thomas and the other inmates intervened, arguing that the settlement violated the American With Disabilities Act, because people with mental disabilities required additional assistance when they were released from jail. The judge agreed, and negotiations began in the summer of 2016 over the changes that were approved last week.

Hartz hopes that the terms of the new settlement agreement, which will be overseen by an independent monitor, will bring LA County’s practices into line with a handful of other cities and counties that have taken progressive steps to improve reentry services for mentally ill inmates. Hampden County, Massachusetts, links soon-to-be-released inmates with “peer mentors” who introduce them to an outside network of behavioral health services.

In a 2017 report outlining recommendations for reentry, the Substance Abuse and Mental Health Services Administration recommended that more counties adopt reentry programs that focus on maintaining continuity in mental health services. “The least developed jail-based service is transition planning,” the authors wrote, promising that such programs could help individuals recover from mental illness, cut recidivism, and reduce spending on prisons. The LA County jail has an annual budget of more than $700 million.