Add preprocess to handle malformed building types