Move types into their own modules