US has been negotiating with the Taliban to reach a peace agreement ending the 18-year war.

Two US soldiers were killed in action in Afghanistan on Monday, NATO announced -- the latest international military casualties as Washington seeks a way out of America's longest war.

"The name of the service members killed in action is being withheld until 24 hours after notification of next of kin is complete," Resolute Support, the US-led NATO mission in Afghanistan, said in a statement.

The death brings to 12 the number of members of the US military to be killed in action this year.

For the past year, the United States has been negotiating with the Taliban to reach a peace agreement ending the 18-year war.

Washington seems eager to speed up the talks as Afghanistan prepares for a presidential election in September and America gears up for the 2020 presidential election.

US President Donald Trump says he wants to begin withdrawing troops before the 2020 vote, Secretary of State Mike Pompeo said Monday.

"He's been unambiguous: end the endless wars, draw down," said Pompeo.