fix doc
refactor cli; move cli to module