AUGUSTA — A man charged with murdering and dismembering his father in Gardiner in 2014 pleaded guilty, but not criminally responsible, to manslaughter on Monday.

By doing so, Leroy Smith III, waived his right to a jury trial on murder charges just as it was scheduled to get underway. Smith had been accused of killing and dismembering his father, later claiming his father was trying to poison him.

As a result of the insanity plea agreement, Justice Michaela Murphy found Smith not criminally responsible and immediately committed him to the Riverview Psychiatric Center in Augusta, for an undetermined period of time.

State prosecutors had agreed for some time that Smith was not criminally responsible for the murder of his father, as it was clear that he was legally insane at the time, according to Assistant Attorney General Donald Macomber.

Macomber said the elder Smith lived in fear of his son and knew he suffered from mental illness. His friends described the elder Smith as helpful, friendly, and a passionate musician skilled in carpentry and mechanical work, and said he was trying to help his son with his troubles.

“This was a brutal murder, but all the evidence showed he didn’t know what he was doing at the time,” Macomber said of Leroy Smith III.

A jury of nine men and seven women had been selected last week to decide whether Smith was guilty or innocent of the May 2014 killing of Leroy Smith Jr., 56, in the south Gardiner apartment the men shared. The jury was dismissed without hearing any testimony following Smith’s plea change Monday morning.

Smith was under court order to be involuntarily medicated at Riverview in an attempt to restore his ability to stand trial after he was found mentally incompetent in January 2016. It was the first time a Maine court made such a ruling, following a change in state law about two years ago. Smith chose to take the medication voluntarily after the ruling, though Smith’s attorney, Pamela Ames, said Smith would not have taken his medication if the order were not in place.

Experts had testified that Smith’s mental condition had improved to the point that he could stand trial.

On Monday morning as the trial was poised to start, Macomber said the state agreed to the change in charges from murder to manslaughter, in part because the result of being found not criminally responsible for murder or manslaughter carries the same sentence: a commitment to Riverview where Smith would remain until when, and if, he is determined to no longer be a threat to the public.

Murphy warned Smith, 27, that time may never come and that he could spend the rest of his life at the state’s forensic mental health treatment facility in Augusta. She asked if Smith understood that and whether he understood that he would be held at Riverview until a court finds that his release is not likely to cause harm to anyone in the community.

He said yes, he did.

Following Monday’s court proceedings, Ames said that if Smith were to ever be released from Riverview, it would be “a very slow release” before which he would likely get gradually increasing privileges at the hospital.

She said he’s already been at Riverview for three years and has done very well under treatment.

However, she said he still believes today, even under medication, that his father was trying to kill him by poisoning. Smith also still believes his father would have killed him if he had not struck first, Ames said.

“He knows what he did but has a subjective belief his father tried to kill him with rat poison,” Ames said outside the courtroom. “He honestly felt, in his mind, if he did not kill his father, his father would kill him.”

Smith’s defense team was expected to raise that issue and claim self defense at the trial.

Macomber said there was no evidence Smith’s father was trying to poison him. But Macomber said the state agreed to accept Smith’s plea to manslaughter, and drop the murder charge, in part because there was a chance the jury could believe Smith’s claims that he felt his life was in danger and he acted in self defense.

He said the jury could have possibly found Smith had acted in “imperfect” self defense if he believed his life was at risk, even though, in reality, it was not.

Macomber said the state believes Smith knowingly and intentionally killed his father.

“He stabbed his father 15 times then dismembered his body,” Macomber said. “This was intentional conduct.”

But he said until last Friday when the defense approached the prosecution about a plea, Smith had insisted on taking his case to trial.

“We’re a little surprised he was willing to do this because, for the last two years, he was adamant he wanted to tell his story to a jury,” Macomber said.

On Monday, Smith’s head was shaved, as it had been in other recent court hearings, and he had a beard. He wore a white collared shirt in court. He answered yes when Murphy asked if he believed he was of sound mind and body, whether he was still taking his medication and whether he was satisfied with the advice given to him by his attorney.

At the January 2016 hearing when he was found incompetent to stand trial, Smith told a judge that his lawyers had failed to represent him properly and that a gun was held to his head in 2011 in an incident somehow involving the heavy metal band Slayer. Forensic psychologists have said that Smith was suffering from delusions.

“I had a gun held against my head and was sworn to keep secret about what I am,” he said, adding, “The whole entire group Slayer was there.”

Police say Smith stabbed his father to death on May 3, 2014, in their Gardiner apartment, dismembered the body and distributed body parts in trash bags in a rural area off Lincoln Street in Richmond. At one point he claimed to be a political prisoner.

According to an affidavit filed in court, Smith told police he stabbed his father in the head and neck and then used three knives to “dismember his father” — a Ginsu knife and an Asian-style knife and an unidentified third weapon. The state medical examiner found that the elder Smith was stabbed to death, saying he died of “sharp force trauma,” according to investigators.

Smith was arrested in Westbrook two days after the slaying. He told officers at the Cumberland County jail he had killed his father and “filleted him and buried him in the woods because his dad sexually assaulted him his whole life,” according to an affidavit by Maine State Police Detective Jonah O’Roak. There was no evidence of any sexual assault committed by his father.

Smith also has referred to himself as God and said he was affiliated with Hells Angels, the affidavit says.

Keith Edwards — 621-5647

[email protected]

Twitter: @kedwardskj