Reorganize the Document model.