BOSTON — On a recent visit to Fields Corner Business Lab in Dorchester, state Attorney General Martha Coakley took a tour of the 3-month-old business incubator. She chatted with the entrepreneurs who started the lab, spoke to a handful of business owners who were using it, admired the view out a window, and remarked on the artwork – a picture of the flatiron building in New York – in an office.

"I used to live in Dorchester and would walk to Fields Corner to get on the subway," Coakley told the group, many of whom were Dorchester residents.

As Coakley campaigns for governor, facing a Democratic primary against Treasurer Steve Grossman and former Medicare and Medicaid administrator Don Berwick, she is shaking hands, posing for pictures and giving out hugs. In other words, she is doing the retail campaigning that she was criticized for avoiding in 2010, the year she lost a special election for U.S. Senate, getting 47 percent of the vote in a stunning upset by Republican Scott Brown.

Asked what she learned from that election, Coakley said she has placed new focus on retail politics. "I learned that it's really important to make sure you have time to build the grassroots campaign, that you have time to be out knocking on doors, talking to folks one on one," Coakley said. "We've done that every day since last September."

"We learned from our mistakes," said Raymond Jordan, vice chair of the Massachusetts Democratic Party and former state representative, who lives in Springfield and worked on Coakley's 2010 and 2014 campaigns.

Speaking to voters, Coakley's message is one of experience. "She has spent her career fighting for people without power," Coakley's first television ad says, focusing on her work protecting women from domestic violence and suing major banks over foreclosure practices.

Asked how she differs from Grossman and Berwick, Coakley focuses on her resume. "I believe from what I've seen working as both a district attorney and an attorney general that I have the experience...from seeing for the last eight years what has worked and not worked in a tough economy, how we can build on what Gov. (Deval) Patrick has done in innovation, education and infrastructure," Coakley said.

Polling shows Coakley leading by least 20 points in the Democratic primary. She has more name recognition than the other candidates and has been able to appeal to many female voters, who are a majority of the Democratic electorate.

But polling shows her leading by a much smaller margin against Republican Charlie Baker, the 2010 gubernatorial nominee and the favorite to win the GOP nomination this year.

There are still signs of lingering concern about Coakley's candidacy among Democratic activists. At the Democratic state convention in June, Grossman won the party's endorsement after getting support from 35 percent of delegates compared to 23 percent for Coakley. Since January, not counting the public financing that both Coakley and Berwick received, just $400,000 separates Coakley, the most prolific fundraiser, from Grossman, the least prolific, and a political action committee has been making independent expenditures for Grossman.

"I think that is a concern, that she lacks the political chops to get through a tough campaign because of her failure (in 2010)," said Michael Shea, a Democratic political consultant who worked for Coakley's primary opponent, Michael Capuano, in 2010 and is not involved in the current race.

Coakley says the short time frame of a special election contributed to her 2010 defeat, along with national dynamics. It was the only race in the country at the time and drew millions of dollars in outside spending. The election became a referendum of Democratic President Barack Obama's health care overhaul, with Brown, backed by the conservative tea party, campaigning as the final vote Republicans needed to block the law. (Brown was unable to block passage of the Affordable Care Act, but his win required Senate Democrats to use a procedural move to approve changes to the law since they no longer had 60 votes to overcome a filibuster.)

But Coakley was also criticized for running a lackluster campaign and taking victory for granted. She famously told The Boston Globe, when asked whether she was being too passive by relying on political endorsements over retail politics, "As opposed to standing outside Fenway Park? In the cold? Shaking hands?"

Coakley points out that she has won two races for district attorney and two statewide races for attorney general. She was re-elected as attorney general with 63 percent of the vote just 10 months after she lost the U.S. Senate special election.

"At this stage I am putting 2010 behind. I think most voters have put 2010 behind," Coakley said. "I know that I have to prove to voters that I have the experience and the skill and the temperament to be a good governor, and that's what I've been focused on."

Coakley's campaign manager Tim Foley said in a full-length election, Coakley has more time to build her campaign and get her message out than in a short special election. According to her campaign, Coakley has attended more than 230 public events, including house parties and canvass kick-offs, and her campaign has knocked on 80,000 doors.

Coakley's supporters believe this race will be different. "We all learn from our mistakes. Businesses fail the first time," said Dianne Muller, a retired teacher from Bridgewater who supports Coakley. "You get more fired up. You know you can do better."

Jordan said he has seen a difference in Coakley's behavior. "She seems more determined and more serious," Jordan said. "She seems to be more aggressive."

"You go into a crowd, now she's in attack mode," Jordan said. He said Coakley jumps into a crowd, shaking hands and meeting people.

Jordan said that is different from Coakley in 2010. "She was laissez-faire before, a little too laid back," Jordan said. "She wasn't as aggressive as she should have been."

Matt Barron, a Democratic political strategist with MLB Research Associates in Williamsburg who was a state convention delegate for Coakley, said Coakley has "clearly learned some lessons from the painful loss for U.S Senate." "She's done a lot more retail politics, going to the diners, senior citizen picnics, marching in parades, meeting people at farmers' markets," Barron said.