A characterization of almost relatively free, finite $p$-groups Let $G$ be a finite minimally $d$-generated $p$-group.
If $G$ is relatively free, that is $G$ is a quotient of the free group $F$ on $d$ generators by a fully invariant subgroup of $F$, then the order of $\operatorname{Aut}(G)$ reaches its maximal value $|\Phi(G)|^d|\operatorname{GL}(d,p)|$.  I thaink this holds also if $G$ is a quotient of $F$ by a characteristic subgroup.
Is the converse true? that is, is true that if $|\operatorname{Aut}(G)|=|\Phi(G)|^d|\operatorname{GL}(d,p)|$, then $G$ is a quotient of the free group on $d$ generators by a characteristic subgroup?
Thanks in advance.
 A: Yes, it is true that if $G$ is a $d$-generated $p$-group, and $|\operatorname{Aut}(G)|=|\Phi(G)|^d|\operatorname{GL}(d,p)|$, then $G$ is a quotient of the free group on $d$ generators by a characteristic subgroup.
Let $F_d = \langle x_1, \dots, x_d \rangle$ be the free group on $d$ generators, and consider a surjection $\pi : F_d \rightarrow G$ sending the $x_i$ to some generators $g_i$ of $G$. The assertion that $\ker \pi$ is a characteristic subgroup of $F_d$ is equivalent the assertion that every automorphism of $F_d$ descends to an automorphism of $G$.
Saying $\operatorname{Aut}(G) = |\Phi(G)|^d|\operatorname{GL}(d,p)|$ is equivalent to saying that every generating $d$-tuple of $G$ is the image of $(g_1, \dots, g_d)$ under some automorphism of $G$ (i.e. that $\operatorname{Aut}(G)$ acts transitively on the generating $d$-tuples of $G$). In particular, if this is true then for any automorphism $\phi: F_d \rightarrow F_d$, we have $G = \langle \pi(\phi(x_1)), \dots, \pi(\phi(x_d)) \rangle$, so some automorphism of $G$ sends $g_i = \pi(x_i)$ to $\pi(\phi(x_i))$ for every $i$, which means that $\phi$ descends to that automorphism.
However, I'm not convinced it's true that if $G$ is the quotient of $F_d$ by a characteristic subgroup, then $\operatorname{Aut}(G) = |\Phi(G)|^d|\operatorname{GL}(d,p)|$. In "On a question of Gaschütz", B.H. Neumann gives an example of a finite 2-group with more than one T-system. Specifically, it's a group of rank $2$ in which the order of the commutator $[a,b]$ is not the same for all generating tuples $(a,b)$. That order is an invariant under Nielsen transformations. I can think some more and expand on this if necessary.
