Gina Haspel, the first woman ever nominated to lead the CIA, was formally sworn into the role in a ceremony at the agency's headquarters in Langley, Virginia on Monday. The Senate voted 54-45, to confirm her last week.

"CIA has been more than a career," Haspel, a 33-year veteran of the agency, said. "It has been for me, like many of you, a calling."

In remarks punctuated by sustained applause, Haspel said, "For me, being director is about doing right by all of you, so that you have the tools and support needed to carry out our sacred mission," she said.

Get Breaking News Delivered to Your Inbox

"We must constantly learn, adjust, improve, and strive to be better. We demanded of ourselves, and America deserves nothing less."

President Trump, who was flanked by Vice President Mike Pence, Secretary of State Mike Pompeo and joined by several other cabinet members, delivered a largely scripted introduction to Haspel, calling her "very special" and reciting a summary of her career accomplishments.

"Gina is tough. She is strong. And when it comes to defending America, Gina will never, ever back down," Trump said. "I know her. I spent a lot of time with Gina."

He also thanked the audience of CIA employees, calling them "the most elite intelligence professionals on planet Earth."

"Nobody even close," Trump said.

Gina Haspel (L) is sworn in as CIA director with U.S. Secretary of State Mike Pompeo, President Donald Trump, and Vice President Mike Pence during a ceremony at agency headquarters, May 21, 2018 in Langley, Virginia. Mark Wilson / Getty Images

It marked the first time the president has given public remarks at Langley since January 2017, when he delivered a meandering speech in which he alternated praise for the agency with assertions about the size of his inauguration crowd. The speech raised eyebrows for its campaign-specific subject matter and because it was delivered before the agency's Memorial Wall, which commemorates CIA officers who have lost their lives in the line of duty.

Though he appeared only infrequently to stray from prepared remarks – which were delivered before a generic flag backdrop – on Monday, the president did use the opportunity, as he concluded his speech, to comment on Haspel's contentious confirmation process.

"It took courage for her to say 'yes' in the face of a lot of very negative politics, and what was supposed to be a negative vote," Trump said. "But I'll tell you, when you testified before the committee, it was over. There was not much they could say."

The historic nature of Haspel's nomination was in large part overshadowed by the rancorous, months-long public debate triggered by her background. Her involvement with the agency's enhanced interrogation program – referred to by many as torture – that was implemented in the aftermath of the September 11 attacks generated widespread criticism and concern, as did her role in the subsequent destruction, in 2005, of 92 videotapes documenting some of the interrogations.

Though her three decade-career at the agency was largely spent in the clandestine service and remains classified, Haspel was known in 2002 to have overseen a secret "black site" in Thailand, where at least two detainees were waterboarded. She also, at the instruction of her boss at the time, wrote a cable ordering the tapes' destruction. Subsequent investigations into the tapes found no wrongdoing on her part, but both matters were heavily scrutinized over the course of her hearing before the Senate Intelligence Committee.

In a rare quip, Haspel on Monday also acknowledged the difficulty of navigating her own confirmation battle. "It has been nearly 50 years since an operations officer rose up through the ranks to become the director," she said, "and after the experience of the last two months, I think I know why that is," prompting laughter from the crowd.

Haspel, who at one point reportedly offered to withdraw her nomination over concerns her involvement with harsh interrogations would damage the agency's reputation, credited notes she received from two young girls with motivating her to persist in the process. "To Eliza and Zoe, I would simply say: 'We did it,'" Haspel said.

Still, the swearing-in ceremony itself was not devoid of tension. In a triad of tweets issued earlier on Monday, the president, quoting conservative Fox News commentator Dan Bongino, said former CIA director John Brennan had "disgraced the country" and "the entire Intelligence Community" by, the tweets said, triggering an ongoing investigation into the president's campaign's connections to Russia. Over the weekend President Trump said he would demand that the Justice Department look into whether the Trump campaign was "infiltrated or surveilled" for political purposes.

Brennan, who was appointed by former President Obama and oversaw the agency from 2013 to 2017, has issued his own tweets criticizing the president for, among other things, his "venality, moral turpitude, and political corruption." He called the president's demand for a broadened DOJ inquiry "self-serving" and "harmful" to American democracy.

Later on Monday, after his appearance at the swearing-in, President Trump met at the White House with the heads of the DOJ, FBI and the director of national intelligence about the matter. A readout of the meeting indicated that the DOJ's inspector general would expand an ongoing investigation into the FBI's practices and brief congressional leaders on "highly classified and other information they have requested."

Though not a topic President Trump raised explicitly at Haspel's swearing-in, Trump did call House Intelligence Committee chairman Devin Nunes, who was in attendance, as "a very courageous man." Nunes has led congressional efforts to obtain sensitive documents from the Justice Department related to its investigation.

"Thank you very much, Devin, for being here," the President said at the start of his remarks at Langley. "Appreciate it."