I had a teacher in undergrad (over 20 years ago) who said UML and code generation are getting so advanced, 5 years out, you likely won't be coding anymore.
In the early 00s, there was tremendous outsourcing going on. Some people said Western programmer salaries will collapse.
So your anxiety is nothing new. I think of ChatGPT-like tech to be like grammar checker. It will make your job easier.
Also, it is interesting to consider how chip design works these days. My understanding (as a software person) is that there are more people doing test-verification harnesses/QA of sorts than designing the basic blocks. This model may be how things go in software.