North Korea lit some nasty fireworks on July 4th, successfully testing a long-range missile capable of hitting Alaska. The test sent jitters up the spines of American national security officials—for good reason. The Hermit Kingdom hasn’t yet been able to put a nuclear warhead atop an intercontinental ballistic missile, but it is getting there faster than intelligence analysts expected. All the trend lines are bad. Yields from North Korea’s nuclear tests are getting larger. Its arsenal is too, with an estimated 20-25 weapons already, and enough fissile material to crank out a new nuke about every two months. Meanwhile, launch times are getting shorter and missiles are flying longer—much longer. Not all rocket science is rocket science. Even CNN and Breitbart agree that Kim Jong Un is blowing past “nuclear breakout” with breakneck speed.

The big question is what the North Korean leader intends to do.

Think about that for a minute. The most dangerous nuclear threat to the United States requires understanding the intentions of just one man.

Here in Silicon Valley, we are used to believing that engineering can solve the toughest problems and that computers are better than humans at just about everything—from recommending books you might like to conducting complex mathematical calculations, playing chess, or even driving a car. (Okay, I admit that being better than human drivers is no great shakes—my 95-year-old grandmother used to head down one-way streets in Miami the wrong way, claiming, “It’s okay, honey, I’m allowed.”)  As one tech executive told me, soon machines will be better at understanding us than us. Companies are racing to create products that can automatically answer emails just like we would and that can anticipate what we want before we even know it.  Google already remembers my favorite brands better than I do. We hear it everywhere: Phones are smart. Intelligence is artificial. Crowds are wise.

But not in Pyongyang. Penetrating the inner workings of Kim Jong Un’s mind is an old-school challenge, not a high-tech one. North Korea’s nuclear program is a terrifying reminder that technology can only go so far; that human intentions can be unfathomable, even to ourselves; and that divining them is an art, not a science.

Is Kim Jong Un crazy or hyper-rational? Is he bent on destroying America or deterring America? Is his model Soviet leader Nikita Khrushchev, who averted nuclear war by building a large arsenal and threatening to use it? Or is Kim looking at the cautionary tales of Muammar Qaddafi and Saddam Hussein—two men who lost their power and their lives because American presidents either didn’t believe or didn’t care that they had given up their nuclear weapons programs?

Nobody knows.

Understanding the intentions of adversaries has always been fraught. Wars often occur because one side miscalculates the other’s willingness to fight. But North Korea has long been in a league of its own. Back in the 1990s, American officials lamented that Pyongyang was the “hardest of hard intelligence targets.” As late as 2009, the CIA was compiling its dossier of Kim Jong Un, then the heir apparent, based on secondhand reports from a sushi chef. When junior took the Hermit Kingdom helm in 2011, experts were all over the map. Some saw Kim Jong-un’s early moves—including public statements about ending “belt tightening” and rumored plans to start decollectivizing farms—as a sign that North Korea might be moving toward Chinese-style economic reforms. A few thought that political liberalization might not be so far-fetched. Others were more skeptical, warning that Kim was no reformer, despite his love of professional basketball and pizza. About the only points of agreement among Korea watchers in those days were that Kim liked Disney characters and dour, throwback haircuts. But even on this last point, it’s still unclear whether Kim’s dress is for show or for real—is it a deliberate ploy to make himself look like his popular grandfather? Or is that just the North Korean strongman uniform?

The Trump administration has to figure out what Kim Jong Un wants, how he sees the world, and how the United States can signal its intentions to defend itself and advance our vital interests without fighting a war that Secretary of Defense James Mattis recently said could be “catastrophic.” There is no algorithm for that.