The Afghan government on Sunday urged the Taliban to extend a rare ceasefire hours before it was due to end, as a contentious prisoner swap between the two warring sides edged closer to completion.

Officials said there were no reports of fighting between the enemies across much of Afghanistan during the three day truce that marked the Muslim festival of Eid al-Adha.

However the calm was broken on Sunday evening when gunmen stormed a prison in Jalalabad in eastern Afghanistan, leaving at least three people dead and several wounded.

Amaq, the extremist Islamic State (IS) group’s news outlet, announced that the IS was responsible for the prison raid, the SITE Intelligence Group tweeted.

The Taliban denied involvement in the assault.

The prison held more than 1,700 inmates, most of them fighters from the Taliban and IS, a security source said.

As the brazen attack on the prison commenced, a “large number” of prisoners managed to escape, Ahmad Ali Hazarat, the head of Nangarhar provincial council told AFP.

Security forces launched a city wide search to track them down.

Meanwhile, President Ashraf Ghani and the Taliban have both indicated that long-delayed peace talks could begin straight after Eid.

“We look forward to it,” Sediq Sediqqi, spokesman to Ghani told AFP when asked if the authorities were keen on extending the ceasefire.

“We hope the Taliban will not resume violence.

“The Afghan government’s actions and steps taken in the peace process must be reciprocated by the Taliban.”

Under a deal signed by the Taliban and the US in February, the “intra-Afghan” peace talks were slated to start in March, but were delayed amid political infighting in Kabul and as an agreed prisoner swap dragged on.

The deal stipulated that Kabul would free around 5,000 Taliban prisoners in return for 1,000 Afghan security personnel held captive by the Taliban.

The National Security Council on Sunday said a further 300 Taliban prisoners had been released since Friday, taking the total number freed so far to just over 4,900.

The Taliban say they have already fulfilled their commitment.

Authorities however have refused to free hundreds of inmates accused of serious crimes that the group had requested for release, adding that a gathering of Afghan elders would decide their fate.

The rare respite from violence allowed some Afghans to safely visit relatives for Eid celebrations after long periods apart.

“I managed to visit my village for the first time in two years,” said Khalil Ahmad from volatile Uruzgan province, a hotbed for insurgents.

“There were many Taliban check posts on the way, but they did not bother anyone.”

Shahpoor Shadab, a resident from Jalalabad, told AFP that “Eid feels different, parks are full with people.

“You almost forget that there has been a war in this country for 40 years.”

Kabul resident Fawad Babak, a shopkeeper, was sad that it was the last day of the ceasefire.

He said: “I’m a little disheartened . . . the killing and bloodshed may resume again tomorrow.”

In restive Zabul province, several residents recited poems calling for the ceasefire – only the third official halt in fighting in nearly two decades of conflict – to be made permanent.

“Peace is everybody’s need and aspiration,” said Sardar Wali, who took part in the poetry session.

“This is a great opportunity to extend the ceasefire today and start intra-Afghan talks tomorrow.”

Deadly violence has rocked Afghanistan since the Taliban-US deal was agreed, with more than 3,500 Afghan troops killed in attacks by the insurgents, Ghani said.