Try writing your equation explicitly with a conditional expectation operator:

$$ \mathbb{E}_t f(\alpha_t, \beta_t, s_t, s_{t+1}) = 0$$

Hopefully this clarifies things.  You can take the total derivative as you normally would with any function, however $s_{t+1}$ is a random variable since it is not predetermined.  Ultimately you are considering all cases of $s_{t+1}$ weighted by their probability.

Since $\mathbb{E}_t$ integrates over shocks, you can differentiate under the integral sign by Leibniz's integration rule.