TUNIS, Tunisia -- In a defiant speech, Tunisia's prime minister rejected opposition demands that his government step down and promised on Monday to complete the country's democratic transition with a new constitution by August and elections in December.

The assassination of two opposition legislators over the last six months has plunged Tunisia – the birthplace of the Arab Spring – into a crisis with anti-government protests, the resignation of a Cabinet minister, and a walkout by dozens of lawmakers.

The standoff was given extra urgency by a bloody ambush that took place Monday in a mountainous region near the Algerian border known as a hideout for Islamic militants that left at least 9 soldiers dead, according to a local hospital.

Prime Minister Ali Larayedh's fiery speech, in which he called those wanting to dissolve the government "anarchists" and "opportunists," is unlikely to appease an angry opposition that says the Islamist-led government has failed to carry out the political transition promised after the overthrow of Tunisia's dictator in January 2011.

With many of the countries that saw pro-democracy uprisings during the Arab Spring heading toward chaos or renewed authoritarianism, Tunisia was considered the best hope for democracy in the region – until its current crisis.

On Thursday, left-wing Tunisian politician Mohammed Brahmi was assassinated in Tunis, shot 14 times outside his home in front of his family. That followed the killing of another left-wing opposition legislator, Chokri Belaid, in February.

On Sunday night, thousands of people demonstrated in front of the elected assembly charged with writing the country's new constitution and demanded that it be dissolved along with the government. Dozens of opposition lawmakers have suspended their participation in the assembly, and Education Minister Salem Labiadh submitted his resignation on Monday.

Even more serious for the government, the governing coalition appears to be breaking apart. Mohammed Bennour, spokesman for the left-of-center Ettakatol (Forum) Party, said his group wants to withdraw from the coalition and dissolve the government. That would leave the moderate Islamist Ennahda Party that dominates the coalition even more isolated.

But Larayedh struck a defiant note in his speech, maintaining that the "dissolution of the assembly and the government would not help the situation or gain us time."

In his televised speech, during which he often banged on a podium, he presented a road map for completing the long drawn out democratic transition with a new constitution by the end of August and the passage of the needed election laws by Oct. 23 – the anniversary of the date in 2011 that brought the Ennahda Party to power.

He said an election for a new legislative body would be held on Dec. 17, the third anniversary of the self-immolation of itinerant fruit seller Mohammed Bouazizi that sparked the uprising that overthrow dictator Zine El Abidine Ben Ali a month later.

The constitutional assembly was supposed to write a constitution and hold new elections within a year. Instead the transition has dragged on for nearly two years as the country has been beset by social unrest, a faltering economy and terrorist attacks.

Larayedh promised to hold "free and fair elections under international supervision" and said the government is open to any dialogue and proposals to complete the transition. He said he is even open to a Cabinet reshuffle.

"Dialogue should not be in the streets or through violence but at the table and about strategies and plans," he said.

Larayedh maintained, however, that those calling for dissolving the assembly and government were small groups, and he threatened to mobilize government supporters against them to preserve public order.

On Sunday night, thousands of government supporters did come out to confront those protesting in front of the assembly and police had to separate them.

Interior Ministry spokesman Mohammed Ali Aroui said Monday that security forces committed some abuses while dispersing protesters with tear gas early Monday. But he defended their efforts to avoid what he called a "blood bath" between the rival demonstrations.

There also have been anti-government protests in several cities in the interior of Tunisia since Thursday's assassination.

____

Schemm contributed to this report from Rabat, Morocco.

Earlier on HuffPost:

Loading Slideshow...
  • A Tunisian supporter of the Popular Front party reacts at Mahmoud Materi hospital, after Mohammed Brahmi died from his wounds after he was shot to death in his car outside his home, north of Tunis, Tunisia, Thursday, July 25, 2013. (AP Photo/Amine Landoulsi)

  • Tunisians take part in an anti-government demonstration outside the Interior ministry on July 26, 2013 in Tunis after the killing of the opposition politician Mohamed Brahmi. (FETHI BELAID/AFP/Getty Images)

  • Tunisians take part in an anti-government demonstration on the Habib Bourguiba Avenue on July 26, 2013 in Tunis after the killing of the opposition politician Mohamed Brahmi. (FETHI BELAID/AFP/Getty Images)

  • The widow of murdered opposition figure Chokri Belaid, Basma Khalfaoui (C) takes part in an anti-government demonstration on the Habib Bourguiba Avenue on July 26, 2013 in Tunis after the killing of the opposition politician Mohamed Brahmi. (FETHI BELAID/AFP/Getty Images)

  • Demonstrators try to remove barbed wire that blocks the access to the Interior ministry on July 26, 2013 in Tunis after the killing of the opposition politician Mohamed Brahmi. (FETHI BELAID/AFP/Getty Images)

  • Tunisian protesters shout slogans during an anti-government demonstration on the Habib Bourguiba Avenue on July 26, 2013 in Tunis after the killing of the opposition politician Mohamed Brahmi. (FETHI BELAID/AFP/Getty Images)

  • A Tunisian protester raises up a national flag near security forces during an anti-government demonstration on the Habib Bourguiba Avenue on July 26, 2013 in Tunis after the killing of the opposition politician Mohamed Brahmi. (FETHI BELAID/AFP/Getty Images)

  • Mubarka Brahmi (L), the wife of opposition politician Mohamed Brahmi, and his son, mourn at their home in Ariana, outside Tunis, after Brahmi was gunned down in front of his home on July 25, 2013. (FETHI BELAID/AFP/Getty Images)

  • Protesters gather on the main avenue of Tunis after the leader of a leftist Tunisian opposition party, Mohammed Brahmi, was gunned down as he left home, in Tunisia, Thursday, July 25, 2013. (AP Photo/Hassene Dridi)

  • Protesters gather on the main avenue of Tunis after the leader of a leftist Tunisian opposition party, Mohammed Brahmi, was gunned down as he left home, in Tunisia, Thursday, July 25, 2013. (AP Photo/Hassene Dridi)

  • In this photo dated Thursday, July 25, 2013, assassinated Tunisian opposition politician Mohammed Brahmi's daughter, Balkis, holds a Tunisian flag as she mourns his death at Mahmoud Materi hospital, north of Tunis, Tunisia. (AP Photo/Amine Landoulsi)

  • Tunisians shout slogans in front of the Interior Ministry after the killing of opposition politician Mohamed Brahmi early on July 26, 2013 in Ariana, outside Tunis. (FETHI BELAID/AFP/Getty Images)

  • A Tunisian supporter of the Popular Front party reacts at Mahmoud Materi hospital, after Mohammed Brahmi died from his wounds after he was shot to death in his car outside his home, north of Tunis, Tunisia, Thursday, July 25, 2013. (AP Photo/Amine Landoulsi)

  • A Tunisian supporter of the Popular Front party reacts at Mahmoud Materi hospital, after Mohammed Brahmi died from his wounds after he was shot to death in his car outside his home, north of Tunis, Tunisia, Thursday, July 25, 2013. (AP Photo/Amine Landoulsi)

  • A Tunisian plainclothes police officer secures the house of Mohammed Brahmi after he was shot to death outside his home in Tunis, Tunisia, Thursday, July 25, 2013. (AP Photo/Amine Landoulsi)

  • TUNISIA-POLITICS-ASSASSINATION

    Mubarka Brahmi (C-L), the wife of opposition politician Mohamed Brahmi, receives condolences from Tunisians at her house in Ariana, outside Tunis, after Brahmi was gunned down in front of his home on July 25, 2013. Tunisia marked a day of mourning after gunmen killed Brahmi, sparking fresh political turmoil, protests and a general strike which took Tunis to near standstill. AFP PHOTO / FETHI BELAID (Photo credit should read FETHI BELAID/AFP/Getty Images)

  • Tunisian lawyer Leila Ben Debba (C) reacts outside a hospital after the killing of opposition politician Mohamed Brahmi on July 25, 2013 in Ariana, outside Tunis. (FETHI BELAID/AFP/Getty Images)

  • Tunisians react in a hospital after the killing of the opposition politician Mohamed Brahmi on July 25, 2013 in Ariana, outside Tunis. (FETHI BELAID/AFP/Getty Images)

  • Belkaeis Brahimi, the daughter of Tunisian opposition politician Mohamed Brahmi, shouts slogans outside a hospital after her father was killed on July 25, 2013 in Ariana, outside Tunis. (FETHI BELAID/AFP/Getty Images)

  • Tunisians react outside a hospital after the killing of the opposition politician Mohamed Brahmi on July 25, 2013 in Ariana, outside Tunis. (FETHI BELAID/AFP/Getty Images)

  • Tunisian police officers inspect Mohammed Brahmi's car in which he was shot to death outside his home in Tunis, Tunisia, Thursday, July 25, 2013. (AP Photo/Amine Landoulsi)

  • Supporters of the Popular Front party gather at Mahmoud Materi hospital, north of Tunis, in support of Mohammed Brahmi who was shot to death in his car outside his home, in Tunisia, Thursday, July 25, 2013. (AP Photo/Amine Landoulsi)

  • Tunisians react outside the hospital in Ariana, outside Tunis, after the killing of the opposition politician Mohamed Brahmi on July 25, 2013. (FETHI BELAID/AFP/Getty Images)

  • Mubarka Brahmi (R), the wife of opposition politician Mohamed Brahmi, cries at the hospital in Ariana, outside Tunis, after her husband was gunned down in front of his home, near the capital, on July 25, 2013. (FETHI BELAID/AFP/Getty Images)

  • Belkaeis Brahmi, the daughter of Tunisian opposition politician Mohamed Brahmi, covers her face with a national flag as she reacts outside a hospital after her father was killed on July 25, 2013 in Ariana, outside Tunis. (FETHI BELAID/AFP/Getty Images)