Three U.N. workers kidnapped in Afghanistan (search) have been released unharmed after more than three weeks in captivity, officials said Tuesday.

"They are out," U.N. spokesman Manoel de Almeida e Silva said.

Officials said the three were freed overnight and were in the Afghan capital. One Western official said doctors were examining the three at a NATO (search) field hospital in Kabul.

The hostages were released late Monday and are in good condition, three Afghan officials told The Associated Press on condition of anonymity.

Armed men seized Philippine diplomat Angelito Nayan, British-Irish citizen Annetta Flanigan and Shqipe Hebibi of Kosovo in Kabul on Oct. 28, the first such abduction in the Afghan capital since the Taliban (search) fell three years ago.

Afghan officials earlier said they believed a criminal gang carried out the abductions, and that negotiations centered on a ransom demand.

News of the release came hours after U.S. and Afghan forces raided two houses in downtown Kabul on Monday and detained 10 people in connection with the abductions.

Most of the detainees were released after being questioned, an Afghan intelligence official said.

Afghan officials believe a criminal gang carried out the abductions, and that negotiations have centered on a ransom demand. But it remains unclear if the kidnappers are working for a Taliban-linked group that has claimed responsibility and demanded that Afghan and U.S. authorities free jailed comrades.

The leader of the group, which calls itself Jaish-al Muslimeen, or Army of Muslims, told AP it had no links to anyone detained in Kabul on Monday.

Akbar Agha also said in a telephone call Monday that the militants were "very close to an understanding" with government negotiators to exchange the hostages for 24 rebels in Afghan jails.

His claims could not be verified.

American officials worry a deal could encourage more abductions just as the military claims it is getting the better of Afghan insurgents using more conventional tactics.

In Monday's raids, security forces began the assault in the west of the city at about 4 a.m., using rockets to blast a hole in a wall surrounding the two-story home of a doctor working for the United Nations, witnesses said.

The doctor, Munir Mosamem, and his 17-year-old son were detained, Mosamem's wife, Zakia, told The Associated Press. The forces searched the house and confiscated three mobile phones and part of a computer, she said.

U.N. spokesman Manoel de Almeida e Silva said the doctor worked at a clinic for the world body in the city, but had no details on why the man was targeted.

Another eight men were detained in a derelict house next door, where several impoverished families of recently returned refugees were living, witnesses said.

The intelligence official said those eight were quickly released, but that the doctor and his son remained in American custody.