-- A federal corruption investigation was inadvertently exposed here this week when a secret listening device was discovered in the City Hall office of Mayor John F. Street.

The bug was uncovered Tuesday during an electronic sweep of Street's office by the city police department, a sweep officials said was performed routinely every few months.

Its discovery set off a political firestorm when local FBI officials announced that the bug was not part of any electoral espionage -- Street (D) is locked in an acrimonious campaign with Republican Sam Katz -- but would not say how they knew that.

"The FBI doesn't confirm or deny investigations," said special agent Linda Vizi, the FBI spokeswoman in Philadelphia. "We were contacted by police that they found the device and responded. We will confirm, however, that we have ruled out the possibility of it being connected to the election campaign."

On Wednesday, federal law enforcement sources said the bug had been placed in the mayor's office as part of an "anti-corruption investigation" by the FBI in Philadelphia, but the sources refused to elaborate on the nature of the inquiry.

The city is already the subject of federal investigations into ticket-fixing and an airport-maintenance contract that was given to the mayor's brother but then rescinded, according to local news reports.

"This is a huge matter of concern to me," Street said in an impromptu news conference Tuesday afternoon, not long after the bug was found. "You'd like to think you have a certain amount of privacy in your own office, and when you don't, you feel violated."

The battery-powered device was found in the ceiling of the mayor's office, along with several microphones throughout the large room. The device transmitted its signal outside City Hall.

Street has said he had no knowledge of the bug before it was discovered and angrily demanded an explanation from the FBI. "I haven't done anything wrong, and I don't know that anybody in my cabinet or in my staff around me has done anything wrong," he said Wednesday.

Katz spokeswoman Maureen Garrity said she was happy that the FBI had quickly exonerated the Katz campaign, but she could shed no further light on what the bug meant.

"I don't think anyone knows what is going on yet. We just don't know the truth," she said. "We have three-and-a-half weeks to go in the race, and hopefully this investigation will take its course, and the people of Philadelphia will find out just what it is about."

This year's election is a repeat of the close race that Street won four years ago. The discovery of the listening device is the latest in a string of incidents that have plagued his campaign.

In June, the mayor had to rescind the multimillion-dollar city contract for airport maintenance with a firm connected to his brother to avoid suspicion of no-bid nepotism; the city turned over 25,000 pages of documents relating to the contract to federal investigators. Then Katz made an issue of the ticket-fixing scandal.

The wife of a Street spokesman was found to be writing letters to the editor of a local newspaper under her maiden name criticizing Katz. In August, someone threw a firebomb into a Katz campaign office, though police could not determine who did it.

The campaign has also prompted heated discussions about race in the city, which is divided about equally between white and black residents, with a much smaller percentage of Asians. Katz, a former Democrat whose only city office has been as a school board member, is white. Street, who was a longtime city council member and council president before becoming mayor, is black.

Pennsylvania Gov. Edward G. Rendell (D), a former Philadelphia mayor and a longtime ally of Street's, has asked the FBI to make public what it knows about the bug.

Street campaign spokesman Frank Keel suggested that any investigation was being orchestrated by the Justice Department for political reasons because Pennsylvania is an important state in next year's presidential election. "Is the Republican Party capable of dirty tricks? I think that is well documented," Keel told the Associated Press.

The local U.S. attorney, Patrick L. Meehan, a Republican appointee, denied that politics would have any role in any investigation by his office but did not address directly the topic of the listening device found in Street's office.

"The U.S. attorney's office in the Eastern District of Pennsylvania has a long and proud history of doing its work without regard to partisan politics. That was the practice of my predecessors, and it is my practice as well," Meehan said in a statement.

Appearing agitated during the Tuesday news conference, the mayor said he was not going to just wait for the FBI to tell him what was going to happen next.

"We'll conduct our own investigation in conjunction with the investigation that the FBI is conducting," he said. "We'll try to get to the bottom of it."

Eggen reported from Washington.

Philadelphia Mayor John F. Street takes questions at a news conference yesterday at which he said the discovery of a hidden listening device in his City Hall office had left him feeling "violated." The FBI said the bug was not related to the upcoming mayoral election, in which Street is seeking another term.