Update doc, refactor some naming.