The defendant is not getting a retrial. He is getting resentenced. His guilt wasn't challenged. I think the defendant's argument is that the lifelike AI avatar of the victim carried the emotional weight of actually being the victim, and since the statement was one of geniality and forgiveness that may not have actually represented the victim's true self. This prejudiced sentencing because it made it look like the defendant killed someone better than they may have been.
The AI statement was effectively a statement from the victim's sister. She can get up on the stand and talk about how genial and forgiving her brother was herself, and it will likely result in a similar sentence. Then, that sentence will be based on actual testimony and not invented testimony.
And to those questioning why the lawyer challenged the sentence, a defense attorney is going to look at any opportunity to argue for a lesser sentence as one worth taking. You may think this testimony yielded a "better" sentence for the defendant, but I'm sure the attorney thinks otherwise.