Obama speechwriter reveals secrets behind Newtown, Nobel addresses President Obama has called Jon Favreau a "mind reader," but on one particular night, the chief speechwriter had no idea his boss was about to address the nation at a crucial moment in his presidency. As special forces prepared to raid Osama bin Laden's compound in Afghanistan, Favreau waited to meet with Obama outside the Oval Office to go over the jokes he had written for the president's address that night at the White House Correspondents" Dinner. His meeting was delayed by a call Obama took from a general in Afghanistan. When the president finally met with Favreau, he made only request: Scratch the reference to bin Laden. ""There's one joke where the punch line is Osama bin Laden. And I would just maybe change that to another dictator,"" Favreau, now 31, recalled being told at the time. I had no idea why he was doing this. So I'm like, "Would Hosni Mubarak work?" He's like, "Mubarak will work great. Why don't we do that? And so we change it. Favreau replaced the al Qaeda leader with the ousted Egyptian president. "And then I found out the next day just like everyone else did," he said in an interview with TODAY's Willie Geist, a portion of which aired Thursday. The incident is a peek into a storied career for Favreau, who on March 1 leaves behind an eight-year partnership with the president that began when he was only 23 and Obama was a U.S. senator from Illinois. The two met under awkward circumstances. "Favs," as he is known, was deputy speechwriter for John Kerry, now Secretary of State but then the Democratic presidential nominee and a senator from Massachusetts, Favreau's home state. During the 2004 Democratic National Convention, Favreau had been sent to ask Obama to cut a line from his speech because it closely resembled one in Kerry's keynote address. "He sort of looked at me as if I was maybe playing a practical joke on him," Favreau said. Years later, Obama recalled that moment while reminiscing about the convention. "He said, "God, I remember that time that kid came in and told me to take out the line,"" Favreau said. "And I was like, "Yeah, that was me.'" Since then, Favreau has helped craft hundreds of speeches for the president and built up a reputation that helped land him as one of Time's "100 Most Influential People in the World" in the same week he ranked among People magazine's most beautiful. He has written some of the president's most memorable speeches, among them, the response to the Rev. Jeremiah Wright. Obama tackled the divisive and controversial comments of his former pastor in one of he few times he has directly addressed the issue of race. Favreau said that while he penned "the easy stuff that almost anyone could write," the most famous line in that speech - "I can no more disown him than I can my white grandmother" - came from Obama. "That's only something that can come from him," Favreau said. Favreau called the president's Nobel Peace Prize acceptance speech a difficult one to write, if only because of the limited time he had to piece it together. The president spent the night before he headed to Oslo, Norway, writing seven pages of material he wanted to use. Favreau and his assistant then spent the next day, and the overnight flight on Air Force One, finishing it. It was actually one of the only moments that we didn't know if we would have a speech ready by the time he gave it. We're usually never like that," he said. While the rest of the staff slept on the plane ride, Obama, Favreau and his assistant worked furiously on revisions and an ending. He (the president) handed us edits literally as he was in the elevators over to the stage. And we put the final words in the prompter right as he was walking up to the podium," said Favreau, who called the moment "uncomfortably close." Like thousands of other mourners, the president was deeply shaken by the mass shootings in Newtown, Conn. Favreau recalled going to the president to pick up the edited version of the statement he was about to deliver. "In the eight years I've known him, I'd never seen him like that," he said. He was looking down at the desk. He barely looked up. He kind of handed me the edits. And he was as somber as I've ever seen him. One of the last major speeches Favreau worked on for the president was his second inaugural address. He called it a difficult one to write. "It was a lot of sleepless nights on that," he said. As usual, Obama made a lot of edits to the speech, writing much of it himself. That ownership showed in his delivery, he said. Favreau said the next major writing project in his life will be a screenplay he wants to tackle with a friend from his Senate staffer days about their experiences from the last decade. That's off in the distance. You know, a couple months down the road," he said. In the meantime, Favreau will stay in Washington for a bit longer and possibly open a small communications shop. He hands off his job to his longtime deputy, Cody Keenan, who most recently wrote the president's State of the Union address. Favreau said Obama will be fine without him. He knows exactly what he wants to say. He's a writer himself. He can write brilliantly. He's an author," he said. You know, my role has always just been helping him figure out exactly how to phrase it. But should the president ever need him, he'll be there. He's told me that once in awhile he might call. And I will pick up the phone. More: New portrait of President Obama unveiled Obama reassures Newtown 'you are not alone' at vigil for victims of shooting Stop gun violence, kids as President Obama in handwritten letters TIME Person of the Year is President Obama