refactor structure, add document