adding features modify task, fix some bugs