restructure pyatta api
add doc string and comments