A former FBI agent who faces perjury charges over statements he made on the witness stand during the 2013 trial of longtime Boston mob boss James "Whitey" Bulger plans to plead guilty, according to a court filing on Wednesday.

Robert Fitzpatrick was the first witness called by Bulger's attorneys during the trial. He testified that when he first met the man who once ruled Boston's underworld, he concluded the FBI should not be working with the gangster, telling the jury that he "couldn't see his soul."

Fitzpatrick also testified he had been the first FBI agent on the scene of civil rights activist Martin Luther King Jr.'s 1968 assassination and had been sent to Boston on a special assignment to clean up "major problems" in the office.

RELATED: Bulger got solitary for allegedly pleasing himself in prison cell

Even Bulger's attorneys expressed surprise at those statements, at least once asking the retired agent if he was lying, which he denied.

Federal prosecutors had similar qualms. Stating that those statements and others made on the stand were lies, they last year arrested Fitzpatrick, now in his late 70s, and charged him with 12 criminal counts of perjury and obstruction of justice.

Fitzpatrick, who served in the FBI from 1965 through 1986, pleaded not guilty in his first court appearance on the perjury charges. In a joint filing on Wednesday, his attorneys and prosecutors asked a judge to schedule a change of plea hearing for May 5.

The filing did not specify whether Fitzpatrick planned to change his plea on some or all of the charges, and his attorney did not immediately respond to a call seeking comment.

Bulger's trial exposed the corrupt relationship between the Irish-American gangster and law enforcement agents who shared his ethnic background and turned a blind eye to his crimes in exchange for information they could use against the Italian-American Mafia.

RELATED: Whitey Bulger no fan of Depp's 'Black Mass'

Bulger, 68, has denied serving as an informant, insisting he paid agents for tips but provided none of his own.

He fled the city in 1995 on a tip from an FBI handler that arrest was imminent and was a fugitive for 16 years, most of them atop the FBI's "Ten Most Wanted" list before agents caught up with him in an apartment in Santa Monica, California, in 2011.

He is serving a life sentence after being convicted of committing or ordering 11 murders while head of the Winter Hill gang in the 1970s and '80s.