code cleaning, doc enhancemenet