Heavy fighting involving artillery fire and helicopter gunships is taking place in the Pakistani tribal area of North Waziristan, military sources say.
The army say that it killed at least 23 militants overnight on Wednesday, but there is no independent confirmation of these figures.
On Wednesday it said at least five soldiers were killed by militants.
On Tuesday the head of the Pakistani Taliban, Mullah Fazlullah, ruled out peace talks with the government.
He vowed to continue attacks against Pakistani forces who he said were preparing to launch an operation in Waziristan.
Military sources said on Thursday that the 23 militants had been killed in exchanges of fire with security forces late on Wednesday night.
“[The] terrorists tried to ambush a convoy of security forces which was returning back from Khajori post,” they said.
“The convoy had gone to rescue injured soldiers who were attacked by a suicide bomber yesterday while they were offering prayers in a mosque at the post.
“Security forces valiantly responded and encircled [the] fleeing terrorists, inflicting heavy casualties on them. A fire fight continued for some time… and a search operation is in progress in the area.”
Locals say that at least two civilians have been killed and several houses destroyed by artillery fire in the Mir Ali area. They say that injured people cannot get to hospital because of a military curfew and continuing shelling.
The BBC’s M Ilyas Khan in Islamabad says that the violence comes after several years of comparative calm in North Waziristan and that locals now fear a wider ground operation in the area and large-scale population displacement.
On Wednesday militants drove an explosives-laden truck into a major security post at Khajori in North Waziristan, killing the five soldiers and injuring more than 20, military sources said.
The post and and a nearby military fort guard the main highway that connects the town of Miranshah in North Waziristan with Bannu, a city in north-western Khyber Pakhtunkhwa (KP) province.
The soldiers man the check-post near during daytime to monitor traffic entering and exiting North Waziristan, but move inside the fort at sunset.
The little-known Ansarul Mujahideen militant group said that it carried out the attack. Analysts say unfamiliar names are often used by Pakistani and foreign militant groups to avoid identification.
Ansarul Mujahideen has also been blamed for warning PTI party leader and former international cricketer Imran Khan not to take his anti-polio campaign into KP province.
The Taliban oppose the polio vaccination schemes, which they see as a cover for international espionage.
Mr Khan’s PTI party says that it is taking “precautionary measures” and has restricted Mr Khan’s movements.