Do the job? No. Noticeably increase productivity, and reduce time spent on menial tasks? Yes.
I suspect the layoffs are partly motivated by the expectation that remaining workers will be able to handle a larger workload with the help of AI.
US companies in particular are also heavily outsourcing jobs overseas, for cheaper. They just don't like to be transparent about that aspect, so the AI excuse takes the focal point.