Added support for tasks and worked on performance