Kinetic theory of a chemically reacting gas with inelastic transitions