Prime Minister Menachem Begin's ruling Likud coalition was put in serious jeopardy today as two of its members defected to the opposition Labor Party on the eve of a crucial parliamentary vote on a motion of no-confidence.

While it was far from certain that the defections will bring down the Begin government Wednesday, the party shifts put the Likud coalition on even shakier ground and increased the likelihood of early national elections.

Despite desperate, 11th-hour attempts by Likud leaders to keep them in line, Knesset members Amnon Linn and Yitzhak Peretz quit the party over patronage dissatisfaction and said they will vote against the government in Wednesday's test over Begin's economic policies.

If the opposition is joined by the three members of the right-wing Tehiya (renaissance) Party and the two-member Telem Party, both of which have expressed dissatisfaction with the government, Begin's coalition will almost certainly collapse and the prime minister will be forced to resign. In that event, and if the Likud and the Labor Alignment are each unable to form a new government, a new national election will be held in Israel.

It was not clear tonight how the two swing parties would vote in Wednesday's test, although Yuval Neeman, leader of the Tehiya, said the "trend" in his party is to force the collapse of the government. The Tehiya, which was formed by ultranationalist opponents of the Egyptian-Israeli peace treaty, is still rankled over the dismantlement of Jewish civilian settlements in the Sinai last month.

Leaders of the Telem Party said they were undecided how to vote and that they are awaiting the return of Knesset member Zalman Shoval from abroad to hold consultations.

Labor Party Knesset members were cautious about predicting a defeat for the Begin government, noting that the Tehiya Party is eager to broaden its base in a new election but is not anxious to bring down the government if there is any likelihood that the Labor Party could form a government without going to a national election.

One Labor Knesset member, Gad Yacobi, said, "I don't think we'll win tomorrow, but the steamroller has begun to move." He said further defections from Likud--most likely from the liberal faction of the party--will inevitably result in an unraveling of the coalition.

With today's defections, the Labor Alignment now has 50 votes in the 120-member parliament and can count on four votes of the Democratic Front for Peace and Equality, a communist party, and two votes of the centrist Shinui Party. Coupled with five votes from the Tehiya and the Telem parties, that would give the opposition a total of 61 votes, enough to bring down the government.

The Likud Party now has 46 Knesset seats, and it can count on six more votes from its National Religious Party partner, four from the Agudat Israel party and three from the Tami Party, giving the coalition only 59 votes. If the two-member Telem Party, formed by the late Moshe Dayan in last year's election, abstains, the no-confidence motion would end in a 59-59 deadlock, and Begin would not have to resign. If Telem voted with the government, the Likud would squeak by with a one-vote majority.

Compounding Begin's problems, Avraham Melamed, a National Religious Party member, said if his vote is needed to break a tie, he will vote against the government.

As so often in Israeli politics, Begin's current coalition crisis arose not so much because of a burning issue as because of happenstance and unpredictable shifts of alliances.

The Labor Party's no-confidence motion was drafted in an almost desultory fashion, with many party members complaining that such regular parliamentary assaults on the government actually strengthen the Likud when they fail. Labor Party leader Shimon Peres conceded in a party caucus yesterday that the prospects of bringing down the government were small, but he argued that the purpose of the no-confidence motion was merely to focus public attention on the government's economic failures.

Last week, the government announced that prices in April rose 10.7 percent, and 33.1 percent for the first third of the year. If the pace continues, the annual inflation rate for 1982 will be 136 percent.

Although Peretz said he defected over dissatisfaction with government handling of social issues, including the decision to end Sabbath flights of Israel's national airline, and Linn said he switched because of disagreements with Begin's policies in the occupied West Bank, both appeared to have changed their allegiance for more practical reasons.

Knesset sources said that Peretz, who in last June's election ran 47th on the Likud list of candidates, has been promised a place in one of the first 25 seats of the Labor list in the next election, plus a job as minister or deputy minister if Labor returns to power. Linn, the sources said, will also be given a more favorable position on the Labor ticket, and also a job as director of Arab affairs if Labor forms a government.

Knesset sources said that Linn was disgruntled because the Likud would not support his candidacy for mayor of Haifa.