Features/code optimize

Update Task component interface to simplify the client (chart) code. This new interface definition is based on the inspiration from npm module"Flow".