The top US military commander for the Middle East warned Thursday that the United States would need more troops on the ground in Afghanistan to stave off a resurgent Taliban.

General Joseph Votel, who heads US Central Command (Centcom), told the Senate Armed Forces Committee he was currently working on a new strategy to break the war out of a stalemate.

‘I do believe it will involve additional forces to ensure that we can make the advise-and-assist mission more effective,’ he said.

US-led forces have been fighting in Afghanistan for 16 years, making it already longest-ever war for the United States.

The question of whether to double down in the seemingly endless conflict is set to be one of the first major military strategy questions of President Donald Trump's term.

General John Nicholson, who commands NATO forces in Afghanistan, said last month he needs thousands more troops to break the stalemate.

According to Votel, the question of reinforcing US troops in the country is being discussed ‘right now’ between the US military and Defense Secretary Jim Mattis.

Trump has yet to lay out a detailed new strategy for Afghanistan, but during the campaign he reluctantly accepted that US troops would remain.

His predecessor Barack Obama had pledged to pull US troops out of Afghanistan, but proved unable to follow through on the promise faced with the Taliban resurgence.

The NATO alliance has 13,300 troops in Afghanistan, about half of them American, assisting a much larger Afghan force in a war against the Taliban and other Islamist militants.

The United States has a total of 8,400 military personnel in the country, when including the special forces battling Al-Qaeda and the Islamic State group independently from the NATO mission.

Afghan government police and armed forces now take the lead in the battle against the Taliban, which was forced from power in Kabul after the 2001 US-led invasion.

But the Afghans are facing mounting casualties -- their losses in 2016 were up by a third over 2015, with 6,785 killed in the first 10 months of the year -- and losing ground.

Last year was also particularly deadly for Afghan civilians: a UN report found that 11,500 were killed or injured, the most since it began keeping records in 2009.

At least 38 people died Wednesday when gunmen disguised as doctors stormed Afghanistan's largest military hospital in attack an claimed by IS jihadists who are making inroads into the war-battered country.

The assault came just a week after 16 people were killed in simultaneous Taliban suicide assaults on two security compounds in Kabul.

Related Story