It seems to me if the big fear with player-controlled ramming is players building dedicated ramming ships, the key is to just make it suicidal. That way, while the player -can- make dedicated ramming ships, it's just no good. With this in mind, my idea is to make ramming cause a ton of shock damage to internal components. A real ship will have most of it's tonnage in internal components, so it will be less likely to die from it. Whereas a big ball of armor with engines has hardly any internal components, so shock damage will quickly kill it. So at best, your ram ship will kill one enemy ship, and that will be it. Yes, your ram ships will be cheap, but the giant shipyards needed to make dozens of ram ships won't be.
I'd also make shields work against ramming based on the amount of armor the ram has. I'm thinking of it kinda like how microwaves work irl. Small things often don't get heated at all; fruit flies for instance survive in a microwave totally unharmed, whereas larger insects die. Well what if ship-scale shields work somewhat similarly? Railgun shells and big balls of armor are dense enough that the shield interacts with them. But normal ships are actually mostly hollow, so just like the fruit flies being smaller than the wavelength of the microwave and surviving, normal ships are unaffected by "hitting" shields. So there's no fear about ram ships mounting 1000-strength shields.