Carpet shampoos contain a mix of chemicals like surfactants for cleaning, solvents for stains, enzymes for breaking down dirt, fragrances, pH adjusters, and water. These chemicals work together to clean carpets effectively.