Representative Tulsi Gabbard on Wednesday assailed Senator Kamala Harris over her record as a prosecutor, saying Ms. Harris owed an apology to the people who “suffered under your reign.”

[Follow our live coverage of Night 2 of the Democratic debates.]

Speaking on the second night of the Democratic presidential debates in Detroit, Ms. Gabbard, of Hawaii, highlighted Ms. Harris’s time as a prosecutor in San Francisco and as attorney general of California. Ms. Harris, in response, said she “did the work of significantly reforming the criminal justice system of a state of 40 million people, which became a national model for the work that needs to be done.”

Here’s a transcript of their exchange:

Gabbard: I want to bring the conversation back to the broken criminal justice system that is disproportionately, negatively impacting black and brown people all across this country today. Now, Senator Harris says she’s proud of her record as a prosecutor and that she’ll be a prosecutor president. But I’m deeply concerned about this record. There are too many examples to cite but she put over 1,500 people in jail for marijuana violations and then laughed about it when she was asked if she ever smoked marijuana.

She blocked evidence that would have freed an innocent man from death row until the courts forced her to do so. She kept people in prison beyond their sentences to use them as cheap labor for the state of California, and she fought to keep a cash bail system in place that impacts poor people in the worst kind of way.

Jake Tapper (moderator): Thank you, Congresswoman. Senator Harris, your response?

Harris: As the elected attorney general of California, I did the work of significantly reforming the criminal justice system of a state of 40 million people, which became a national model for the work that needs to be done. And I am proud of that work. And I am proud of making a decision to not just give fancy speeches or be in a legislative body and give speeches on the floor but actually doing the work, of being in the position to use the power that I had to reform a system that is badly in need of reform. That is why we created initiatives that were about re-entering former offenders and getting them counseling. It’s why, and because I know the criminal justice system is so broken, it is why I’m an advocate for what we need to do to not only decriminalize but legalize marijuana in the United States.

Tapper: Thank you, Senator. I want to bring Congresswoman Gabbard back in.

Gabbard: The bottom line is, when you were in a position to make a difference and an impact in these people’s lives, you did not and worse yet in the case of those who are on death row, innocent people, you actually blocked evidence from being revealed that would have freed them until you were forced to do so. There’s no excuse for that and the people who suffered under your reign as prosecutor — you owe them an apology.

Tapper: Senator Harris?

Harris: My entire career, I have been personally opposed to the death penalty and that has never changed. And I dare anybody who’s in a position to make that decision to face the people I have faced to say I will not seek the death penalty. That is my background, that is my work. I am proud of it. I think you can judge people by when they are under fire and it’s not about some fancy opinion on a stage, but when they’re in the position to actually make a decision what do they do, when I was in the position of having to decide whether or not to seek a death penalty on cases I prosecuted, I made a very difficult decision that was not popular to not seek the death penalty. History shows that and I am proud of those decisions.