The federal government has asked the Supreme Court to turn aside what it termed major threat to voluntary affirmative action plans effecting millions workers.

The threat is a 2-to-1 ruling by a federal appeals court that in plants where discrimination hasn't been proved employers and unions can't consider race in negotiating programs to select employes to be trained inhouse for skilled jobs.

Thr ruling is "incorrect," Solicitor Generd Wade H. McCree Jr. wrote for the government. If allowed to stand it "can be expected to chill voluntary compliance throughout the country," he said.

His Petition - filed 11 minutes before a midnight deadline Thursday - urgent the justices to nullify the ruling and send it back to the 5th U.S. Circuit Court of Appeals, "for reconsideration and supplementation of the record is light of" the Supreme Court's decision in the Allan Bakke case last June.

In Bakke, the justices decided 5-to-4 that the Constitution allows a state university to take into account the race of application for its professional schools.

The 5th Circuit ruling preceded Bakke by 7 1/2 months. As of now, it applies in the six states in its jurisdiction: Alabama, Florida, Georgia, Louisiana Mississippi and Texas.

The union in the case, the United Steelworkers of America (USWA), was stronger than McCree in warning about the potential consequences of the ruling. The ruling, the USWA said in a brief Thursday, can cause companies and unions in the 5th Circuit to dismantle existing affirmative action programs while deterring them there and elsewhere from starting new ones.

But the union took a different tack than McCree, who was speakin particularly for the Justice Dapartment, the Equal Employment Opportunity Commission and the Labor Department's Office of Federal Contract Compliance.

Rather than sending the case back, as recommended by the government, the union said the justices should hear argument on it during the term starting Oct. 2.

This is not "an issue which can be safely left to another day," the USWA argued. The petition said the ruling already had led one major corporation to advise the union that it has suspended implementation of affirmative action training programs at its plants.

The company in the case, Kaiser Aluminum and Chemical Corp., joined the union in seeking Supreme Court review. But in a footnote in its petition. Kaiser said it "does not object" to the case being sent back to enlarge what the government calls a "very limited" record.

The record consists of testimony of four witnesses in a one-day trial before U.S. District Court Judge Jack M. Gordon in New Orleans, seven exhibits and a short stipultation.

The trial resulted from a "reverse discrimination" class-action lawsuit against the company and the union initiated by Brian F. Weber, a white employe of the Kaiser plant in Gramercy, La., who is active in the USWA local there.

As of 1974, blacks in Gramercy constituted 46 percent of the populartion and 39 percent of the work force. In the Kaiser plant, meanwhile, they accounted for less than 2 percent of 273 skilled workers.Disrimination in the building trades had severely restricted the supply of qualified black craftsmen.

Also in 1974, the USWA began a nationwide program to overcome discrimination by negotiating collective bargaining agreements providng qualified minority workers, mainly in the steel, aluminum and can industries, with a quota plan: They would fill half of all vacancies in craft-training program for as long as it would take to end their statistical underrepresentation.

At the Gramercy plant, a nationwide agreement between Kasier and the union implemented the quotas by setting aside 50 percent of the openings in three craft-training programs for bidding by blacks on the basis of their plant seniority among their blacks.

Two of the blacks who were chosen had less seniority than Weber. He and other whites then sued Kaiser and the union, charging that the program illegally discriminated against them in violation of Title VII of the Civil Rights Act of 1964.

Weber won in both lower tribunals. The Equal Employment Opportunity Commission intervended in the appeals court. For its majority, Judge Thomas G. Gee wrote that the record showed no discrimination by Kaiser in hiring or promotion.

In reply, Solicitor General McCree wrote that none of the three parties to the suit had an incentive to show discrimination against blacks.

Gee said that in the absence of employer discrimination, "a racial quota loses it character as an equitable remedy, and must be banned as an unlawful racial preference."

McCree's key contention is that Title VII authorizes plans such as Kaiser's when employment figures, on their face, show discrimination. He pointed out that the fifth Circuit recently ruled, on the basis of figures "strikingly similar" to those for Gramercy, that blacks had made a prima facie case that Kaiser had discriminated in hiring for craft jobs at its plant in Chalmette, La.

Under the ruling in the Gramercy case, McCree said, employers wanting to set up a program like Kaiser's would have to prove that they have been violating Title VII. But they have natural disincentives, including legal liability, to do that, he said.