Updated

A standoff between Nepal's king and the political elite could lead to the communist rebels taking over the Himalayan nation, the U.S ambassador said Wednesday, hours after insurgents killed three soldiers in an ambush.

Ambassador James Moriarty said the Maoist guerrillas had made "massive gains" in the past decade, and he warned that a recent alliance between the major political parties and the rebels to press for democracy "is fraught with danger."

If the Maoist insurgents and the parties successfully topple the monarchy, "the Maoists will ultimately seize power, and Nepal will suffer a disaster that will make its current problems pale in comparison," Moriarty said.

The rebels, who say they are inspired by Mao Zedong, have fought for a decade to establish a communist Nepal. The insurgency has claimed nearly 13,000 lives.

King Gyanendra seized control of the government in February 2005, saying he needed to quell the bloody rebellion and bring order to a chaotic and corrupt political scene that had alienated many of Nepal's 27 million people.

The country's major political parties since have demanded that democracy be restored, but the monarch has conceded little ground. Instead, he has cracked down on protests and jailed hundreds of politicians, student activists and human rights campaigners.

Moriarty said that "if the king and his government opt for greater repression, their attempts will ultimately fail and Nepal will suffer greater misery and bloodshed."

Frustrated with the king's rigid posture, the political parties reached a deal with the rebels in November to work together to counter the royal government, agreeing that the parties would use peaceful means and the rebels violence.

Former Foreign Minister Ram Sharan Mahat, a leader of Nepali Congress — one of the seven parties that have teamed up with the rebels, said the deal was a risk "worth taking."

"We still believe that the Maoists can be persuaded to join the political mainstream," Mahat said.

But the U.S. envoy said the deal between the parties and rebels was "wrongheaded," and the king and parties must reconcile for Nepal's crisis to end.

He said the standoff was encouraging the rebels, and "as long as there is no coherent strategy in place to roll back the massive gains the Maoists have made over the past decade, the Maoists will rightfully conclude they are winning."

If the king falls, Moriarty said, "the Maoists would be armed; the parties would be unarmed ... This stark scenario leaves the parties, and the people, defenseless against ideological 'partners' long used to settling arguments with a gun."

The latest rebel attack came early Wednesday when the insurgents ambushed an army patrol near Bibeke, about 150 miles west of Katmandu, killing at least three soldiers and injuring two others, a Royal Nepalese Army official said.

The ensuing battle lasted until dawn, when reinforcements reached the mountainous area and the guerrillas fled, the official said on condition of anonymity according to army policy.

A number of rebels also were believed to have been killed, he said.

Nepal's embattled royal government continued its crackdown on opponents of the king's direct rule Wednesday, a day after a former prime minister and dozens of other political figures were released from detention.

Two senior leaders of the Communist Party of Nepal said Wednesday they eluded arrest at their party's office by escaping on motorcycles through back alleys.

Police surrounded the office late Tuesday searching for Bam Dev Gautam and Jhal Nath Khanal, who have been on the run since the government began its crackdown.

"We managed to escape another attempt by the government to arrest us," Gautam told The Associated Press by telephone.

An international rights group, meanwhile, warned that 10 years of the insurgency have pushed this Himalayan nation to the verge of a humanitarian disaster.

New York-based Human Rights Watch said the rebels "must immediately demonstrate that they will respect human rights standards and the laws of war and end abuses against civilians and accept their share of blame" for the country's present condition.

The rebels have long been accused of killing vocal critics, stealing from poor villagers and pressing young men and women into service.