Among the total re-think needed is an acceptance of A.I. assisted house arrest and updated medication regimes by implant. Probation/imprisonment terms and compliance would be far more effective, and cheaper, than a thousand pounds a week for conventional prisons.
The prisoner could be technologically prevented from viewing anything online, or communicating with companions, which might perpetuate the mindset or the behaviour which had caused the offence.
Where behaviour was influenced by drink or substances, or by an unrestrained impulse or inclination, then the implanted medication could encourage a calmness to the point of apathy if necessary. Apparently weight loss drugs cause an indifference to food. Other appetites must be capable of suppression.
Apparently there are also medications to make people averse to alcohol. Or, to quell any testosterone excess or mood swings which cause violent outbursts. Those whose crimes involve complex planning may be given whatever medication will make the thought process muddled.
In any case, the inability to wander the streets freely, for life, (though without costing taxpayers a thousand pounds a week) will make it impossible to get access to a child, for example. Constant monitoring on cctv could be screened with A.I., with anything of concern triggering a human monitor, presumably with police powers, to intervene at once.
And, there are body worn (or implanted?) methods to monitor blood.
Tiny tracking implants rather than old fashioned ankle tags would seem better to control any escape from house arrest, and to instantly trigger an alert to the nearest police car.
The only aim of a prison sentence is to safeguard the offender from opportunities AND inclinations to repeat the offence. Merely locking up and releasing, unchanged, cannot possibly achieve either of these aims. This is not in the interests of future victims, nor in the best interests of offenders.
Some have asked, in vain, for chemical castration, despairing because of knowing they will still be drawn to repeating the behaviour. There must be, and are, constantly improving methods to achieve behaviour- control by carefully balanced medications. But implant must be the only sensible method.