“If the US needs STEM workers, we should start training them” – @austinmshauri – as long as Americans will make more money in finance or business, we will lack not just STEM workers, but also STEM professors/teachers/instructions.
And to fill those gaps, international students will step in. (The biggest reason most TAs in STEM are foreign is because graduate school is their only way to stay in the US, since most won’t get H1B visas to stay.)
So to address the STEM issue we need to start by first treating our STEM teachers and professors better. That will make STEM a more attractive field. We then need to find ways to ensure STEM grads can remain in their careers after 40. Right now, most engineers (for example) age out, and unless they move up into management, will find themselves obsolete - and prime fodder for layoffs. No wonder the best and the brightest avoid STEM: the career options and earning potential just isn’t that great.
We live in a society that values those who make things less than those who know how to make a profit off those who make things.
Sadly, fixing it isn’t as easy as saying “let’s cap visas.”