To begin with, practice randomly when there is no trigger. Have a sneaky treat ready and say the dog's name. If it's difficult to begin with (because they don't know their name), try putting the treats into a small plastic container and shaking it, or taking the plastic packaging of their treats. They learn to respond to that noise very quickly. Words are more complex, but if you say their name when you make the noise they'll start responding to that too. Always carry accessible treats.
5 months since we adopted untrained (pretty wild) greyhounds, I can get either of them to sprint to me by calling their name, sit, high-five, lie down... no matter what's going on around them. That response makes it easier to discourage cat-chasing and to reduce their prey drive.