Refactored source to doc