U.S. efforts to keep the sensitive American military presence here out of the limelight are being undercut by President Anwar Sadat's penchant for publicity and U.S. Air Force disclosures in Washington.

U.S. diplomatic sensitivity appears prompted by a desire to deflect attention from two major Air Force programs in Egypt and by general anxiety about creating an Iran-like backlash here to all things American.

The two programs illustrate different aspects of the U.S. dilemma.

The first, aimed at training Egyptians to handle F4 Phantom fighter-bombers, has run into early troubles at Cairo West Airfield. The United States rushed the Phantoms here last fall to demonstrate American backing for Egypt after Cairo broke ranks with the Arabs to make a separate peace with Israel.

The second program, which involves a U.S. military presence at the base at Qena, about 300 miles south of Cairo in isolated upper Egypt, draws tight-lipped and evasive responses from American officials.

Foreign diplomats are convinced that Qena is intended to be a permanent facility for the U.S. Air Force to use at will. Since last December, AWACS, sophisticated American communications aircraft, have been based there.

Sadat last month revealed that the American C130 transport aircraft used in the abortive mission to rescue hostages in Tehran had used Qena. Such leaks appear part of Sadat's effort to raise the American profile in Egypt at the very time the U.S. Embassy would like to lower it.

Sadat's apparent goal is to demonstrate that Egypt has become the most reliable U.S. ally in the Middle East, outstripping even Washington's longtime friend, Israel, whose military bases are considered too politically controversial for use in crisis.

Gen. Lew Allen Jr., the Air Force chief of staff, appeared to have reinforced Sadat's policy last week. He announced that a squadron of Phantoms and about 400 Air Force personnel would fly here next month for up to 90 days to help train Egyptians to fly the previously delivered Phantoms. Allen suggested that eventually F15s, F11s and possibly B52s would also use Egyptian facilities as part of plans to introduce land-based American airpower to the Middle East and the Persian Gulf.

U.S. officials here said they knew nothing about visiting American aircraft other than the Phantoms.

They suggested that the Egyptians now undergoing training on 35 F4s were not far enough advanced to benefit from the experience of the summer visitors.

In fact, the training program is experiencing such serious problems that although U.S. officials say the Phantoms are flying up to 50 training sorties a week, knowledgeable foreign specialists insist that the total may be closest to 12.

"It would even take an American Air Force unit two years to convert to a new aircraft," an American official said, "and these guys are coming from the Soviet system."

Starting in the mid-1950s the Egyptian armed forces relied almost exclusively on Soviet weaponry for most of two decades.

Some foreign specialists fault the United States for providing Phantoms. They argue the planes are too sophisticated and demanding for already critically short maintenance personnel.

The specialists noted that Phantoms require from 90 to 120 hours of maintenance per flying hour, compared with 40 for the French-built Mirage which is also in service here, and only 20 for the F16s which Egypt is counting on receiving from the United States.

U.S. officials admit that maintenance, logistics and other associated questions pose the most serious problems in the program next to language.

The majority of Egyptians involved in the Phantoms program are not fluent in English.

As a result, "about 100" Americans are involved in the Cairo West training. The French, who trained Egyptians on Mirage fighters, and the British, who taught them to handle helicopters, insisted that Egyptian personnel come to their respective countries to learn.

Four French representatives, all employes of the Dassault company, which makes the Mirage, and one British company representative, are the only foreigners here connected with their countries' programs.

"We took years to wean the Egyptians away from the Soviet procurement system," noted a European expert, "and now the Yanks have knocked the slats out from under the Egyptians by making them change again. It's traumatic for them."

American officials dismiss such talk as sour grapes since American equipment is now replacing European weaponry here. The Americans argue the big difference is less between various American and Western European weapons systems than between any given Western system and that of the Soviets.

But the arrival of American euqipment has nonetheless complicated standardization for the Egyptian armed forces, which also have British, Chinese, French and Soviet equipment.

The American presence has also raised fears that anti-Americanism may be just over the horizon.

"The Americans aren't stationing troops downtown the way the British did in the old days. Nor are American colonels in uniform driving through central Cairo in air conditioned Chevies," a Western diplomat said, "but the Americans have a high profile here."

A high Foreign Minister official worry privately about "definite negative repercussions" for the American military presence. Already the opposition is wondering why Sadat has replaced the Soviet military with the American. "It's one thing to have fought Israel for 30 years, another to appear as mercenaries for America," a dissident intellectual noted, "especially when the United States is perceived as increasingly weak."

But for the time being, Sadat is determined to keep the armed forces happy by giving them everything he can get.

"The problem with the military is that they are not happy with what they're getting. They want more and more now," a specialist said. "They're miffed at the United States because the Phantoms were pulled out of U.S. Air Force units and were not new. The Egyptians are like children in a candy store."

"If that sounds familiarly like the shah of Iran in the old days," he added, "the main difference is that the shah had his own money and Sadat depends on gifts. But, so, too, do the Israelis."