MOSCOW, DEC. 26 -- Soviet President Mikhail Gorbachev today chose as his vice president Gennady Yanayev, a Communist Party apparatchik with little political standing outside the Kremlin bureaucracy.

With the announcement in the Congress of People's Deputies, the country's supreme legislative body, many of the more than 2,200 members groaned or whistled. Most fell into a stupefied silence as Gorbachev described Yanayev's long service as leader of the country's labor union bureaucracy and as head of the Communist Party faction in the legislature.

"I am a Communist to the depths of my soul," Yanayev told the Congress. "My main fight will be against political bacchanalia and vandalism -- but through democratic means, not by repression."

Under the Soviet constitution, no alternative candidates were permitted, and Congress chairman Anatoly Lukyanov allowed 10 seconding speeches but no statements in opposition. Many reform-minded members objected that Yanayev is an evident opponent of radical economic reform and also, as a Russian, brings no ethnic diversity to the government at a time when Moscow is trying to resolve its myriad nationality conflicts.

Nevertheless, Yanayev, 53, is expected to win confirmation on Thursday with a simple majority in the one-candidate balloting.

Earlier in the day, Gorbachev told the Congress that his prime minister, Nikolai Ryzhkov, had suffered a heart attack Tuesday night. Ryzhkov, 61, a defender of a centralized economy, is the last remaining member of Gorbachev's original leadership team, but he has come under so much criticism in recent months that few expected him to retain his post long after this session of the Congress.

Gorbachev said Ryzhkov was in the hospital but that "at the moment there is no threat to his life." Yanayev told reporters that "psychological pressure" had undoubtedly contributed to Ryzhkov's illness.

The Congress also formally approved Gorbachev's plan for a restructured executive apparatus, which now will be subordinate to him rather than to the prime minister. The Congress, however, rejected his plan to create a Supreme State Inspectorate to monitor the fulfillment of executive decrees.

The Congress also declared that the new cabinet -- the Federation Council -- would include in addition to the heads of the 15 Soviet republics, the leaders of the country's separate ethnic regions, known as autonomous republics. The panel could now have more than 30 permanent members.

Conservative politicians, especially longtime members of the Communist Party's policy-making Central Committee, said they were delighted with Gorbachev's selection of Yanayev. "It's a great choice," said Yegor Ligachev, once Gorbachev's most powerful conservative rival in the leadership. "Yanayev is a genuine Communist, a great mind."

As a Central Committee secretary, Yanayev is a de facto member of the Politburo, the party's ruling body. But now that Gorbachev has shifted his base of authority from the party to the government, the Politburo retains only a fraction of its old power.

Many supporters of radical reform in Congress said that Yanayev's nomination deepened their conviction that Gorbachev is depending more and more on the traditional institutions of power -- the party, the KGB and the military -- to assert his authority over rebellious Soviet republics.

Alexei Yemilyanov, a member from Moscow, said: "Today it looks as though we have finally burned our democratic structures and have gone the way of dictatorial rule. Pretty soon we'll be praying for people like Ligachev to come back."

Algis Cekuolis, of Lithuania, called Yanayev "a lapdog," while Arkady Murashev, a leader of the Inter-Regional Group of radical-reformist legislators, described Yanayev as "a yes-man, a prime example of the party bureaucracy."

Yuri Chernichenko, head of the new Peasants' Party, said: "Gorbachev needed someone who had some public respect at his side. What has this Yanayev ever done? When someone like Eduard Shevardnadze feels he has to resign, and we got a Yanayev instead, we are in deep political trouble. Yanayev is an insult to all our hopes for the future."

Alexander Yakovlev, once Gorbachev's closest adviser and a leader of radical reform, seemed nonplussed by the selection but said with a sly smile: "It's the president's choice. That means it's a good choice. The president is a smart man."

Asked if the conservative surge was growing stronger, Yakovlev replied, "It's not getting any weaker."

Gorbachev said last week that before Shevardnadze resigned as foreign minister he had been hoping to nominate him as vice president. With Shevardnadze gone, speculation then centered on the leader of the Central Asian republic of Kazakhstan, Nursultan Nazarbayev. But Nazarbayev seemed to reject the job in interviews, saying it was "meaningless."

Because of Gorbachev's tense relations with so many Soviet republics, he may have been hard pressed to find another non-Russian with any authority. And given strong indications that he intends to appeal to traditional Soviet discipline to bring order out of political and economic crisis, it seems apparent that he could not have chosen a radical reformer, such as Russian President Boris Yeltsin.

Asked by a member of the Congress how he could consider both Yanayev and Shevardnadze for the same post "when they are of such diametrically opposed views," Gorbachev denied that the two men disagreed, saying: "Even if their views don't overlap, they are very close."

In the new executive system, the vice president would assume the presidency in the case of Gorbachev's death, but new elections would be scheduled. Asked about rumors here and in the West that Gorbachev suffers from diabetes or other illnesses, his adviser Georgi Shakhnazarov said: "No, no. I've been working with him for three years, and he's only had a cold twice. He works like a horse."

In a brief speech and question-and-answer period, Yanayev, 53, proved cautious, given to the sort of bureaucratic language typical of Central Committee secretaries.

Yanayev pledged to avoid violence in the country and promised "no unpredictable, no convulsive policies." He spoke fiercely against any sort of Polish-style "shock therapy" economic reform and promised to strengthen the country's army and law enforcement bodies.

He said, however, that, "If anyone tries to suggest to me that Gorbachev is keeping some kind of political monster in the shadows and with its help will unleash a new draconian order, then I say this is nonsense."

Even an adviser as close to Gorbachev as Shakhnazarov was surprised by Yanayev's selection. Just minutes before Gorbachev's announcement, Shakhnazarov told reporters that the president would be well-advised to select a young non-Russian who could broaden his appeal.

Yanayev, whom Gorbachev called "a man of firm principles," graduated from an agricultural institute in Gorki, worked as an official in the Young Communist League and earned an advanced degree in history. In the early 1970s, he administered foreign exchange programs for rising Communist Party officials. In 1989, he was appointed to head the country's trade-union movement, a traditional bastion of conservative Communist apparatchiks.

Mikhail Poltaranin, a member of the legislature of the Russian republic and a spokesman for Yeltsin, called Yanayev "conceivably the worst choice possible."

The Interfax news agency and other Soviet sources said Gorbachev's leading candidate to replace Ryzhkov as premier is the current finance minister, Valentin Pavlov, a conservative whose views are much like those of Ryzhkov.