It was the kind of warning that could only be heard in Lebanon, so perverse that it was almost comical but so close to the deadly reality here that it was considered genuine.

A Shiite Moslem militia leader publicly threatened to shell Jewish settlements in northern Israel--not to aid the Palestinian cause but because he wanted to provoke a heavy Israeli response against Palestinian guerrillas who, he said, were shelling his strongholds and Shiite villages.

The action by Haj Mohammed Ghaddar dramatized the extent to which the constant threat of an Israeli attack has become part of Lebanon's factional warfare. It also underlined the Palestine Liberation Organization's unavoidable drift into Lebanon's internecine disputes that distract the guerrilla group from its struggle against Israel.

PLO leader Yasser Arafat, who last weekend predicted Israel would attack in two days, spent today mediating between the Shiite militia Amal and the Lebanese leftists who are his main allies. Arafat hoped to head off war between the groups following outbursts of violence last week that ballooned into a nationwide confrontation.

Amal has become a potent military force since Iran's 1979 revolution, thanks in part to aid from the Shiite government of Ayatollah Ruhollah Khomeini. Against the background of the Iranian-Iraqi war, hostility between Amal gunmen and Iraqi-backed leftists has flared into clashes dozens of times over the last 18 months.

The latest violence began Monday in the southern Lebanese hill villages where PLO guerrillas have concentrated their strength anticipating an Israeli attack.

Since the PLO is the only real law in the region, Palestinian forces were drawn into the fighting although Arafat reportedly gave orders not to become involved. Palestinians shelled and occupied some Shiite villages in southern Lebanon in an effort to end the fighting and ensure the PLO's ability to use the area militarily.

Lebanese and U.N. sources said the bloodletting broke out over the killing of an Amal leader at a communist checkpoint. But they attributed its escalation to the increasing resentment of southern Lebanon's 150,000 Shiite Moslems toward the PLO-Israeli conflict that makes their villages military positions and targets.

"We are facing an imminent Israeli aggression against the south, and southerners preparing to take on this aggression expected to receive enemy bullets," said Sheik Mohammed Mahdi Chamseddin, head of Lebanon's Higher Shiite Council, "but now instead we find we have Arab bullets directed against our breasts when the rifles should be pointed toward the Israelis."

By midweek the PLO troops--with help from U.N. forces--had calmed the situation. But combat had spread to Beirut and its suburbs, where Shiite neighborhoods abut Palestinian and leftist quarters.

In some of the heaviest fighting here in almost a year, Beirut's Amal forces battled gunmen from a panoply of leftist groups allied with the Palestinians. Lebanese security officers estimated that more than 60 persons were killed, while PLO officers said their count showed fewer than 40 killed and "many" wounded.

Despite their proximity to the battles and close ties with the leftist groups, PLO forces were reported to have steered generally clear of the Beirut fighting. One PLO official acknowledged, however, that guerrillas intervened to drive off an Amal checkpoint on the coastal road south of Beirut airport--a passage between the capital and the southern border that PLO officers consider vital.

The rivalry between Shiites and leftists reflects internal Lebanese politics as well as the Iran-Iraq conflict. Leftist Druze leader Walid Jumblatt's "National Movement" has been trying to organize elections for local governing councils that would help fill the government vacuum in mostly Moslem West Beirut just as the Phalange Party does in Christian East Beirut.

Amal, with its newfound strength, has strongly resisted this idea and has demanded recognition of its political influence. With nearly a million followers, the Shiite sect has become the most numerous group among Lebanon's 3 million people.