The probabilities describing the possible outcome of a single trial are modeled, as a function of explanatory (independent) variables, using a logistic function or multinomial distribution.
Another alternative is to use maximum likelihood estimates to calculate a p-value from the exact binomial or multinomial distributions and fail to reject or reject based on the p-value.
Note that this differs crucially from the above formula in having an extra term at the front that looks like the factor at the front of a multinomial distribution.