Latarsha Sanders of Brockton allegedly showed up at her mother's house earlier this month vowing to kill someone so she could offer up a human heart to save her dying father. Sanders then disappeared with her two young sons in tow, and only resurfaced two days later when police officers found the 8- and 5-year-old boys stabbed to death in her apartment. Sanders, the sole suspect in their deaths, has a long history of mental illness and allegedly killed her children in a quasi-religious sacrificial ritual. 

Sanders' future will be heavily determined by how her history of mental illness shapes her trial.

WGBH legal analyst and Northeastern University law professor Daniel Medwed tells Morning Edition that there's a lot of public confusion about how a defendant's mental state can affect the way they're treated by the courts.

For one, Medwed said, Sanders has to be determined to be mentally competent in order to stand trial or accept a plea bargain.

"The law requires that for a defendant to waive her constitutional right to a jury trial and enter a plea she has to do so knowingly, voluntarily, and intelligently," said Medwed. "That could be a challenge, given [Sanders'] lengthy history of mental health issues."

A similar test is required if a person decides to proceed to trial. A defendant must understand the allegations they face and must be able to participate in their own defense. If a person fails to pass these tests, the trial continues indefinitely without a finding but does not necessarily result in a dismissal of charges.

However, if a person is deemed mentally competent to face a jury, Medwed said, that does not prevent them from claiming mental insanity during trial.

An insanity defense argues that person was unable to understand the consequences of their actions or was unable to abide by a law at the time of a crime because of a temporary mental incapacity caused by illness. While a successful insanity defense prevents a person from entering prison, it doesn't guarantee freedom. Sanders could spend the rest of her life institutionalized, Medwed said. 

"It's unclear if spending an indefinite, indeterminate period of time in a mental health institution with all the danger and treacherousness nature of that existence ... whether that's preferable to being in general population for a finite number of years, he added."

To listen to the interview in its entirety, click on the audio player above.