reworking to simplify and add more flexibility on tasks selection