Tens of thousands of pro-democracy protesters have celebrated what they described as the fall of the Yemeni government after Ali Abdullah Saleh, the long-serving president, left the country for medical treatment in Saudi Arabia.

The president has undergone two operations "with success" to remove shrapnel from his upper body and perform neurosurgery on his neck, according to a Saudi official.

"Today, Yemen is newborn," sang dozens of youths on Sunday in Sanaa's University Square, dubbed "Change Square", which has been the epicentre of anti-government protests that have raged since February.

Protesters also danced and slaughtered cows to revel in Saleh's departure.

In Yemen's second-largest city Taiz, a flashpoint of anti-government demonstrations south of the capital Sanaa, hundreds also celebrated, chanting: "Freedom, freedom, Ali has fled".

Meanwhile, the al-Ahmar group, leading Yemen's Hashed tribal federation that has been locked in battle against troops loyal to Ali Abdullah Saleh, has agreed to abide by a day-old truce, the opposition said on Sunday.

Abd-Rabbu Mansour Hadi, the acting president, has offered to withdraw troops from the Sanaa neighbourhood that has seen the heaviest fighting and lift roadblocks for the main routes into the capital.

Saudi officials said Saleh was in their capital, Riyadh, for treatment only and that the visit was not a political one. They also said Saleh would return to Yemen after two weeks.

But Yemen's opposition has vowed not to let Saleh return from Saudi Arabia.

"We will work with all our strength to prevent his return," Mohammed Qahtan, Yemeni parliamentary opposition spokesman, told the AFP news agency. "We see this as the beginning of the end of this tyrannical and corrupt regime."

Medical treatment

Saleh left for Riyadh on Saturday after he was injured in an attack on his compound in Sanaa a day earlier, the Saudi royal court said in a statement on Sunday.

He flew to Riyadh on a Saudi medical aircraft and was immediately taken to a military hospital at King Khalid Air Base, while a second aircraft carried members of his family.

Saleh walked off the aircraft but had visible injuries on his neck, head and face, a source told Reuters news agency.

Once he recovers from the first two surgeries, Saleh is also expected to have plastic surgery to mend wounds on his face and neck.

Saleh's departure has raised speculations over whether he is going to return to Yemen again.

The rocket attack on the presidential palace, which killed 11 people, devastated the government.

The prime minister, two deputy prime ministers and the speakers of both parliamentary chambers are being treated in Riyadh for injuries.

'End of Saleh's rule'

The rocket attack on Saleh's presidential palace marked a major escalation in the four-month-long uprising against his 33-year rule.

Al Jazeera's Hashem Ahelbarra, who has reported extensively on Yemen, said Saleh's retreat to Saudi Arabia spelled the end of his rule.

"If he was seriously injured then he would need long treatment in Saudi Arabia and Yemen cannot stand a protracted power vacuum," he said.

"If he was just suffering minor injuries then I would assume it would have made sense for him to be treated in Yemen. The fact that he was flown to Saudi Arabia says a lot about the end of the Saleh era."

State news agency Saba reported that Hadi, the country's vice-president now acting president and supreme commander of the armed forces, held talks with Gerald Michael Feierstein, the US ambassador, on Sunday.

However, our correspondent said the vice-president was more of a "window dressing" until a transitional council could be formed.

"The opposition and the tribal establishment will say they are now the ones to dictate a new deal," Ahelbarra said.

"You have the powerful tribal leaders, the disenchanted generals who joined the pro-democracy movement and the Islamists who are the most organised and largest opposition party that will definitely sit down and draft a new law about the transition and who should oversee it.

"Saudi Arabia has leverage, cash, border, and historical political influence. They will talk to tribal leaders, give them money, and instruct them what to do and what the exit strategy is," our correspondent said.

Heavy gunfire

Amid the celebrations, heavy gunfire and explosions were reported in Sanaa on Sunday, witnesses said, just a day after a Saudi-brokered truce.

Live Box 201131716250932154

The gunfire was centred on the Hasaba district, a focal point of fighting in recent weeks between Saleh's forces and members of the powerful Hashed tribe led by Sadiq al-Ahmar.

Two people were killed and 15 others were injured when a bomb exploded at the headquarters of the Yemeni 1st armoured division in Sanaa.

Elsewhere, about 200km south of Sanaa, armed men stormed buildings in Taiz and gun battles broke out in the city, prompting protesters to form committees to try to keep the peace. At least two people were reported dead and several others injured.

Meanwhile, witnesses said Yemeni fighters had ambushed an army checkpoint in the southern city of Aden. And, after news spread that Saleh had left the country, an activist and a witness said military forces had withdrawn from checkpoints there.

Yemen's crisis has transformed in recent weeks from a peaceful uprising to a struggle between two of Yemen's most powerful families - Saleh's, which dominates the security forces, and the al-Ahmar clan, which leads Yemen's strongest tribal confederation.

The confederation groups together about 10 northern tribes.

Al-Ahmar announced the Hashed's support for the protest movement in March, and his fighters adhered to the movement's non-violence policy. But last week, Saleh's forces moved against al-Ahmar's fortress-like residence in Sanaa, and the tribe's fighters rose up in response.

Source: Al Jazeera and agencies