High-ranking diplomats from the five Andean Pact countries assembled here today for an emergency meeting to deal with the increasingly difficult issue posed by the reported presence of 10,000 Cubans seeking political asylum inside the Peruvian Embassy in Havana.

Peruvian officials said late tonight that the five countries were close to reaching an agreement to accept some but not all of the refugees.

Today's emergency pact meeting was called by Peru in an effort to seek assistance of its allies in resettling the Cuban refugees. Other pact members are Venezuela, Colombia, Ecuador and Bolivia. Apart from seeking practical solution to the problem, the five countries were expected to reaffirm their commitment to the principle of political asylum.

The Peruvian government earlier expressed the hope that other Western countries, including the United States, would offer permanent refuge to the Cubans. Foreign Ministry officials said 6,300 refugees have been interviewed by Peruvian diplomats in Havana thus far and "the overriding majority has expressed the desire to go to the United States."

[In Washington, a State Department spokesman said the United States was prepared to cooperate in working out a solution of the problem but made it clear that the five Andean nations should be primarily involved in resettling the Cubans. U.S. officials suggested that refguees with relatives in the United States or some other legitimate claim would be admitted to the United States.]

Peru has already called on the International Red Cross and the U.N. High Commissioner for Refugees, among other international organizations, to help in caring for and resettling the thousands of refugees stranded in Havana. Cuba has rejected Red Cross assistance, maintaining that it is capable of providing the refugees with food and water.

Whatever Cuba's reasons for allowing the refugees to enter the Peruvian Embassy last weekend, there was little doubt that the crisis has damaged Cuba's relations with Peru, Venezuela and several other Latin countries -- principally because of a bitter dispute over the principle of political asylum and the terms by which it is granted, which is at the heart of the current imbroglio.

In addition to calling on the Andean Pact to help resettle the refugees, it was also expected that the five South American countries would publicly reaffirm the traditional Latin view that political asylum is an almost sacred right which may not be tampered with by any country from which refugees are attempting to flee.

The principle has been largely respected by Latin governments of all political persuasions for almost a century, mainly because of the coups and political instability which has historically characterized the region. No government leader has wanted to violate the convention because none has been sure that he would not one day have to avail himself of it.

A Foreign Ministry report said that the situation within the Peruvian Embassy compound in Havana, where the refugees have been camping since Saturday, has deteriorated and that "severe" rationing was in effect. Officials here said several refugees were wounded by shots fired from outside the embassy and that there were violent incidents inside the crowded complex throughout the day.

"It is not likely the situation can be sustained for much longer," one Peruvian official said.

Although the current dispute erupted with full force only last week, it has been brewing since last May 12 when 13 Cubans forced their way into the Venezuelan Embassy in Havana and asked for political asylum. Cuba's relations with Venezuela deteriorated sharply after Cuba refused to grant the 13 safe-conduct passes out of the country, claiming that they had violated Cuban law by entering the embassy by force.

Since last May, several other groups of Cubans drove cars and trucks past Cuban security personnel guarding both the Venezuelan andPeruvian Embassies and, each time, the Castro government reiterated its claim that they were nothing more than common criminals who should be turned over for prosecution to the Cuban authorities.

Venezuela and Peru stoutly defended their right to decide who should and who should not be granted political asylum. They also demanded that Cuba grant safe-conduct passes to the approximately 40 refugees inside the two embassies as of April 2, a day after a Cuban security officer was killed during the last attempt by Cuban dissidents to force their way into the Peruvian Embassy.

Last Saturday, the situation became a full-blown crisis when Fidel Castro's government issued a tough statement recalling "the deceit and cowardice" of Latin governments that it said had, at the bidding of the United States, participated in the diplomatic and economic boycott of Cuba after the country's 1959 revolution. The same day, the Cuban government announced that it was withdrawing its security personnel from around the Peruvian Embassy.

Both Peru and Venezuela reacted with toughness of their own, calling the language in the Cuban statement unacceptable and reminicent "of the cold war, which has been overcome in the region" over the past decade as more and more Latin governments have recognized Havana and as Castro called an end to exporting his revolution throughout the hemisphere.

Foreign Minister Arturo Garcia y Garcia of Peru said last night that Peru has no intention of breaking relations with Cuba over the refugee problem in Havana. But there was little doubt that the crisis has set back a decade of improving ties between Castro and other governments in South and Central America.

Despite today's meeting and their plea for international aid, Peruvian officials here acknowledged that they do not as yet have any estimate of the cost of resettling the refugees or even a precise number of Cubans now living in the embassy compound in Havana. In addition to those camped inside, at lease 2,400 potential refugees are believed to have accepted the Cuban government's promise that they could leave the embassy, return to their homes and still be eligible to emigrate once an evacuation effort gets underway.

"We've got no good information," a Foreign Ministry official here admitted. "We are now making a thorough evaluation of the situation [in Havana] and hope to have more definite information later."