In an extraordinary response to a request from Sen. Edward M. Kennedy (D-Mass.), the Soviet Union apparently will grant an exit visa to a prominent and high-ranking Jewish scientist who has been waiting to emigrate for six years.

At a crowded press conference here yesterday, Kennedy said he expects the Soviets to give exit visas to Benjamin Levich and his wife, and to 17 other families who have been seeking to leave the Soviet Union.

Kennedy was in the Soviet Union last week, and met for two hours with Soviet leader Leonid I. Brezhnev, who discussed the case of Levich with Kennedy and apparently ratified an unprecedented display of magnanimity toward an American senator by signalling a more flexible attitude on these exit visas.

One of the 18 families involved is that of Jessica Katz, an 11-month-old infant suffering a rare disease that prevents her from digesting food. American Jewish groups have been sending her special formula for months via tourists, while pressing the Soviet authorities to allow her to go abroad for treatment.

Kennedy declined to characterize or explain the Soviet decision to release these people - as many as 50 individuals - after his intervention, but it appeared that the Kremlin had chosen him to send to message to President Carter.

Levish, the Katz infant and the others who will get exit visas according to Kennedy's announcement are not among the Soviet citizens whom Carter and his administration have defended by name in various public statements on the fate of Soviet dissidents.

Carter's public interventions on behalf of the dissidents have not produced more favorable treatment for them. Kennedy has made no public statements comparable to Carter's, and now the Soviets have apparently "rewarded" him with these new exit visas.

At yesterday's press conference - which attracted five television cameras, several dozen reporters and more than 100 guests and spectators - Kennedy said he was reluctant to go into details about how the exit visas were arranged.

It was learned subsequently that his foreign policy aide, Jan Kalicki, flew to Moscow the week before last to negotiate with Soviet officials about what gestures Kennedy could expect to be made during his visit to the Soviet Union. Kalicki learned that the Soviets would look favorably on Levich's application for an exit visa and would agree to release a number of families who have relatives now living in Massachussetts whom Kennedy has been working to reunite.

However, it was learned further, the Soviets sweetened the pot for Kennedy after his arrival, informing him that they also would look favorably on exit-visa applications from a half-dozen Jewish families about whom the senator apparently never made inquiries.

Kalicki also was assured that American businessman Francis J. Crawford would be given a suspended sentence after his trial on charges of foreign currency violations, so that Kennedy would not be embarrassed on that score during his visit. Crawford did receive a suspended sentence, and left the Soviet Union, during Kennedy's visit.

Kennedy did not receive ironclad promises that these new exist visas would be issued, but apparently felt confident enough about them to announce them yesterday. There were no news reports from Moscow last night suggesting that Levich had learned that he and his wife would be permitted to leave.

Kennedy agreed, it was learned, that he would not give any press conference while in the Soviet Union, nor make any public comment there about his understandings with the authorities on these exit visas. After his meeting with Brezhnev, Kennedy met with a number of Jewish activists and "refusedniks," who have been refused exit visas, at the Moscow home of Alexander Lerner, another prominent scientist who has been waiting for years for an exit visa. A security man from the Soviet KGB accompanied Kennedy to Lerner's apartment.

Levich was not at that meeting.

Kennedy was asked yesterday if Brezhnev or other Soviet officials asked him about his political future. He curtly answered, "No, they' did not."

He also went out of his way to emphasize that the Carter administration knew of his trip in advance and received a full report on it when he returned. (Kennedy met yesterday with Warren Christopher, the deputy secretary of state.)

Kennedy is widely regarded as a potential Democratic candidate for president, perhaps even in 1980, though he has repeatedly said he will support Carter in 1980. The crowd that filled a Senate hearing room for yesterday's press conference included a number of Kennedy admirers who clearly hoped this dsiclaimer is not the final work.

Some of those present speculated that the Kremlin, too, was signaling an interest in a Kennedy candidacy through its unprecedented treatment of the senator's visit.

It was learned that during their meeting Brezhnev told Kennedy that the Soviet Union was confused by the Carter administration's policies and could not be sure what the president's true objectives are.

Kennedy said the results of his visit were one of several recent "positive signals from the Soviet Union" that "offer hope that the recent downward spiral of Soviet-American relations may be at an end." He said he was confident that a new strategic arms agreement will be reached soon.

Levich, who Kennedy said will soon leave the Soviet Union, is a corresponding member of the Soviet Academy of Sciences and a world-renowned physical chemist. Scientists and scientific organizations all over the world have urged the Soviets to allow him to emigrate. His two sons were allowed to leave the Soviet Union several years ago.

The case of Jessica Katz and her parents has received worldwide publicity. Jessica has been diagnosed as suffering from malabsorption syndrome: her mother and father have been denied exit visas, at least partly on the ground that her mother once worked with state secrets.

Others whom Kennedy said the Soviets will soon let emigrate include Lithuanians, Latvians, Armenians and Estonians with relatives in Massachusetts and many Jews who have previously been denied exit visas.