Ported over most of the old schema