Maybe there's a bit more to a company and its software than the quantity of code it generates? And maybe there's a built in moat that a lot of these companies have that takes a lot of effort (and marketing, etc) to overcome?
People don't just jump social networks because a new one exist, there has to be a compelling reason to migrate over to it. And for a lot of people, there needs to be a sufficient number of people (and probably existing friends) already using the app for them to expend the effort to start using it.
It's not like there haven't been other attempts at competitors for these over the years, and you haven't heard about them probably because none of them ever got any traction. And that takes more than just building software.
Like DuckDuckGo has been competing with Google search for years (it first came out back in 2008, it looks like), and likely is way better developed than anything someone will crank out with A.I. in a short period of time. And it still has a tiny fraction of Google's marketshare.
I'm not saying there won't eventually be other competitors to these, but it'll take more than just whipping up an MVP with A.I. in a few weeks.