Add thread class for parallel tasks