A visiting French bookshop owner, who was detained for two days last week by Polish police in Krakow, said he was abducted and tortured by unknown persons shortly after his release from police headquarters.

Commenting today on the case, which has received wide attention in the French media as the first publicized physical abuse of a foreign visitor in Poland since the military crackdown more than three years ago, a government spokesman said authorities were investigating the incident "energetically" and rejected suggestions that either the Warsaw government or the secret police was behind the reported assault.

The attack on Frederic Castaing, a resident of Paris and an expert on autographs, has raised speculation in the French press and opposition circles here of another secret police operation like the kidnaping last October of a priest who supported the outlawed trade union Solidarity. Four secret police officers were convicted in the murder of the priest, the Rev. Jerzy Popieluszko, and sentenced to long jail terms in a case that shook the government of Gen. Wojciech Jaruzelski.

Relations between Poland and France have been at a low point for months, showing no upturn despite gradually improving ties between Warsaw and other West European countries. But government spokesman Jerzy Urban told reporters today that the assault on Castaing served neither the interests of the Polish government nor those of the police.

He suggested that groups hostile to Poland may have been involved in the case, saying the attack was "in the interest of all those who want to show Poland as a country of death squads with ties to the authorities."

Urban confirmed that Castaing had been detained by police in Krakow on March 12 after being found carrying Solidarity leaflets.

Castaing refused to answer questions and was released by police two days later with instructions to leave Poland. He has told reporters in Paris that militiamen directed him to a bus that they said would take him to the center of town but instead it carried him to the suburbs. As he stepped out of the bus, he was bundled into a car where he said three men in civilian dress burned him with a lit cigarette.

French authorities sent a letter over the weekend to Krakow city officials demanding an investigation.