Confronting Soviet gain and U.S. loss in the Western Pacific's military power balance, Japan has embarked on modest, gradual but nevertheless inexorable rearmament - part of its cautious emergence as a political as well as an economic world power.

In a country where policy making is a search for consensus, there is now agreement within the power structure: Japanese defense spending will steadily increase, in a few years bursting through the informal ceiling set at 1 percent of gross national product. What's more, it may well be attained without internal convulsions here once deemed unavoidable.

The defense commitment reflects both concern over Soviet muscle-flexing and doubts about reliability of the U.S. defense shield. But in a broader sense, Japan is finally shedding the caution bred of traumatic defeat and embarking on a political role appropriate for the free world's No. 2 economic power.

One result is the new "peace and friendship" treaty with Communist China. On our last reporting trip to Japan in 1975, Japan's government doubted it ever would conclude the Chinese pact because of Peking's insistence on an "anti-hegemony" clause aimed at the Soviet Union. In 1978, it signed a treaty containing that clause despite heavy breathing from Moscow.

Dmitri Polyansky, a former member of the Soviet politburo demoted to be ambassador to Tokyo, was called home to Moscow for the summer. Returning after the Chinese treaty was signed, he began calling influential Japanese to warn them of the "yellow peril" from China. Selected businessmen and politicians were urged by Polyansky to promote a Soviet-Japanese "peace and friendship" treaty.

Is there any chance for such a pact? "No way," a high foreign-ministry official told us, speaking in English. Foreign ministry professionals were outraged when Prime Minister Takeo Fukuda, campaigning for re-election, blurted out that he plans a visit to the Soviet Union next year. The foreign ministry stresses there will be no talks, by Fukuda or anybody else, unless and until the Soviets discuss return of the Kuril Islands, seized from Japan in World War II.

Instead of beginning such negotiations, Moscow has exhibited its growing naval and air strength with repeated violations of Japanese jet fighters regularly scramble against Soviet air incursions.

While Russian bully-body tactics helped provoke Tokyo into the Chinese treaty, tipping of the Western Pacific's naval balance is carefully noted in Tokyo. With the expected introduction of a Kiev-class carrier into the Sea of Japan, the Russians are viewed as overpowering the once supreme U.S. Seventh Fleet.

While visiting here Nov. 14, Rep. Bob Wilson of California, a veteran member of the House Armed Services Committee, triggered handwringing in the U.S. embassy when he declared the Seventh Fleet by itself could not longer guarantee Japanese sea lanes. But that is precisely what Japanese officials told us.

Although the Seventh Fleet is undergoing belated modernization, hardware improvement will not reassure Japanese who see the U.S. troop pullout from Korea as symptomatic of declining interest in East Asia. Prominent Japanese simply do not believe that Washington could or would honor its promise to send three additional carrier task forces and 21 tactical air wings to Japan in time of general conflict.

The response is steady Japanese rearmament, will emphasis on anti-submarine warfare and air defnse to make Japan a prickly porcupine. Along with more tanks and submarines, this will push defense spending beyond 1 percent of GNP in a few years (a limit already breached if military pensions are counted, as in the United States and Western Europe).

Discussion of such matters is no longer taboo. A Japanese politician can publicly predict defense spending rising to 2 percent of GNP without being hooted off the platform. The disarray of left-wing parties over Peking's support for Japanese rearmament is an added dividend of the Sino-Japanese treaty.

All this transcends the U.S. Soviet military balance. An innovative first-term member of the Diet named Tetsuro Kondo told us in 1973 that Japan must develop its own military arsenal, partly to parry Western economic pressure. Five years later, Kondo at 47 is a vice minister of education and less angry about the West, but he still believes building first-class military hardware is essential for Japan. Significantly, Kondo is no longer alone.

However cautious and restrained, Japan's emergence as a power disturbs Asian nations devastated by imperial Japanese militarism 40 years ago. But change, inevitable sooner or later, has been hastened by the visible rise of the polar bear and decline of the American eagle in these waters.