Put in place sensible rules around noise, locating in pre-planned areas, and covering the cost for electrical upgrades then let the market decide how many to build. Most people appear to be getting their information from TikTok and have developed a very ignorant NIMBY attitude.
To be blunt progress does get made by listening solely to those who get short end of the stick. Japan and China have good rail in large part because the central government can simply make the globally better choice over the objections of those nearby who lose out due to noise and other factors. We don’t need to do that, we simply need to not let ignorance win and instead regulate the externalities properly, and capture value for the public through property taxes.