Most candidates in the D.C. mayoral race are now treating council member John Ray (D-At Large) as the front-runner and are focusing their attacks on him as the campaign for the Democratic nomination enters its final three weeks.

Council member Charlene Drew Jarvis (Ward 4) and council Chairman David A. Clarke weighed in last week with criticisms aimed at portraying Ray as a captive of real estate and other special interests, echoing accusations made for weeks by Del. Walter E. Fauntroy.

For the most part, Ray has ignored such attacks and focused on a broad platform that cites education as his top priority and calls for bringing the city together racially.

At a campaign rally in Northeast Washington yesterday, Ray said that he would take the "high road" and urged his campaign workers not to "wallow in the mud" with other candidates.

"There were some candidates who got in this race to run against someone," Ray shouted. "Now that someone is gone, and they're trying to find someone else to run against."

Mayor Marion Barry, after the end of his trial on drug and perjury charges, took himself out of the mayor's race definitively last week and announced he would run as an independent for an at-large seat on the D.C. Council.

Political analysts caution that the race is by no means settled. Ray was the strongest of the five Democratic candidates in early polls and remains by far the top fund-raiser.

But Jarvis has picked up momentum in fund-raising and secured key endorsements from several labor unions and gay activists. Fauntroy and Clarke are proven vote-getters in the city, and lawyer Sharon Pratt Dixon continues to gain applause at forums with her slashing attacks on the city bureaucracy.

Around the District, the once drab candidate debates have become electric as the rivals gang up on Ray. Looming as especially critical encounters are several televised debates scheduled for the final weeks of the campaign, when candidates will have opportunities to confront each other before citywide audiences obsessed for most of the summer with Barry's trial.

The mayoral race, which has received only modest attention until now, moved to center stage after the verdict in Barry's trial and his announcement that he would not seek a fourth term.

"Marion Barry's problems have been the biggest blessing John Ray has had," said Robert L. Johnson, Fauntroy's campaign manager. "For 65 days, he was able to run a race without anyone paying attention."

"Ray is perceived, because of the money he's raised, as being a front-runner," Johnson added. "But there is a tremendous undecided vote out there . . . . People are going to recognize that they don't know who John Ray is."

Fauntroy has been the toughest in his criticism of Ray's extensive contributions from real estate developers and brokers, his stance on rent control, and his recent endorsement from a group of black businessmen with close ties to the Barry administration.

Fauntroy has assailed Ray as the "great white hope" of suburban developers. He has urged voters in this predominantly black city to support a candidate who is "unbought and unbossed."

Clarke and Jarvis joined in last week with statements characterizing Ray as someone who cannot be trusted to protect the interests of average citizens.

"The issue is who is going to control the agenda for the District of Columbia," said Jarvis after a debate Thursday night that was marked by frequent jabs at Ray. "It is a real question of whether the people are going to control the agenda with Charlene Drew Jarvis, or whether the special interests will control the agenda with John Ray."

Clarke attacked Ray for permitting a private group of real estate brokers to mount an independent, $25,000 advertising campaign on his behalf, saying the action left the "strong impression that he is committed to one industry, to the detriment of the renters."

Ray has rejected such criticism, asserting that he has raised thousands of dollars from other sources, including dozens of small contributions. He also implied yesterday, in his remarks to supporters, that he believes Fauntroy and Jarvis are acting in concert to trip him up -- an assertion denied by both campaigns.

Having raised nearly $900,000, triple his closest competitors in fund-raising, Ray has assembled an impressive organization, plastering all eight wards with a slick campaign newspaper outlining his biography.

In Ward 3, west of Rock Creek Park, Ray has made inroads with white voters anxious for stability at the District Building, while lining up support in black middle-class neighborhoods elsewhere.

In Northeast and Southeast Washington, Ray has gained key endorsements from council member H.R. Crawford (D-Ward 7), school board President Nate Bush (Ward 7) and community activists.

Ray has saved far more money than his rivals, and with more than $300,000 in the bank, he is prepared to launch the most extensive media campaign of any candidate.

Ray is to start a television advertising campaign tomorrow that will last until the Sept. 11 primary and is aimed at saturating a still-volatile electorate with soft images of the Georgia-born lawyer.

His opponents, who are contemplating more limited radio and television campaigns, concede that Ray stands to gain a lot from the added exposure.

"There will be more minutes broadcast on the television and on radio that are bought and paid for than will have been journalistically presented," said Clarke. "It gives the advantage to the monied candidate."

But the city has not always supported well-financed candidates. Barry came from behind in the final two weeks of the primary campaign of 1978 to defeat Sterling Tucker, and Clarke upset incumbent council Chairman Arrington Dixon in 1982.

Some knowledgeable political activists said Ray's organizational efforts have been hampered recently by conflicts between his campaign manager, George Mitchell, and field director Joe Carter.

Jarvis, one of the most outgoing and exuberant campaigners in the race, has gained momentum from her recent endorsements by the Gertrude Stein Democratic Club -- the city's main gay political club -- the American Federation of Government Employees, former Ward 3 council member Polly Shackleton and a number of former Barry allies. The support has also paid off with a sudden boost in fund-raising; Jarvis collected about $150,000 in June and July.

After a slow start, Fauntroy is mounting a strong effort in the city's churches, where he has been endorsed by prominent ministers, such as Bishop Walter McCullough of the United House of Prayer. He has also picked up support from several important unions.

Clarke continues to focus on a grass-roots campaign, personally knocking on doors throughout the city and attending virtually every campaign forum and numerous block parties. His volunteer telephone bank, a key part of past successes, has been in operation since last fall, and he has picked up backing from tenants groups and Americans for Democratic Action, the liberal advocacy group.

Meanwhile, Dixon continues to perform well at forums, while some of her campaign themes, such as reducing the D.C. work force, have been picked up by other candidates. She traveled to Massachusetts this weekend for two fund-raisers in an effort to boost her total, the smallest of any candidate.