reorg and add constraint doc