Rewrite metadata scheme