The estranged wife of a New York City police officer testified Monday at his federal kidnapping-conspiracy trial that she had discovered last fall that she was among the women he had allegedly intended to kill, rape, cook and eat.

Gilberto Valle has pleaded not guilty to one count of conspiracy to commit kidnapping, and his defense attorneys say his acknowledged participation in cannibal-themed online chats were the stuff of fantasy that he had no plans to carry out.

None of the alleged plot ever came to fruition. If he is convicted, Mr. Valle, 28 years old, who was suspended from the police force after his arrest in October, faces a prison term of 20 years to life. His trial opened in Manhattan federal court on Monday.

A courtroom sketch on Monday of Gilberto Valle and his estranged wife, Kathleen Mangan-Valle. Reuters

Kathleen Mangan-Valle, 27, and the mother of the couple's 17-month old child, said she installed a tracking program on her computer after she had become suspicious last summer of what she described as her husband's erratic behavior and the long hours late at night that she said Mr. Valle was spending online.

She said the spyware turned up what she said was "thousands and thousands" of chat messages in which her husband took part.

Crying at times from the witness stand, she told the court she began to read the messages and saw photos of herself and of her friends.

"I was going to be tied up by my feet and my throat slit," she said one of the messages indicated.

She said someone involved in the chats wrote: "if she cries don't listen to her, don't give her mercy."

"And Gil just said, 'It's OK, if she cries we'll just gag her," Ms. Mangan-Valle testified.

At one point in the proceedings, when photographs were introduced showing a smiling Mr. Valle with his now-17-month-old daughter, Ms. Mangan-Valle was crying so hard that U.S. District Court Judge Paul Gardephe allowed her to step down from the witness stand to compose herself.

As she did so, Mr. Valle also broke down, sobbing loudly.

She said she contacted the Federal Bureau of Investigation in September.

Ms. Mangan-Valle said she moved to New York City after college as part of the Teach for America program that places college graduates in teaching positions in poor neighborhoods.

She taught special education in the Bronx and East Harlem. She met Mr. Valle through an online dating program called OkCupid, in 2009.

At first, she said, they had "fun, we laughed together, it was nice, he opened doors, pulled out chairs."

The couple moved in together in 2010. She testified that after she became pregnant early in 2011, he changed. "It's like he was gone," she said.

She said he became distant and spent an inordinate amount of time on the computer. He stopped sleeping in their bed and took to the couch.

It was in August that she found links to sadomasochism pornography sites on their computer.

She confronted her husband but a month later found another link to websites that disturbed her even more. Clicking on one of them she said she saw "a woman and she was dangling, just hung and naked and blood was all over her."

Ms. Mangan-Valle grabbed her child and fled to her parents' home in Nevada. It was there several days later that she checked her spyware and found the chat messages with her photos, which led her to contact the FBI.

In opening statements, prosecutor Randall Jackson told jurors that Mr. Valle's "heinous plot to kidnap, rape, murder and cannibalize a number of women" was "deadly serious."

Mr. Valle's defense attorney, Julia Gatto, countered that the prosecution's opening was "shocking and gruesome, the stuff that horror movies are made of." But she said that like a horror movie, the government's account is "pure fiction."

Ms. Gatto said Mr. Valle is a normal father and husband with a "very unusual sexual fetish." She said Mr. Valle's secret was that since he was a young teenager he has been sexually aroused by the "idea and the idea alone" of a woman tied up "laid out on a platter with an apple in her mouth," ready to be cooked.

Before the trial, the judge cited marital privilege and other laws and ruled the prosecution couldn't ask Ms. Mangan-Valle if she thought Mr. Valle really planned to carry out the plot to kidnap and murder her.

Ms Gatto asked Ms. Mangan-Valle why she had declined to speak to defense counsel before the trial.

"You represent the man who wants to kill me," she said. "No, I did not want to talk you."

Write to Sean Gardiner at