Stallings-Stammbach sequence

Definition
The Stallings-Stammbach sequence is a slight generalization of the Stallings exact sequence. Suppose we have a short exact sequence of groups:

$$1 \to N \to G \to Q \to 1$$

Suppose that $$B$$ is a $$Q$$-module, i.e., an abelian group equipped with a homomorphism of groups:

$$Q \to \operatorname{Aut}(B)$$

The Stallings-Stammbach sequence is the following short exact sequence of groups:

$$H_2(G;B) \stackrel{\alpha_B}{\to} H_2(Q;B) \stackrel{\beta_B}{\to} N^{\operatorname{ab}} \otimes_Q B\stackrel{\sigma_B}{\to} H_1(G;B) \stackrel{\tau_B}{\to} H_1(Q;B)$$

In the case that $$B = \mathbb{Z}$$ with trivial action of $$Q$$ on it, the Stallings-Stammback sequence becomes the Stallings exact sequence.