refactored structure of doc