bug fix and write doc