Apparently Rumsfeld knew that almost from the beginning when he was still alive. The Afghanistan papers now published has evidence that each administration knew that, however they covered it up and painted a rosy picture to the public. Hate him or not, Trump was the first to accept reality, hence the approach to start talks with the Taliban.Nobody could know this, I trained special forces, they were at least dedicated and motivated..
As for the conventional forces, I had some faith in them but not a whole lot....did I or anyone I know think they would run away and desert in the face of the Taliban...no we didn't and couldn't....
I believe I posted a link regarding the Afghanistan papers earlier, go read it.