Great point. AI remixes and rips-off existing code-bases in a manner that is impossible to attribute copyright violation making it legal. ie, Perfect cloning. In a world where cloning is legal, the engineering cost of product drops to zero. That is where software production could be headed. What remains is marketing/distribution/sales.
There will remain niches solving "hard problems" which cant be cloned, but those will be rare. Hard problems are where a lot of engineering complexity resides, involving interacting components for which there are no examples in training datasets to copy from. For example, a complex distributed system or hardware with multiple nuanced tradeoffs.
Don't forget liability & compliance :)
There will be people who will pay for "human coded" software if it is better. Quality is always a differentiator that some people will pay for.
Stuff for old men like me
That's what I mean by margins being a significant difference.