Refactor some names, add boolean type and add samples