Back in the days when American cities were run by political party machines, New York's Tammany Hall stood out among the most notorious, and today its example is recalled in U.S. political lexicons as a sort of brand name for that party-boss style of municipal management.

West Germans have a different term for a similar practice. They call it filzocratie. The word filz literally means "felt" (as in cloth) and in this connection denotes the smooth, overlapping ties of a patronage system that builds on favors for friends and tends to blur lines of authority between those who do business and those responsible for supervising them.

To rid a city administration of filz takes more than a little spring cleaning, and West Berliners expect a thorough scrubbing leading up to the unexpectedly early mayoral elections on May 10.

During 35 years of nearly uninterrupted rule by Social Democrats here in West Germany's largest city, the political mesh of privilege, graft and oversights grew thick.A financial scandal in January embarrassed the government, drew public outrage, prompted the collapse of the leadership at city hall and forced new elections, two years early, at the instigation of the conservative opposition Christian Democrats.

The election is important not only for this insular Western-linked city 110 miles inside East Germany, but also for the Bonn coalition led by Chancellor Helmut Schmidt.At a time of division and distress in Schmidt's Social Democratic Party, West Berlin is being looked to as a kind of political litmus test for the national party's powers of renewal.

Beyond the simple theme of corruption, the West Berlin election turns on a complex web of festering social and urban problems that this city -- because of its size, attractions and unusual status -- suffers more keenly than others in West Germany. The troubles include violent youth protests, a housing shortage, a swelling population of disadvantaged foreign workers, growing unemployment and a lengthening list of pensioners.

Finding solutions has taxed the old Social Democratic formulas of state support based on the assumption of strong and continued economic growth. With the West German economy in a slump, the new fact of diminished possibilities has left the Social Democrats in this country generally feeling depressed and uncertain.

Not that the Christian Democrats have offered more definite answers. They sense, however, that the political tide may be moving in their favor -- particularly given public disapproval of how the bickering Social Democrats have behaved since their federal victory last October -- and a win in Berlin would further strengthen the opposition's hand.

Both parties have fielded first-string and exceedingly honorable candidates.

Schmidt picked Hans-Jochen Vogel, who had been the West German justice minister and was favored to succeed Schmidt as chancellor.

Demonstrating a sense of duty to party that won him additional respect, the 55-year-old Vogel charged off to West Berlin in the role of political crusader to run a caretaker government and prepare for the elections. He has shown himself to be a bold, demanding and disciplined administrator. He is experienced at city management, having served 12 years as a big-city mayor -- a fact that would be more in his favor in this Prussian region if the other city had not been Munich, the capital of southern Bavaria.

His Christian Democratic opponent is Richard von Weizsacker, who towers over the center-right in West Germany as a sort of philosopher-politician. Von Weizsacker's understanding of East-West relations is considered an important aset in his bid for leadership in this divided city.

Von Weizsacker failed in an attempt in 1979 to become mayor. After that, he returned to Bonn to serve as vice chairman of the Bundestag, or lower house of parliament, a move that offended a number of Berliners and that is seen as an early handicap for him. In contrast, one of Vogel's first shrewd moves was to declare himself a Berlin resident for the next four years, whether he wins or loses the coming election.

Vogel has seized other initiatives, moving to establish his image as a problem-solver and patch up the soiled image of the Social Democrats by attacking the filz.

A massive fraud had been responsible for bringing down the government of his predecessor, Dietrich Stobbe.The city had underwritten 90 percent of a loan equivalent to $270 million for a construction company, although the contracts were for projects far from West Berlin; the projects included two military academies in Saudi Arabia and a new building to house the West German Embassy in Cairo.

The company collapsed, its architect -- a Free Democrat with friends in the city administration -- fled, and the Berlin public was left holding the guarantees. The affair generated a parliamentary investigation and public demands for an end to the standard practice of allowing city politicians to serve on the boards of banks and other municipal enterprises over which they are supposed to exercise parliamentary supervision.

Vogel has banned such conflicts of interest in the future. He also removed most of the city's department heads, bringing with him a fresh team of professional aides and administrators.

These moves mollified some Berlin voters, who are persuaded that Vogel can make good on his call for a new beginning for the Social Democrats. But as the opposition points out, the recent scandal marked the third time in postwar history that a Social Democratic mayor was forced to resign under a cloud.

Moreover, the Berrlin political atmosphere remains tense as a result of continued confrontation between authorities and squatters now occupying more than 100 vacant buildings to protest a housing shortage. Tempers lately have flared into violent rampages by militant youths.

Protesters have refused to accept Vogel's offer of quick renovation of a number of the empty apartments. Instead, they are demanding amnesty for those arrested. For the time being, Vogel is restraining the police to avoid an escalation of violence.

While Vogel is credited with a strong campaign start, the 60-year-old Von Weizsacker is seen as biding his time, failing to draw very sharp distinctions so far between himself and his Social Democratic opponent.

A degree of public dissatisfaction with both main parties has given rise to the unusually strong showing in early opinion polls of the so-called "alternative" party, which is particularly popular among young voters and thus an especially serious threat to the Social Democrats. The "alternatives" are expected to score at least above the 5 percent minimum necessary to win representation in the city parliament.

In what was seen as a general warning signal for the Social Democrats, the party suffered significant losses to the young environmental group called the "Greens" in city council elections last weekend in Frankfurt and elsewhere in the state of Hesse.

Like the federal government in Bonn, the Berlin leadership is a coalition of Social Democrats and Free Democrats who together have a nine-vote margin in the 135-seat assembly. It is one of only two such coalitions in the 11 West German regional governments outside the Rhineland capital -- which would make the upset of the coalition here all the more shattering for the Schmidt government in Bonn, and a victory all the sweeter.