The official said the language of Mr. Ghani’s letter was broad — asking for teams from both sides to discuss details of where costs could be reduced, and how the troop levels could be brought down from the current 14,000 to a “more efficient level.”

The official said the possibilities they had envisioned could save as much as $2 billion a year for the United States, drawing from areas such as maintenance contracts, and reduce the level of American troops to as low a 3,000.

Mr. Ghani alluded to such savings during an appearance last week at the World Economic Forum in Davos, Switzerland, in which he argued for caution in any American withdrawal.

“The United States as a sovereign power, as a global power, is entitled to leave,” he said. “But we need to get the departure right. Are the fundamental reasons that brought the United States to Afghanistan — are those objectives accomplished? The first issue is cost. We completely agree that the cost must come down, must become more efficient.”

The United States Embassy in Kabul declined through a spokesperson to comment on Mr. Ghani’s letter to Mr. Trump, saying “we are not going to get into the specifics of diplomatic conversations.”

It was not immediately clear on Tuesday whether Mr. Trump had received the letter yet. It was sent to him via Alice Wells, the principal deputy assistant secretary for South and Central Asia, who had been visiting Kabul. A spokesman for Mr. Ghani also declined to discuss the letter.

Mr. Ghani has found himself increasingly at odds with other members of the Afghan political elite, who are now rallying around the American effort to negotiate with the Taliban. They are painting Mr. Ghani as an obstacle to peace.