Consider the locus of smooth curves of genus g and p-rank f defined over an
algebraically closed field k of characteristic p. It is an open problem to
classify which group schemes occur as the p-torsion of the Jacobians of these
curves for f < g-1. We prove that the generic point of this locus has a-number
1 when f=g-2 and f=g-3. We include other results for curves with p-rank g-2 and
g-3. For example, we show that the generic hyperelliptic curve with p-rank g-2
has a-number 1 and that the locus of curves with p-rank g-2 and a-number 2 is
non-empty with codimension 3 in M_g. The proofs use degeneration to the
boundary of M_g.Comment: final version, to appear in International Journal of Number Theor