Through the years, Alexandria city officials and planners have called the corner building of the old Torpedo Factory's complex, located where King Street stops and the Potomac River begins, "ugly," "crummy" and a "real problem."

Last night, what to do with the chunky little building with the fading yellow paint was the subject of an almost three-hour debate by City Council members, staff and architects. The key issue is whether part of the building should be razed to give citizens a better view of the Potomac.

All agree that whatever is decided is going to have a dramatic effect on the city's $50 million project to revive its decaying downtown waterfront.

"We need to move on and get this thing developed and resolved," said City Manager Douglas Harman. He said much of the continuing Torpedo Factory complex development will be stalled unless the city soon decides, once and for all, how it wants to develop the structure known as Building 10.

In March 1981, the council approved a plan to redevelop the structure where naval torpedos were manufactured in World War I into a mixture of retail and office space with a restaurant. The council went on to consider whether a substantial part of the building should be razed, but decided to stick with the original plan.

But for months, Mayor Charles E. Beatley has been openly critical of the $2.2 million plan that calls for giving the two-story structure a brick facade, lacing the upper floor with arches and setting back its first floor to accentuate its entrance and provide a view to the river.

A key feature of the building, said its designers, is a 15-foot-wide retail arcade designed to draw people into Building 10 and lead them to the newly revamped waterfront.

Beatley maintains that the building, even after all the proposed changes, would still obstruct people's view of the Potomac River as they approached it from Old Town's King Street business corridor.

The mayor, joined by council members Donald C. Casey and Patricia S. Ticer, suggested last night that as much as half of the building's 10,000-square-foot first floor could be "lopped off" to create a river vista.

That raised questions about whether the reduced retail space would make the building worth while. And architect Arthur Keyes, of the firm Metcalf & Associates Keyes Condon Florence that designed the building, opposed the idea.

"You don't want to bite out of the building," he said. "That will only dilute what is being done" in the rest of the project.

City officials said they hope the problem can be resolved by this fall. CAPTION: Map, The dot marks the location of Building 10. The Washington Post; Picture, MAYOR CHARLES E. BEATLEY . . . critical of $2.2 million plan