Yea, if you're facing an AI that's using any melee ships then you're almost certainly going to want to unlock grav turrets. They're used very frequently in general against other stuff (even if it's tractor/forcefield-blockable) but against melee it's often your only way to slow them down.