Add a resistor(s) across the capacitor(s). In order to calculate values we’d need to know the capacitance, whether the capacitors are in parallel and/or series, operating voltage and ideally the exact capacitor specification, or at least the leakage current spec if the capacitor has one.
Julie