The St. Louis man accused of making anti-Semitic threats to Jewish centers across the country in a convoluted campaign to harass his ex-girlfriend faces up to 10 years in prison after pleading guilty to cyberstalking in Manhattan federal court on Tuesday.

Juan Thompson, appearing composed and saying he was contrite, also pleaded guilty to inducing fear through hoaxes involving bomb threats that he tried to attribute to the former girlfriend, a social services worker from Brooklyn who has not been named.

“I committed all these acts with the intent to disrupt my ex romantic partner’s life and cause her substantial distress,” Thompson, 32, a former journalist, told U.S. District Judge P. Kevin Castel. “For this, I deeply apologize and am pleading guilty today.”

Thompson was charged in March with making threats to Jewish centers in New York, California, Michigan and Texas that some had depicted as part of a wave of anti-Semitism in the aftermath of the presidential campaign of Donald Trump.

A former reporter fired by the online news site the Intercept for fake stories, Thompson allegedly made some threats in the girlfriend’s name to smear her after they broke up, and others naming him that were designed to make it look like she was framing him.

The threats evoked frightening images — such as a “Jewish Newtown” in a reference to the notorious school shooting in Connecticut — and Thompson also sent the woman’s employer defamatory material with nude pictures citing matters such as drunken driving and child pornography, the government said.

advertisement | advertise on newsday

During his plea, he showed no signs of the aberrant behavior that got him in trouble, responding calmly when the judge asked how he was feeling. “I’m slightly nervous, but I have to deal with the consequences of my actions,” Thompson said. “That’s why I’m here.”

In his cyberstalking plea, he admitted he used emails and faxes in 2016 and this year to spread “false and salacious allegations” about the woman to cause her emotional distress. In his plea to bomb hoaxes, he admitted at least 12 threats to Jewish community centers, service groups and schools.

After the plea, acting Manhattan U.S. Attorney Joon Kim said in a statement that Thompson’s personal revenge campaign had broader consequences.

“Thompson’s threats not only inflicted emotional distress on his victim, but also harmed Jewish communities around the country,” Kim said.

Defense lawyers and prosecutors told Castel they have not agreed on how to apply federal sentencing guidelines to Thompson’s case. Prosecutors say the nonbinding guidelines call for 37 to 46 months in prison, while the defense calculation calls for 30 to 37 months.

Thompson has been detained since he was charged in March. Castel scheduled his sentencing for Sept. 15.