LONDON — FOLLOWING Islamic Jihad's release of hostage John McCarthy, the British government decided to pin its hopes for achieving the release of the remaining Western hostages in Lebanon on UN Secretary-General Javier Perez de Cuellar. It based its decision on comments Mr. McCarthy made soon after his arrival in Britain.Within hours of the journalist's release Aug. 9, Prime Minister John Major wrote to his Israeli counterpart, Yitzhak Shamir, urging him to do more to end the hostages' captivity and to cooperate with the secretary-general in all possible ways, officials in London disclosed Aug. 13. Mr. Major's letter to Mr. Shamir was seen as an indication that pressure was building on Israel to be more flexible over the hostage issue. As Mr. Perez de Cuellar's mission gathered momentum, there was rising optimism in government circles that Terry Waite and Jack Mann, the two Britons still being held, would be released soon. Sources stressed, however, that a future hostage deal depended on Israeli cooperation. On Aug. 11, McCarthy, looking remarkably fit and composed considering his ordeal, handed Perez de Cuellar a six-page letter from Islamic Jihad proposing a comprehensive deal for the release of all hostages and prisoners. According to British sources, early debriefing of McCarthy suggests that the Shiite groups holding the remaining Western hostages are eager for a solution and are looking to the UN secretary-general to broker it. Perez de Cuellar said in Geneva Aug. 12 that the letter did not contain a detailed formula for releasing the hostages, but that he was "hopeful" that its contents would improve the chances of an end to the hostage problem. UN officials acknowledged privately that a crucial factor was the attitude of Israel, which has said it will consider releasing Arab prisoners it is holding only if seven Israeli servicemen being held in Lebanon are handed back. Sir Crispin Tickell, Britain's ambassador to the UN until late last year, said Aug. 12 that it was possible that work was well advanced on a wide-ranging negotiation to free the remaining hostages. Israeli readiness to help in making a deal possible was "central," he said. Asked about Israel's role in reaching a solution to the hostage problem, Sir Crispin said: "Israel now has a chance to get the problems of Palestine settled on an equitable basis. It would be extremely unwise not to take advantage of this opportunity." In a brief statement to the media on Aug. 11, after he saw Perez de Cuellar, McCarthy said: "It is my belief the kidnappers do want to end the situation and that it will come to an end soon." Douglas Hogg, the Foreign Office minister who spoke privately to McCarthy soon after he arrived at Lyneham, said Britain would give the secretary-general "every help he needs" to achieve the release of the remaining hostages. It would be "extraordinarily encouraging" if Israel released some of the detainees it is holding in south Lebanon, he said. A Foreign Office spokesman said afterward that the letter from Islamic Jihad to the UN secretary-general "could help break the logjam on the hostage issue." Despite hopes both the remaining British hostages would seen be freed, official circles think it more likely that Mann would first be released. Waite, the Archbishop of Canterbury's special envoy was seized five years ago during a mission to Lebanon aimed at securing the freedom of other hostages. A campaigner for Waite's release, who refused to be named, said Waite might be the last of all the hostages to be released because his prominence made him a "major bargaining counter." Less was known about Mann, but McCarthy said his captors had reported that Mann was in good condition. Asked if he had a message for the remaining hostages, McCarthy replied: "Keep the faith."