Meta is preparing sweeping layoffs, potentially affecting 20% of staff, as it boosts AI investments and seeks greater operational efficiency.