Create sub task in different candidate group

we have a requirement to create parent task and sub task where parent task is in one candidate group and sub task is in other candidate group. creation of sub task is dynamic/runtime. also want audit history and when we query based on candidate group user can see task for approval.

Thanks in advance for help !!!