A fighter on the government side said one of his comrades was shot dead in the fighting. He spoke on condition of anonymity because he was not authorized to brief journalists. A hospital official later said that three others were killed and 13 people were wounded. He too spoke anonymously for the same reasons.
Later in the day, government-affiliated militias and residents erected checkpoints along the road from Tajoura to the city center, checking IDs and searching cars in hopes of preventing outside militiamen from entering.
Prime Minister Ali Zidan told militias from outside the capital not to enter, saying that could lead to a "bloodbath," LANA also reported.
Zidan, who was briefly kidnapped by militiamen himself last month, said Friday his embattled government was working on a plan to drive all militias out of Tripoli.
Meanwhile, mourners gathered in Martyrs' square, a focal point of the country's uprising against Gadhafi, to pray for the dead. They raised Libyan flags and portraits of the slain protesters, chanting "Martyrs for you Libya" and calling for civil disobedience.
A statement drafted by Tripoli officials in the name of the city's inhabitants was read out to the crowd. It vowed to keep protests going until militias leave the capital.
The statement also stressed that Friday's protests were peaceful. It said that demonstrators were not armed but carried only "olive branches and white flags." It also held the government responsible for the killings.
Tripoli officials have declared a three-day mourning period. Many stores in the city were closed on Saturday.
The Friday attack started when thousands of protesters marched from a downtown mosque to a neighborhood called Gharghour, home to the headquarters of a militia originally from the city of Misrata that has a powerful presence in Tripoli. In Gharghour, many militias have turned villas and residential compounds of former Gadhafi-era officials into camps where they stash weapons.
By late Saturday, a government-affiliated militia, Libya Shield-Central Command, said it was in control of Gharghour. In a statement read out on Libya al-Ahrar TV, the militia declared it a military zone and vowed to turn it over to the government.
It is not clear if Libya Shield's control of the neighborhood will ease the tension, as residents have called for the military and the police only to be in charge.
The government has given militias a December deadline to join state security forces or lose their government paychecks though it is not clear if the government would actually cut them off, as similar threats have been made in the past.
The United Nations Support Mission in Libya condemned the violence, urging Libyans to exercise "maximum restraint" and resolve their differences peacefully.
The U.S. Department of State also condemned the violence and urged restraint, saying in a statement that it would continue to work with the Libyan authorities toward improving security and good governance.
"There can be no place for this kind of violence in the new Libya," it said in the statement, issued in the name of Secretary of State John Kerry.