It doesn’t just assume it. It’s the whole point of the masks.
If your aim is just to prevent making people sick, a surgical mask is just fine (exhibit A, normal doctors).
If your aim is to prevent getting sick yourself, a N95 respirator is a better choice (exhibit B, doctors treating COVID patients).
An inhalation valve does less to protect other people, because the expelled air still has to go somewhere, and will just blow out of the sides of the mask. It could theoretically go through the mask material if it was thin enough, but there’s probably too much pressure inside and it’ll burst out the sides.
That in reverse is the whole idea for masks with an exhalation valve. Breathing in creates negative pressure inside the mask, so air gets pulled inside through the mask. When breathing out the valve opens and releases the extra pressure without blowing out the sides (not really a problem per-se, but would compromise your protection).