GULIBAGH - Hazrat Gul spent two years in detention for allegedly aiding the Taliban when they publicly flogged and beheaded people during a reign of terror in the scenic Swat Valley.

Now he whiles away his time in pristine classrooms, a Pakistani flag pin on his crisp uniform, learning about word processing, carpentry and car repairs at the Mashal de-radicalisation centre run by the army.

Part of a carrot and stick approach to battling militancy in the strategic US ally, the aim is to cleanse minds of extremist thoughts through vocational training, and turn men like Gul into productive citizens who support the state. The success of the programme will ultimately hinge, however, on the ability of the government to help the de-radicalisation graduates find jobs. “If a sincere leadership comes to this country, that will solve the problems,” said Gul, 42, one of the Mashal students. “Today the leadership is not sincere. The same problems will be there.”

Military drove militants out of Swat in 2009. Mashal is in the building which used to be the headquarters of the militants from where they imposed there austere version of Islam.

Eventually, the army realised it couldn’t secure long-term peace with bullets alone.

So military officers, trainers, moderate clerics and psychologists were chosen to run three-month courses designed to erase “radical thoughts” of those accused of aiding the Taliban.

Students like Mohammad Inam, 28, a former assistant engineer, give the school a good report card. “The environment is very good. Our teachers work very hard with us. They talk to us about peace, about terrorism and how that is not right,” said Inam, in the presence of a military officer. “God willing, we will go out and serve our country and our nation.”

School officials say about 1,000 people have graduated since the initiative began two years ago, and that only 10 percent were not cleared for release.

Officials concede that their “students” are not hardened militants who killed. Mostly, they provided the Taliban with water, food or shelter, or beat people.

That was enough for a two-year detention, and some say abuse, in a country where the Taliban stage suicide bombings at will and have launched brazen attacks, including one on the army headquarters near the capital. Even if the Mashal institute instils a new mindset and discipline in the students, graduates face an uncertain future. “The problem is the deprivation being faced by these individuals. There is no electricity. There are price hikes. There is no law and order or justice which prevails in the country,” said Major Khurram Bajwa, one of Mashal’s directors.

He pointed out how easy it is for the Taliban to recruit people. “It takes about two years to train an army officer, and one month to train a suicide bomber.”

Military presents the Swat offensive and the campaign to root out extremism as a showcase of its success against militancy. On the surface, the valley looks far more stable than it did in the Taliban days when Fazlullah, known as FM Mullah for his fiery radio sermons, was ordering his men to take to the streets and punish the “immoral”, or anyone who disagreed with his violent philosophy. Residents of Swat, 160 km from Islamabad, crowd street markets. Girls schools that were blown up by the Taliban have reopened. A ski resort burned down by the Taliban has re-opened.

That is due in large part to a sense of security created by the thousands of Pakistani soldiers still stationed there.

But the army’s successes have been tarnished by allegations of human rights abuses.

Human Rights Watch says it has received credible reports of extrajudicial killings allegedly committed by soldiers or police in Swat. The army counters that it takes human rights seriously and has launched an investigation into the matter.

Outside Mashal’s classroom, there are signs that not everyone is embracing the new approach.

Soldiers led a hooded man into a truck while three others looked on through the barred windows of what appeared to be a cell at the compound.

Conditions still seem ripe for Fazlulah and his lieutenants, who have vowed to make a comeback, to recruit people.

Officials estimated after the army operation expelled the Taliban that over $1 billion would be needed to revive the local economy and rebuild infrastructure.

Residents like Ajab Noor, 61, who sent two of his sons abroad to work, doubt the population of about 1.3 million will ever benefit from those funds.

“People have no options. They either go outside the country to work, or they join militants who promise them many things,” he said at a street market in Swat’s capital, Mingora.

A member of a state-backed anti-Taliban militia believes two boys in his village had graduated from a de-radicalisation centre and ran away to rejoin the Taliban.

“I told the military, ‘you are nurturing the offspring of snakes’. But they did not listen,” he said.