Law Enforcement should be more under the judiciary than under the executive branch, as it is done in the United States. Judges, Corrections, and Law Enforcement are the three legs of the stool of Justice; they each look at it from a different perspective.
-Judges are in charge of adjudicating the law and making decisions about the law. They should not make laws, nor should they have the power to enforce the law. Their whole purpose is to make difficult decisions based on all the evidence made available to them. It would be nice if the laws could be decided upon by judges with AI assistance, but the judgments shouldn't be purely by AI or human alone: humans are prone to bias, while AI would lack compassion. Appeals should be allowed, although a limit of one per year might be appropriate in all but the most egregious circumstances. The primary executive (President, whatever) would still have the power to pardon in those cases where the law is limited or where justice may have been limited by the letter of the law.
-Law Enforcement is in charge of protecting the citizens from those who violate the law. They do not make decisions, only observe when laws are broken and collect evidence to give to the judges so that the judges can make the best determination of whether or not the laws were violated. Everything in society should be recorded but not necessarily monitored by someone, allowing evidence to be collected in the event of a crime, but not be used as a method of investigation prior to a crime. Law Enforcement can only observe the private recordings of citizens with an order from a Judge IF that judge is given sufficient evidence to believe that a crime is likely to be committed. Law enforcement should ALWAYS be monitored and recorded while on the job, and obvious to anyone who meet them. Covert investigations should remain under the purview of the executive branch, specifically intelligence operations.
-Corrections is in charge of making certain that those who are found guilty of crimes are educated about the laws (especially those they violated), and protecting the citizens by making certain that they will be no longer a threat to society when released. Those who have violated the law should be seen as misguided, perhaps damaged, individuals to be made whole and informed. If they cannot be taught, or repaired, then they must remain as charges to live out the rest of their days in further education until they either learn, heal, or depart this life. Corrections should NOT be considered punishment under any circumstances, but be in charge of the CORRECTION of aberrant social behavior.
Above all, as you might guess, I believe the entire role of the judicial branch should not be seen as an actor of punishment, but one of protection and education for its citizens. You should never dread going before a judge (slight pun intended), but instead should only see them as a 'village elder' who will make as impartial a decision as it is humanly possible to do so, while making sure that all parties involved return to a place of equilibrium (in the case of civil law) so they can return to a place where they can grow and thrive.