The Iraqi army’s recent triumph in Ramadi made it clear that its soldiers aren’t cut from the same cloth as those who ditched their gear and fled in terror from the Islamic State group in 2014 — and Marines have been a pivotal part of that transformation.

Hundreds of Marines have been quietly deploying over the past 16 months to assist the Iraqis fighting to retake territory, hard won by U.S. troops over the past decade or more, from brutal ISIS militants.

As 2015 drew to a close, the Iraqi army hoisted its flag above the center of Ramadi’s city center and declared victory. The seven-month struggle to retake the gateway city in western Anbar province was bloody and costly, but dealt ISIS a strategic blow and proved that the Iraqi military — with coalition air support — is capable of sustained offensive operations.

It also opened the door to greater U.S. involvement and a follow-on drive to retake the northern city of Mosul.

But Marines have played a “critical role” in Operation Inherent Resolve, the Defense Department’s campaign against the terror group, Marine Commandant Gen. Robert Neller told Marine Corps Times last month. The Marine Corps’ mission in Iraq has been a quiet one, in part because ISIS vowed to seek revenge on anyone responsible for bombing the group’s strongholds in places like Iraq and Syria. Last year, the group’s so-called hacking division released the names, photos and addresses of 100 U.S. troops, calling on supporters inside the U.S. to carry out attacks against them.

“I think we have shown a lot of flexibility,” he said.

From April to October, for example, Marines with Special-Purpose Marine Air-Ground Task Force–Crisis Response–Central Command flew more than 8,300 combined flight hours, delivered almost 2.8 million tons of cargo throughout the region and launched airstrikes against ISIS strongholds on a daily basis.

They directly trained Iraqi soldiers and advised and assisted Iraqi leadership to ensure accurate intelligence and precise airstrikes. They kept watch over the U.S. Embassy in Baghdad and remote military outposts, and stood at the ready to recover downed aircraft and pilots at a moment’s notice. They also worked side-by-side with America’s regional allies to prepare them for the fight.