Trains have long been a staple of Donald Trump’s iconography. Trane, less so. But the recent North Korea crisis provides a moment to consider the parallels between John Coltrane, the iconic tenor saxophonist who died 50 years ago this summer, and the 45th president.

Trump and Coltrane both began their careers in fairly traditional ways, and each got more esoteric as he got older, producing what some listeners found brilliant and what others called incoherent and hard to listen to. Both are prodigious improvisers, tending to whip up new ideas and thoughts on the spot. And both seem unsure where to stop improvising.

“I don't know what it is,” Coltrane once told Miles Davis, in whose band he was playing. “It seems like when I get going, I just don't know how to stop.” Davis, never one to beat around the bush, replied, “Why don't you try taking the horn out of your mouth?”

This week, some of President Trump’s advisers wish he’d just taken the horn out of his mouth.

On Tuesday, Trump exacerbated a global crisis by laying down a red line for North Korea.

“North Korea best not make any more threats to the United States,” he said. “They will be met with fire and fury like the world has never seen. He has been very threatening beyond a normal statement, and as I said they will be met with fire, fury, and frankly power, the likes of which this world has never seen before.”

That statement stunned many observers, since it was a significant escalation in rhetoric. The U.S. has previously said that North Korea should not be allowed to threaten the United States with nuclear-armed intercontinental ballistic missiles. But to say that the U.S. wouldn’t even tolerate verbal threats? After all, as I noted yesterday, one of the few certainties in the decades-long, failed effort to contain North Korea’s nuclear program is that Pyongyang will make threats. Indeed, within hours, Kim Jong Un was threatening to attack the U.S. territory of Guam.

Just like that, a red line had been drawn and crossed. And that immediate problem obscured the bigger one, which is that, as The Washington Post reported Tuesday, U.S. intelligence agencies think that North Korea may already have the capability to attach nuclear warheads to ICBMs.

Where did Trump come up with the “fire and fury” formulation? As he spoke before cameras in New Jersey, he seemed to be looking occasionally at a sheet of talking points on the table. But it turns out those all pertained to a meeting on the opioid crisis; he declared it “a problem the likes of which we have never seen.” The North Korea remarks, which included a similar phrase, were improvised on the spot, like so many Trane choruses on “Impressions,” according to The New York Times:

His ominous warning to Pyongyang was entirely improvised, according to several people with direct knowledge of what unfolded. In discussions with advisers beforehand, he had not run the specific language by them, though he had talked over possible responses in a general way.

The Times reports that there are differing opinions in the White House about how to handle Korea—a group led by Steve Bannon favors a more conciliatory approach, while National-Security Adviser H.R. McMaster wants a tougher response. Although Trump has used the phrase in question privately,

Neither camp advocated language like “fire and fury,” according to the people involved. Among those taken by surprise, they said, was John F. Kelly, the retired four-star Marine general who has just taken over as White House chief of staff and has been with the president at his golf club in Bedminster, New Jersey, for his working vacation.

Since Kelly took over as chief of staff, he has been credited with some tentative steps to instill discipline in an entropic White House. But as has been clear since Kelly’s appointment, his greatest challenge is not getting his staff in line but figuring out how to channel the president’s energy and prevent surprises. The incident suggests Kelly hasn’t solved that puzzle yet.

White House Press Secretary Sarah Sanders disputed the Times report, but she did not dispute that Trump’s specific wording was improvised.

“General Kelly and others on the NSC team were well aware of the tone of the statement of the president prior to delivery. The words were his own,” she said. “The tone and strength of the message were discussed beforehand. They were clear the president was going to respond to North Korea’s threats following the sanctions with a strong message in no uncertain terms.”

Another well-sourced White House reporter, Josh Dawsey of Politico, reported that Trump’s choice of words was not vetted. “Don’t read too much into it,” he was told.

The problem is that in matters of sensitive international relations, everyone reads a lot into everything, so the specific wording does matter. (There’s a reason treaties hang on painful, lengthy negotiations over specific clauses and phrases.) Once you start improvising, you introduce a whole range of risks, and the dangers on the international stage are far worse than being booed off the bandstand. Mishearings can lead to near shooting. International peace is sometimes built on delicate diplomatic fictions that a sloppy or off-the-cuff remark can undermine.

Plus, you’re liable to box yourself in. During the 2016 presidential election, Trump bluntly diagnosed the problem he saw with Barack Obama’s foreign policy: He hadn’t been tough enough. A prime example of this was Obama’s statement that Syrian use of chemical weapons would constitute a “red line.” Once the Assad regime used apparent nerve agents in 2013, and the U.S. failed to act, it hurt American credibility. As Trump put it during the second presidential debate: “Obama draws the line in the sand. It was laughed at all over the world what happened.”

Arguably, however, Obama’s error was talking too tough: If he was unwilling to take action (a defensible stand, if not one with which everyone would agree), then he should not have bluffed. The irony is that Trump has unwittingly, and improvisationally, committed the same error he so clearly diagnosed. He talked tough on Tuesday, drawing a red line that North Korea was sure to cross, and which it then promptly crossed. Now even his own advisers are unwilling to say that he meant what he said—in part because they don’t want to embrace the alternative, which is to contemplate a shooting war with North Korea that might turn nuclear.

This case hardly stands alone. When Trump spoke at a NATO meeting earlier this summer, his advisers expected him to affirm the U.S. commitment to Article 5, the organization’s mutual-defense clause; instead, the president improvised and dropped it, rattling both allies and his own aides. He tried to pick a fight with the mayor of London over terrorism strategy, irritating Britons.

Improvisation is fun and it is quintessentially American—jazz is America’s classical music, right? But in the midst of a sensitive global showdown, sometimes it’s better to stick to the notes on the page.