Thermodynamic modelling of the outgassing chemistry of Super Earths and sub-Neptunes: applications to secondary and hybrid atmospheres | Synapse