President Trump plans to meet with North Korean leader Kim Jong-un by May, according to an announcement made outside the White House by South Korean National Security Adviser Chung Eui-Yong on Thursday night. White House Press Secretary Sarah Huckabee Sanders says the summit will take place at a “time and place to be determined.”

Chung, who met with Kim in Pyongyang earlier this week before heading to Washington to brief Trump, said he had hand-delivered an invitation from the isolated North Korean chairman, whom Trump recently referred to derisively as “Little Rocket Man.” North Korea’s state media has in turn referred to Trump as a “mentally deranged U.S. dotard.”

This is a major development. No sitting U.S. president has ever met with a North Korean leader or visited North Korea. (Jimmy Carter and Bill Clinton did so after leaving office.) If the meeting takes place outside North Korea, it will be the first time Kim has left the country since taking office.

It’s also a fairly dramatic reversal from Trump, who previously described negotiations with North Korea as a waste of time. As recently as last Saturday, Trump said that North Korea would have to “de-nuke” before he would consider talks. Chui did say that North Korea was willing to halt nuclear and missile tests while talks took place—which we already knew on Monday. That’s not the same as giving up its nuclear weapons, and North Korea has made similar pledges in the past, but just the fact that they were willing to discuss denuclearization was apparently enough to satisfy Trump.

Kim did reportedly tell the visiting South Koreans he would be willing to denuclearize, if it felt its security was guaranteed. That’s a big if. Tong Zhao—an analyst at the Carnegie-Tsinghua Center in Beijing who meets regularly with North Korean officials—told me by email, “There is no way the United States can reassure North Korea on that security issue to its full satisfaction in the near-term future. In other words, North Korea’s attitudes about denuclearization have not changed.” The purpose of the proposed meeting, Tong wrote, was likely to, “to make the international community–including and especially the US–accept North Korea’s nuclear reality and to relax the increasingly tighter economic noose around Pyongyang’s neck.”

As Fred Kaplan wrote earlier this week for Slate, even if the underlying issues seem nearly impossible to resolve in the near term, talks are a good thing, especially considering how close to war the two sides looked just a few weeks.

But there’s definitely cause for concern about Trump being the one doing the talking, considering his habit of consulting zero experts prior to important meetings and his demonstrated willingness to say whatever it takes to make the people in the room with him happy—whether that’s congressional Democrats talking about gun control or the president of China. And as Trump’s visits to Saudi Arabia and China have shown, he’s nothing if not susceptible to pomp and hyperbole—two things North Korea’s government excels at.

When he was building up hype for the announcement this afternoon, Trump told one reporter, “I hope you will give me credit.” He absolutely should get credit if, and only if, this very risky gamble pays off. But given that securing a summit with a U.S. president has been a major foreign policy goal of the world’s most isolated government for decades, the leader who should really be getting some credit for his diplomatic savvy today is Kim.