The number after the dash is the mass number, which is the number of neutrons plus the number of protons. Since the number of protons can’t change (it would have become a new element if so), this means the number of neutrons must have changed.
Nitrogen has 7 protons, which means nitrogen-14 must have 7 neutrons and nitrogen-15 must have 8 neutrons.