So, after three years of mutual chest-beating, North Korea has agreed to give up its nuclear weapons programme. And in exchange, it gets what it wanted all along: a security guarantee from the United States. You really have to wonder why the hell it took them so long.
There are details yet to be worked out - whether the US will supply light-water reactors for electricity generation (exactly as they agreed to do and then reneged on previously), and on the verification regime. But the framework is in place, and the world is safer for it. Not just because the threat of proliferation has been reduced, but because there's that much less chance of the Americans starting a conventional war on the Korean peninsula in an effort to halt it. The cost of that would have been horrific - North Korea has thousands of artillery pieces pointed at Seoul, and the estimated casulaties would run to several hundred thousand dead civilians in the first hour alone - and it was well worth avoiding.
There is a danger that the deal won't stick - but it is better for America to go for it and try and verify it and make it work than expect the South Koreans to die in droves for the safety of others.