I don't think productivity gains explain why companies need fewer people to be employed. A better explanation is that tech companies have grown too big. They've established big enough moats to prevent competition from arising, and if for some reason competition did arise, they can just be bought out.
So we have something like a monopoly/oligopoly situation where companies are in a rent seeking phase and don't need as many employees as before when they were in a value producing phase.