A mental hospital that used isolation cells and chairs with straps to restrain its patients sounds like something from the far-distant past.

But it was only 20 years ago that a class-action lawsuit was resolved, leading to the shutdown of the Augusta Mental Health Institute and the creation of a system of community-based alternatives for thousands of Maine people with mental illness.

The last two decades have been far from perfect, and Maine still has a long way to go keep its promise to some of its most vulnerable citizens. But on this anniversary of the consent decree, it’s worth noting how far we have come.

In 1988, five residents died during a heat wave in the old facility, which lacked air conditioning. At least one was strapped in restraints at the time of his death.

In 1989, a lawsuit was filed on behalf of all the hospital’s residents, demanding better treatment. It was resolved the following year with a consent decree that required the hospital to close within five years and to be replaced with a system of community-based options.

The old hospital was finally replaced with the Riverview Psychiatric Center in 2004.

But moving care to the community has never been a smooth transition. Only three years after the consent decree was signed, the state was back before a judge for slashing its program budgets while it was releasing patients.

These days, Maine’s county sheriffs indicate that there is a disproportionate number of people with mental illness in the state’s jails. The same is true for homeless shelters.

More budget cuts to state programs make community services harder to access for the people who need them.

In a recent report on the status of the consent decree, former Maine Chief Justice Daniel Wathen, who is the appointed special master for the case, wrote that the state’s increasing reliance on federal Medicaid funding is making services unavailable to people who do not qualify for the program.

Wathen has recommended spending $5.5 million more to provide adequate care and housing support.

It’s important that the state does not forget about these people as we forgot about them in the past, during the days before the lawsuit was filed.