update mempool lib and add some docs