Brazilian officials yesterday wound up two days of talks with a committee of commercial bankers on refinancing of Brazil's $104 billion in foreign debt expressing hope that Brazil would "shortly" reach agreement with the International Monetary Fund.

Antonio Carlos Lemgruber, president of the Central Bank of Brazil, and Carlos Eduardo de Freitas, director of international affairs for the central bank, told the bankers that Brazil expects a trade surplus of about $11.5 billion for 1985, more optimistic than some estimates.

The government import-export agency Cacex, in announcing Brazil's April surplus yesterday, said that if present trends continue to the end of the year, the 1985 surplus will be only $9.5 billion. Brazil's April trade surplus was $1.08 billion, bringing the four-month total to $3.4 billion, roughly half-a-billion dollars below the same period last year.

As Lemgruber talked with the bankers, Finance Minister Francisco Dornelles was meeting in Washington with officials of the International Monetary Fund and the U.S. government.

A multi-year refinancing program between Brazil and the banks worked out under the former military government was nearly complete when Brazil ran into trouble with the IMF for exceeding money supply and inflation targets agreed to as a condition for a $4.2 billion loan. The IMF suspended disbursements on the approximately $1.5 billion remaining in the loan arrangement and that, in turn, brought the bank refinancing to a temporary halt.