Letter codes in molecular term symbols
Quoting from Hollas, Modern Spectroscopy, 4th ed. (p 236):


  There is a convention, which is commonly but not always used, for labelling electronic states. The ground state is labelled $X$ and higher states of the same multiplicity are labelled $A, B, C\ldots$ in order of increasing energy. States with multiplicity different from that of the ground state are labelled $a, b, c \ldots$ in order of increasing energy.


As such, for the oxygen molecule, where the lowest three states are ${}^3{\Sigma}_g^-$, ${}^1{\Delta}$ and ${}^1{\Sigma}^+_g$ (in increasing order of energy), the triplet ground state would be labelled $X$ and the next two states $a$ and $b$ respectively.

A word of caution: it seems that this convention is not always obeyed. On the next page, Hollas writes (for $\ce{I2}$, where the ground state is a singlet)


  The transition $B\,{}^3{\Sigma}_{0_u^+} - X\,{}^1{\Sigma}_g^+$ involves the $\Omega = 0$ component of the $B$ state [...] The labelling of the $B\,{}^3{\Sigma}_{0_u^+}$ state follows general usage rather than convention, which would label it $b\,{}^3{\Sigma}_{0_u^+}$.


Wikipedia also adds, although without a citation:


  In polyatomic molecules (but not in diatomics) it is customary to add a tilde (e.g. $\tilde{X}$, $\tilde{a}$) to these empirical labels to prevent possible confusion with symmetry labels based on group representations.