Other candidates six weeks ago hid their anxieties behind clouds of cigarette smoke, tumblers of liquor and chatter with supporters as they waited in hotel ballrooms for the results of the preliminary run-off election that would reduce the number of contenders for a seat on the Boston city council from 30 to 13.

Twenty miles away, however, in a gray stone building in suburdan Dedham, council candidate Paul Ellison was calm. He sat smoking a pipe and listening to a small transistor radio in a seven-by-eight-foot room.

When the 36-year-old former two-term school committee member learned he had won - squeaking onto the final ballot by placing 18th - he issued his victory speech: "The people of Boston will never know how grateful I am for this victory."

But the only person who could hear the speech was his cellmate, for Ellison is in Norfolk County Prison in prison grays, serving a one-year term for grand larceny in connection with a city payroll check-cashing scheme.

Ellison maintains he was framed.

He thus becomes the latest act in a grand old Boston political drama of running for public office from prison - and winning - which once starred the likes of James Michael Curley, the mayor of Boston who went to prison twice during his notorious political career.

"The voters have given me a second look, and I think they really believe I'm innocent," Ellison said during an interview in the prison library. "The voters would have felt I'd given up if I hadn't run."

"Of course there are those who will think all politicians are crooks and Ellison is just one of the few who got caught," he said. "But there are also those who know me and will vote for me because they know I will work for them - who know I should not be in prison right now."

With the Nov. 8 final election drawing near and the city council race swinging into high gear, Ellison's sister and campaign manager, Anne Reveliotis, has been acting as proxy on the campaign stump, appearing at candidates' nights luncheons and "coffees" throughout the city on a 16-hour-a-day schedule.

Ellison has had limited media access during the campaign, and the burden of personal contacts with the electorate as well as the political problems caused by his current predicament have fallen on Reveliotis.

But in this still heavily Irish city, Reveliotis said, she does not have to apologize for Ellison's trial and conviction.

"The Irish are funny," she said. "They have a way of knowing and understanding they don't have to talk about the misfortunes Paul has gone through."

"We're basically still an Irish town," said Dick Sinnott, a local political analyst and columnist. "We love you when you're down, not when you're up. Hell, look at what jail did for Curley, and he was a man who could get elected to anything in this town."

James Michael Curley was just a few years younger than Ellison when he spent his first term in the city's Charles Street Jail in the '20s, during the sunrise of his 55-year political career, for taking a civil service exam for an illiterate Irish immigrant trying to get a post office job.

Curley went on to win four mayoral terms, two congressional terms, and the governorship of the state before a feud with President Franklin D. Roosevelt over the President's refusal to give Curley the ambassadorship to Rome turned the tide on the big city boss' remarkable political career.

According to local political gospel, Roosevelt retaliated against attacks Curley made on him by prompting an investigation of Curley that resulted in an indictment on mail fraud charges in 1945 while Curley was still in Congress but running for a fourth term as mayor.

In keeping with the tradition he had created. Curley's subsequent conviction and incarceration at Danbury federal penitentiary the following year created a state of confusion over who would act as mayor in his absence.

At the time, the president of the city council, John B. Kelly, who would have succeeded Curley, could not take the job because he was under indictment for allegedly soliciting bribes from companies seeking garbage permits.

"James Michael Curley was a kind man and a good man," recall Charles lannelia, a former nine-term Massachusetts state representative and Curley lieutentant who spent four months in Deer Island Prison in 1962 after being convicted of stealing $340 from the city for a contracting job he did not perform.

"He'd send me down with envelopes of $5 bills for the poor people on Christmas and every house had a picture of the great master," reminisces lanella, who received his largest victory during the campaign he ran from prison and who went on to win three more terms after he was freed.

"They just aren't like that today," he said reverently.

But city council candidate Ellison says his old campaign organization has reformed for an all out push in these final days of the campaign despite his legal troubles.

Working on his behalf, Ellison's sister has spent hours on the telephone with potential voters and she reports receiving dozens of calls each day from old and new campaign workers willing to spread the word that Paul Ellison is a serious contender for the city council.

Still, there is a psychological hurdle for the voters in electing a convict. And then there is the logistical problem of the prison rules, which only allow three visits and three phone calls a week.

Ellison has been refused a furlough and is just now being let out on work release. But that leaves no time for hand-shaking, speeches or any other kind of electioneering.

Prison officials have granted him only a few interviews with the press, and those are allowed only outside the main area of the prison population because officials are afraid he might be singled out as a "prima donna" and thus become subject to assault by his fellow inmates. (He was beaten in the face with the side of a hammer by a prisoner shortly before he announced his candidacy last summer.)

Ellison's parole hearing and motion for a retrial both based on claims that a witness perjured himself - have both been postponed until after the election.

"I'm really a political outsider now," said Paul Ellison from inside the walls.