Context doesn't work the same way as memory + experience in humans. While humans have an impression and a flexible mental model of any single domain, AI needs hard data, which is hard to manage with context and can't really be worked around by fine-tuning in practice, lest you have to retrain the model on each and every code merge.
Also, not every project is highly complex or involves huge codebases and, for those that are, a junior developer might be assigned to a reasonably self contained and small module within the project (i.e. something that a LLM can do better at).
Finally, although this wasn't part of my original argument: before modern LLMs, let's say that a senior developer could produce N units of work per Y units of time. Now, with the help of a LLM, they are able to produce XN units of work per Y unit of time. I don't think it's too controversial to claim that some portion of developers are now more productive than they were before. And if developers in general are more productive, then you can expect some reduction in the number of developers that you need for a given project. So, in an indirect sense, LLMs are already capable of replacing coders.
This pattern I see play out time and time again. Senior builds the integration to various team services, then juniors tweak & mimic those to do more.
> let's say that a senior developer could produce N units of work per Y units of time.
So, it's more the case that senior developers are building full production assembly lines, that can then be replicated to do similar things relatively easily. The cost of the units of work are not at all equal.
How does this apply to AI? Good luck getting AI to do something novel, by definition it can't. OTOH, extending an existing pattern is trivial for a senior developer to do after they have built that pattern; juniors spend a lot of time at it cause they have to learn everything.
So, who is the AI going to replace? If the junior, then you have a senior developer using an AI to do something that is already trivial for them to do. No way AI is replacing the senior.. So who? Who is getting replaced by the AI and who is using it?