Gravitational-wave transient noise poses a challenge in the upcoming LIGO-Virgo-KAGRA fourth observing (O4) run. In this talk, I will briefly introduce gravitational-wave transient noise, followed by a study that estimates how much noise transients affect the electromagnetic follow-up. I will also present how machine learning can be applied in various stages of noise mitigation, ranging from estimating the amount of noise in the data to modelling and removing the noise. I will end the talk by giving my outlook on transient noise mitigation for O4.