After years of struggle, state security forces have broken the back of internal political dissent in the Soviet Union, leaving its future as clouded as at any time since the death of Stalin in 1953.

Ironically, this has been achieved virtually on the eve of the Madrid conference, which opens Tuesday to review compliance with the provisions of the 1975 Helsinki agreement on European security and cooperation. Soviet internal repressions opened the door to likely bitter wrangling there about Moscow's compliance with the human-rights provisions of the accord.

The pace of the KGB secret police offensive against dissidents, which has gathered momentum since 1977, escalated with the arrest and internal exile of Moscow's most famous human rights champion, Andrei Sakharov, in January. It was given an added urgency by Kremlin determination to silence dissenters prior to and during last summer's Olympic Games here.

Since the games ended Aug. 3, however, more than two dozen trials producing convictions have been held, and numerous new arrests were carried out in a security sweep that left the ever dwindling dissident movement frustrated, disheartened and leaderless.

Moreover, this drive has been punctuated by three activists' confessions of crimes against the state that had devastating impact on the morale and steadfastness of those still willing to express their views publicly.

For the most part, the recent trials have attracted little foreign attention, with the public and media preoccupied by the U.S. elections, the Iranian-Iraqi war and other major concerns. In addition, none of the activists commands as much attention as Sakharov, the scientist who developed the Soviet hydrogen bomb and who received the Novel Peace Prize the same year that the Soviet Union, the United States and 33 other nations signed the Helsinki agreement.

But a look at some recent cases shows the thoroughness with which the state is pursuing the activists.

Political dialogue: Three editors of the clandestine journal Poiski (Searches) have been convicted of state slander and sentenced to three years' imprisonment. Yuri Grimm and Valerie Abramkin were jailed, but Viktor Sokirko's sentence was suspended after he pleaded guilty and recanted his activities. The six issues published during the journal's two years of operation included discussions of Eurocommunism, socialism, and communist reform.

The journal reached a relatively small number of Moscow and Leningrad intellectuals, but despite its limited audience, the magazine could not be allowed to survive since its attempts at broad political dialogue could trigger pressure for reform.

Nationalists: Lithuanians Antanas Terleckas and Julius Sasnaukas were given three and 18 months respectively in labor camps, plus five years' internal exile each, for their human-rights work. For many years, Terleckas was a major nationalist figure in the Vilnius-based movement, and with 44 other Baltic natives, including Sanauskas, last year signed a denunciation of the 1939 pact that gave Moscow control of the Baltics. The condemnation thus struck at Soviet claims to legitimacy there and assured reprisal.

In the Ukraine, veteran nationalist Vasil Stus has been thrown in jail for 10 years, with an additional five years of internal exile, and Estonians Yuri Kukk and Mart Niklus, face stiff reprisals for their activities.

Religious activists: Having gained a televised confession from dissident Russian Orthodox priest Dmitri Dudko in June -- perhaps the single greatest blow to broad-based and nationalist-oriented church ferment -- the authorities followed up this fall with confessions from Lev Regelson and Viktor Kapitanchuk of the Christian Committee for the Defense of Believers' Rights. The two, accused of anti-Soviet activities, pleaded guilty and received suspended five-year jail sentences.

In August, the Rev. Gleb Yakunin, founder of the committee, denied similar charges at his trial and was sentenced to five years in a labor camp and five in internal exile. The cases dismembered the committee, which had embarrassed the state-controlled Orthodox church by reporting on widespread repression of Christian denominations to world church groups.

Human-rights activists: Vyacheslav Bakhmin, of a citizens' group that monitors psychiatric abuses, was convicted of anti-Soviet slander and sentenced to three years' imprisonment. His group has been devastated by several arrests.

Tatyana Velikanova, a key member of the Chronicle of Current Events, an important underground rights journal, was convicted of anti-Soviet agitation and given four years' imprisonment and five of internal exile.

The successful suppression of dissidents, or "those who think differently" in Russian, is the work of a Kremlin leadership determined to project the appearance of unanimity among the diverse Soviet peoples at a time when this country faces complex domestic and foreign policy challenges.

These include economic and ideological stagnation; the dangers of Poland's independent trade union movement; the Afghanistan crisis, which has badly damaged Soviet foreign policy initiatives, and a sure prospect of a leadership turmoil after President Leonid Brezhnev leaves the political scene.

But the paring of a generation of activists that emerged in the 1970s solves, for now, internal problems connected with the decade of detente, when Brezhnev reversed longstanding Kremlin policy and actively sought political, economic and military "relaxation of tensions" with adversary West in an attempt to modernize the struggling Soviet economy.

That change of direction, formally ushered in with the 1972 Nixon-Brezhnev summit in Moscow, posed immense difficulties for the totalitarian leadership. It promised much wider contact for Soviet masses, exposing them not only to superior Western goods and technology but also to Western values antiethical to a government that places the needs of the state above those of the individual.

Moscow's aim was to take the technology, but insulate its populace from the dangerous ideas that might encourage the religious, nationalists, political and social dissenters who had always survived within the Soviet society.

The Kremlin proved equal to the challenge. The activists have been routed, and the Soviet Union now enjoys wider economic ties with the West than ever in its history. It sells billions of dollars of raw materials yearly and uses the hard currency to gain technology for the economy.

At the same time, the leadership has succeeded in containing detente's potential impact on the masses. In fact, chiefly because of renewed jamming of Western radio broadcasts since the Polish crisis, and shrill anti-U.S. denunciations not heard here since the Vietnam war, the Soviet people seem psychologically more isolated from the West than at any time in the past 15 years.

When Jimmy Carter took office in 1977 with a ringing defense of the activists, dramatized by meeting newly exiled dissident Vladimir Bukovsky and sending a personal letter of support to Sakharov via the U.S. Embassy here, Moscow's dissidents were surprised and awed. Here at last was a powerful Western champion who had scrapped "quiet diplomacy" and sought to make the Kremlin accountable for internal repression by raising the issue to the level of official state-to-state relations.

Carter's action coincided with a period of intense dissident activity, sparked by the Helsinki agreement. Led by physicist Yuri Orlov, "Helsinki monitoring groups" sprung up in Moscow, Leningrad, Kiev, Tbilski, the Baltics and elsewhere in a fresh effort to bring activists together to publicize Soviet repressions.

But within months, Orlov, Alexander Ginzburg and Anatoly Scharansky were arrested, followed by other arrests, searches, beatings and threats. The actvists' hopes faded. Presidential statements had no noticeable effect on a Kremlin that under Brezhnev jailed most of its organized critics or occasionally exiled them to improve its foreign relations in moments of strain. But, as evidenced by the decision allowing Jews to emigrate, Brezhnev's policies always hinged such gestures to specific goals, in that case, an attempt to gain long-sought trade credits from the United States.

Carter's human-rights policy helped focus Western attention on the plight of Soviet dissenters, but had no appreciable impact.

The list of unofficial groups all but destroyed by the KGB since the mid-1970s is very long; most Helsinki-monitoring groups barely function. Their activities have largely been narrowed to defending arrested members and reporting on abuses in prisons and labor camps. It is very difficult for them to continue their activities at the same level, when many of the most experienced and committed have been jailed.

Even as the Polish crisis seems to hold out some possibility of liberalization within that neighboring country, veteran activists here see little future benefit for them from what the independent labor unions may achieve.

"The situation here is simply completely different," one activist said in a recent interview. "Poland is a Westernized country, where workers are used to coordinating their actions, where the church has always been strong and where agriculture is largely private. None of those conditions exist here."

Indeed, two years ago, the security forces jailed, forcibly exiled or sent to psychiatric hospitals almost every member of a small group of workers seeking to found an independent trade union for Soviet laborers.

Underground publications continue, notably in Lithuania and the major cities of European Russia, and large amounts of information that paint a far different portrait of Soviet reality from the official version find the way to Western correspondents here and media abora. But the atmosphere is grim and unrelieved.

"It has been a veryt difficult time," said one activist not long ago. He was sitting in the quiet living room of the apartment of Irina Grivnina, a woman arrested a few days earlier for helping to monitor political abuse of psychiatry. The tension in the room was palpable, and a physician who had come there from out town to sepak about some recent cases of political abuse of mental hospitals was visibly nervous talking to reporters.

"The movement continues because the abuses continue," he said. But the work must be done even if the future is not at all clear."