A $6 billion package of credits for Yugoslavia, including a substantial amount of new money, has been put together by Western governments, their commercial banks, and international lending institutions, sources said yesterday.

The Eastern European country, one of the few with major ties to the West, is in deep recession, with an inflation rate estimated at 30 percent.

A central element in the loan package, a credit of $1.3 billion advanced by 14 governments including the United States, was announced yesterday in Berne, Switzerland. These loans, with a maturity of at least three years, are expected to be disbursed this year.

The rest of the package, from international institutions and commercial banks, is expected to be announced momentarily.

The emergency aid package was intended to maintain Yugoslavia's orientation toward and trade relations with the West, and to avert the possibility of a default on Yugoslavia's $20 billion external debt, sources said.

International monetary sources explained that technically, no "rescheduling" of the Yugoslavia debt is involved, although commercial banks have in effect agreed to roll-over both short-term and medium-term loans.

Government leaders in Yugoslavia did not want to consider rescheduling, fearing that Western banks and governments would then classify Yugoslavia as financially weak and unsuccessful as other Eastern bloc countries like Poland and Romania, sources said.

Yugoslav leaders also told Western officials that rescheduling might force a change of government to one that would be more insulated from the West. Recently, the proportion of Yugoslavia's trade with the Russian bloc had risen above the 50 percent mark, after having come down to about 40 percent three years ago.

The difference between rescheduling and roll-overs "may be in the eye of the beholder", one monetary official said. The technical difference between rescheduling and the package being devised for Yugoslavia, experts said, was that Yugoslavia will not have to stop payments and restart them later. Instead, the new loans combined with the roll-overs should enable the government to deal with its liquidity crisis and keep up its schedule of payments.

According to American banking sources, the existing $20 billion external debt will require Yugoslavia to pay $1.9 billion in interest and $3.9 billion in principal this year.

Other provisions are:

* The International Monetary Fund will advance a gross amount of $600 million, yielding Yugoslavia $400 million after repayments of old loans.

* The World Bank will put in a modest amount, possibly about $300 million.

* Commercial banks will roll-over $2 billion in loans due in 1983 and another $1 billion due after 1983 and advance $1 billion in new loans.

* Pending the time that the 14 governments can disburse the $1.3 billion, the Bank for International Settlements in Basel, Switzerland will advance $500 million in "bridging" money--in effect, as a temporary loan.

If the World Bank commitment is $300 million, the package will divide into $3 billion of new money and $3 billion of roll-overs.

By advancing new money and averting the necessity of a default comparable to the situation in Poland and Romania, Western officials believe that Yugoslavia's leaders will be encouraged to maintain trade and other relations with the West.

Yet, no leading Western country has wanted to take the lead in a rescue operation for Yugoslavia. The United States, though a full participant in the package now developed, has had its hands full dealing with South American debt problems, and was content to leave the organization of the bail-out discussions to the Swiss in Berne, officials said.

Yugoslavia's economic problems are comparable to those in other Third World countries--a combination of domestic deficiencies and external conditions such as world-wide recession over which Yugoslavia had no control.