The head of Thailand's military junta and the prime minister are visiting the country's restive south, where violence has become endemic over nearly three years. the new government of predominantly Buddhist Thailand is reaching out to the mostly Muslim south but has no illusions that the violence will end soon.

Prime Minister Surayud Chulanont has said that restoring peace to southern Thailand is one of his main priorities. Residents in the region, who are mostly ethnic Malays, have long complained that they are treated as second-class citizens. Mr. Surayud says the problems are rooted in injustice.

His month-old government, installed by the military after a September 19 coup deposed former prime minister Thaksin Shinawatra, has already revived a mediation agency in the country's southernmost provinces. Mr. Thaksin had dissolved the Southern Border Provinces Administration Center in his pursuit of a hard-line approach to unrest in the region.

On Thursday, Mr. Surayud went further, publicly apologizing in the town of Pattani for the harsh policies of the past.

"I came here today, to reach out to you with my hands and apologize for the mistakes of the past," he said. He promised to use peaceful means to solve the south's problem

Thai analysts say the current violence, which has claimed more than 1700 lives, is different, and more daunting, than past rebellions because the militants responsible for the profusion of roadside bombings and drive-by shootings are more difficult to identify.

Thai security officials say most of the attacks are carried out by a new generation of village-based militants who are part of a loose network of small cells scattered throughout the region.

Sondhi Boonyaratglin, the Muslim general who led the coup against Mr. Thaksin and accompanied prime minister Surayud to the south Thursday, says it will take a long time for peace to be restored in southern Thailand.

Mr. Surayud promised to purge what he called wrongdoers from within the ranks of civil servants in the region.

Kraisak Choonhavan, a former senator, says security officials must not only be purged, but held accountable for cases of abusive behavior toward local residents.

"This entails sacrifices, in fact, even punishment, of the wrongdoers, meaning on the government side, the security side, that has put to death a lot of people, that has violated a lot of human rights in the past," he said.

Thailand's new government is also saying it is willing to talk to the insurgents. But until all those behind the violence are identified, few Thais expect the unrest to end.