Premier Adolfo Suarez faces the most difficult task of his brief but spectacular political [WORD ILLEGIBLE] - implementation of the economic and political compromise that he negotiated with Communist, Socialist, moderate and conservative legislative leaders.

The basic agreement, called the "Moncloa Pact" because it was hammered out in talks in the premier's isolated Moncloa Palace, was signed Oct. 25. It includes many Socialist and Communist contributions.

Government spokesmen have termed the accord between left and right-wing forces "a miracle."

It not only calls for wage and price restraints, but also imposes an income tax and proposes to end the subsidies that Spanish industry enjoyed during the dictatorship.

Both Communist Party General Secretary Santiago Carrillo and the premier have staked their political futures on the pact and on the expectation that it will reduce Spain's crippling 30 per cent annual inflation rate by the end of 1978.

The question is whether workers, the growing number of unemployed, the homeless who are squating in empty apartments, industry leaders caught in a liquidity crisis, students excluded from universities and farmers will fall in line when they begin to feel the squeeze of the austerity program.

Suarez, a pragmatist who is orchestrating Spain's transition to democracy, has defended the joint agreement on the grounds that it is the result of "a consensus" of the political representatives elected by the Spanish people in June in the first free elections since the 1936-39 civil war.

The premier had other reasons for dealing with the leftist parties, which were outlawed by the late dictator Francisco Franco in 1939 and legalized by the Suarez government in the spring.

He realized that his Center Democratic Union coalition, even though it had 165 seats in the Congress of Deputies, lacked a majority to enact major economic and political changes.

This meant that Carrillo - a former anti-Franco guerrilla who was exiled for years - had to be included in the talks and given a voice for greater than his 20 congressional seats.

The premier and King Juan Carlos - Franco's successor - apparently felt that there could be no labor peace in Spain without Communist support.

The Socialist Party, Spain's second largest political force with 118 deputies, wanted to remain in opposition to Suarez and was mocking Carrillo's suggestion that it should join the government's party in a coalition because neither party was strong enough to govern.

But when the premier invited all parliamentary party leaders to Moncloa Palace to work out a program to solve Spain's economic crisis and consolidate the democratic process, the Socialists could not refuse.

The Socialist Party's support of the pact raised strong objections from its labor affiliate, the General Workers Union. The Socialist union muted its criticism however, following talks between labor leaders and party Secretary General Felipe Gonzalez. The Communist workers' commissions leaders appear to have no disagreements with Carrillo.

The greatest turmoil caused by the pact was within the premier's party. The Center Democratic Union is formed of 12 factions, ranging from Social Democrats on the left to Conservatives who have opted for reform but not for deals with Communists and Socialists.

The premier did not consult the party on the pact, and excluded most of the Cabinet from the talks. He simply forged the agreement with the opposition, including the conservative Popular Alliance, led by Manuel Fraga. The Alliance agreed to the economic measures but did not go along with the pact's political clauses.

The premier's commitment to the pact - which was approved by Parliament - left in his party unhappy. The disarray was such that Socialist began to woo social Democrats within the premier's party and Fraga began to court the conservatives. Christian Democrats in the premier's coalition began to march to their own drum, their ranks strength the election and rightists associated with the Franco government.

A political leader who helped Suarez to forge the Center Democratic Union as a "centrist party" complained that the "pact betrayed tens of thousands of middle-class voters who supported Suarez."

The premier appears to have overcome internal dissent, even though he was angered by the talks between his party's social democrats and liberals and the Socialists. Suarez hasn't said so publicly, but he reportedly intends to change a few ministers in the immediate future.