By Alex DeMetrick

BEL AIR, Md. (WJZ) –Murder and cannibalism bring a guilty plea in Harford County, but there will be no prison time for the man who committed the crime.

Alex DeMetrick reports the reason Alexander Kinyua will not go to a standard prison was his mental derangement at the time of the killing.

READ MORE: State Won't Prosecute Baltimore Officers Who Shot, Killed Armed Man Near Inner Harbor Last Year

Kinyua, 22, heavily shackled and under medication, was judged mentally competent to enter a guilty plea in the Harford County Courthouse in Bel Air on Monday morning.

But in May 2012, when he murdered, dismembered and ate the heart of his 37-year-old roommate Kujoe Agyei-Kodie, psychiatrists say he was seriously mentally impaired.

Agyei-Kodie had been staying with Kinyua’s family for about six weeks at their townhouse in Harford County before he went missing.

Kinyua originally told police he knew nothing about the disappearance but later confessed to the murder and led police to a church dumpster, where most of Agyei-Kodie’s remains were found. His head and a hand were discovered in the townhouse.

Authorities say Kinyua ranted about “human sacrifices” on Facebook before the slaying.

Prosecutors weren’t convinced about his mental state.

“The disposal of the body parts in the dumpster. The room had been painted. There was some evidence to dispose of other evidence, and I was concerned there seemed to be a lot of planning before and after,”said Joe Cassilly, Harford County State’s Attorney.

But when the prosecution’s doctors studied Kinyua, they made the same finds as doctors at the state’s prison hospital and Kinyua was found not criminally responsible for the murder.

READ MORE: Will Congress Act On Guns After Sandy Hook, Buffalo, Uvalde?

This isn’t Kinyua’s first guilty plea where he was found not criminally responsible.

He attacked another man with a baseball bat wrapped in barbed wire on the campus of Morgan State University, where he and Agyei-Kodie were students. Kinyua was freed on bail.

A week later, he killed Agyei-Kodie,

“Certainly that should’ve been a call for somebody, specifically his parents who bonded him out, to have gotten some sort of psychiatric review or some workup done to find out why would somebody make that sort of an attack rather than bring him out of custody and release him to find a new victim,” Cassilly said.

Joshua Caesar, who was injured in the baseball bat attack, is suing the university, accusing it of ignoring signs that Kinyua was violent.

Family and friends of the student who came from Ghana to Maryland to study told the judge of the senseless loss of so much promise.

“He was slaughtered in the most brutal and inhumane way by Alexander Kinyua, for consumption,” said family friend Percess Mattison.

“I think there’s a great sense of emptiness because they kind of feel like after I explained it to them, nothing really happened today. He was committed back to the hospital,” Cassilly said.

Kinyua will remain at the state prison hospital indefinitely until doctor’s judge him no longer a threat to society or himself.

If a time comes that Kinyua is judged safe to leave the hospital, he would not be sent to a standard prison. He would be a free man.

MORE NEWS: Ferguson And Jones Downplay Possibility Of Special Session For Gas Tax, Blame Oil Companies

Kinyua’s father is a physics professor at Morgan State.