The interstellar medium of dwarf galaxies : new insights from Machine Learning analysis of emission-line spectra