Insurgents who attacked Pakistan's military HQ near Islamabad have taken 10 to 15 security personnel hostage, the army says.
Military officials say the attackers are surrounded inside the compound in Rawalpindi, and efforts are being made to recover the hostages safely.
Sporadic gunfire has been heard from the compound, reports from the scene say.
Six soldiers and four militants were killed in the initial assault.
The military at first said the situation was under control, but later added that up to five militants were holding the hostages inside a building within the compound
Reports say senior officers were among the hostages and among those who died.
The attack comes as the Pakistani army prepares for a major operation against the Taliban.
"Eight to 10 terrorists were involved in this attack. Four of them have been killed while six of our security personnel were martyred," military spokesman Maj Gen Athar Abbas told the private Geo TV station.
He said the building had been surrounded and officials were assessing the timing of a rescue operation.
"We are trying to move with the minimum loss of life," said Gen Abbas.
Another Pakistani official was quoted by Reuters news agency as saying: "It's a hostage situation. They're demanding the release of some of their fellows."
Area sealed off
Officials said the gunmen drove up to the army compound in a white van just before midday local time (0600 GMT) on Saturday.
They took up positions, fired on the compound and threw hand grenades, security officials said.
Roads to the area were sealed off and helicopters hovered over the compound.
Eyewitness Khan Bahadur, a van driver, said there had been "fierce fighting" followed by a blast.
"Soldiers were running here and there," he said. "There was smoke everywhere. Then there was a break, and then firing again."
The military reported that the attack had been repelled after a gun battle lasting around 45 minutes.
However, military officials later said that more militants were still at large and were now holding several hostages in the "security office building" inside the complex.
Pakistan's Interior Minister Rehman Malik said officials wanted to catch the gunmen alive so they could "give us more information".
"The Taliban are hired assassins. They are the enemies of Islam and Pakistan. All their actions are against the sovereignty of Pakistan," he told CNN.
The attack follows a series of bombings in north-western Pakistan. On Friday at least 50 people died in a blast in Peshawar.
The BBC's Aleem Maqbool, in Islamabad, says the latest attack, on one of the most secure areas of the country in the middle of the day, shows a new level of audacity from the militants.
Islamist militants have carried out a number of attacks against high-profile, high-security targets in recent years.
In March this year gunmen opened fire on a bus carrying the Sri Lankan cricket team in Lahore. Six policemen and a driver were killed, and several of the team were injured.
In the same month, dozens of people were killed when a police training centre on the outskirts of the city was occupied by gunmen