A tentative deal between President Donald Trump and North Korean leader Kim Jong Un to be finalized over the next two days at their summit in Vietnam has emerged — and while it may still change, the current agreement looks like a huge win for Kim.

For the US? Not so much.

Under the current iteration of the agreement, described to me by three people familiar with the negotiations who spoke on condition of anonymity to discuss sensitive diplomatic issues, the US would agree to lift some sanctions on North Korea and improve ties between the two countries in exchange for a commitment from Kim Jong Un to close down a key nuclear facility.

Here’s the outline of the tentative deal as described to me:

Both countries will sign a peace declaration to symbolically end the Korean War. That conflict ended in an armistice (basically a truce), not an actual peace treaty, in 1953, which means the war is technically still ongoing. The agreement would effectively, although not officially, end hostilities between the two countries and dramatically improve their relations. North Korea will agree to return more remains of US troops who died during the Korean War, although it’s unclear how many of the thousands will come home and when. Last year, following the Trump-Kim summit in Singapore, North Korea returned the remains of 55 American service members. The US and North Korea will establish liaison offices — which are quasi-embassies with minimal authorities — in each other’s nations. That will be the first concrete step toward normalizing diplomatic ties between the two longtime enemies. North Korea will agree to stop producing materials for nuclear bombs at its Yongbyon facility. In exchange, the US will push to lift some UN sanctions on Pyongyang so it can pursue joint economic projects with South Korea. It’s also possible the deal will include some other nuclear facilities, one source said.

Again, it’s entirely possible that this tentative deal will change — perhaps even dramatically — between now and when Trump and Kim meet on February 27 in Vietnam. But the deal as it currently stands comports with what many expected heading into the summit.

In other words, it isn’t a major surprise that this is the deal on offer. The problem, though, is that Trump may be giving more than he’s getting.

Why this deal is both good and bad for Trump

If agreed to, the most controversial part of this deal will be the promise from Kim to shutter the Yongbyon facility in exchange for some modest sanctions relief.

Here’s why: The people familiar with the current deal say there are no specific details and no timetable for how North Korea will end nuclear fuel production at the Yongbyon facility. Instead, Trump and Kim will agree in principle to the closure and working-level staff will finalize the details in future talks.

That’s likely to pique some North Korea experts.

The Yongbyon nuclear facility is “the heart of [North Korea’s] nuclear program,” a top expert told the Washington Post last week. It’s the only place (that we know of) where the country can make plutonium for nuclear bombs. If it shuts down, Pyongyang’s ability to make plutonium-fueled nuclear weapons will be severely curtailed.

That wouldn’t mean the end of its nuclear program — not by a long shot — but it would be a concrete gesture that would help signal that Kim may actually be serious about dismantling the program eventually.

That said, it’s one thing for Kim to say he’ll close the facility, and another thing entirely for him to actually do so.

Rebecca Hersman, a nuclear expert at the Center for Strategic and International Studies, told me that for this to be a real concession, Kim would have to let international inspectors into the facility to verify that nuclear material production had really ended. Without those inspections, there’s no way to know if Kim has followed through on his promise.

That’s a move the leader may be reluctant to take. And even if he did so, he could always just restart the shuttered facility once the inspectors left — as his father, Kim Jong Il, did twice before, after deals with the US collapsed.

That, in part, is why experts want any deal on closing Yongbyon to be extremely detailed. “An agreement on the dismantlement of such a site has to be worded deliberately and concisely so technical experts can watch and verify each step in the process,” said Grace Liu of the Middlebury Institute of International Studies.

But if Trump moves to lift sanctions before Kim actually ends all production at Yongbyon, he will have offered a major concession without getting anything substantive in return.

The rest of the deal, however, looks pretty good.

By signing a peace declaration, both sides will reduce tensions with one another by saying they are no longer warring enemies. By establishing liaison offices, Washington and Pyongyang will take an important step toward normalizing their relations. And by returning more troop remains to the US — something people close to the negotiations tell me is personally very important to Trump — North Korea will show it’s serious about staying in America’s good graces.

So there’s a lot to like in this potential deal. But it doesn’t really move the needle much on the fundamental goal of denuclearizing North Korea, and mostly just rewards Kim with much-needed sanctions relief for doing little more than continuing to show up for talks and making some vague promises. It that sense, the deal isn’t great for Trump but is a pretty big win for the North Korean leader.

But if this serves as a building block to more deals down the line — leading North Korea to dismantle its nuclear program in the long run — then it’s possible we’ll all look back on Hanoi fondly in a few years’ time.