President Trump accused leaders at the FBI and the Justice Department of politicizing "the sacred investigative process in favor of Democrats," on Feb. 2. (Reuters)

President Trump on Friday accused the top leadership of the Justice Department and FBI of favoring Democrats and having “politicized the sacred investigative process,” posting an incendiary tweet hours before the expected release of a controversial congressional memo alleging surveillance abuses by the FBI.

“The top Leadership and Investigators of the FBI and the Justice Department have politicized the sacred investigative process in favor of Democrats and against Republicans — something which would have been unthinkable just a short time ago,” Trump wrote on Twitter.

He added: “Rank & File are great people!”

The president’s statement on Twitter came on the day that he is expected to approve the release of a memo that suggests that the origins of special counsel Robert S. Mueller III’s probe into Russian interference in the 2016 election were tainted by political bias.

The memo alleges that the FBI, when obtaining a surveillance warrant, relied in some part on a dossier of allegations against then-candidate Donald Trump that was underwritten by the Hillary Clinton campaign and the Democratic National Committee.

Law enforcement and intelligence officials have expressed “grave concerns” about the memo’s release, saying it contains classified information and inaccuracies.

The four-page memo was written by Republican staffers of the House Intelligence Committee, which is chaired by Rep. Devin Nunes (R-Calif.).

It alleges that the British former spy who wrote the dossier passed bad information to the FBI and suggests that information was used in the application to conduct surveillance on the former campaign adviser, Carter Page, according to people familiar with the document.

In a separate tweet Friday morning, Trump quoted Tom Fitton, the president of Judicial Watch, a conservative educational foundation, alleging that the dossier was wrongly used to convince a court to authorize the surveillance and “spy on the Trump Team.”

Leaders of Fusion GPS, the research firm responsible for the dossier, have said they do not believe it was the trigger for the FBI’s investigation into Russian meddling.

Trump has told aides and confidants that he believes the memo will vindicate his claim early last year that the expansive Russia investigation overseen by Mueller is a “witch hunt.” He has long expressed frustration, both publicly and privately, with his Department of Justice and, specifically, Deputy Attorney General Rod J. Rosenstein, who is supervising Mueller’s work.

Both Rosenstein and FBI Director Christopher A. Wray are Trump appointees.