async def schedule(self) -> None:
        """Run all tasks in self.tasks in parallel, respecting dependencies."""
        # run until all tasks are done
        while not self._all_tasks_done():
            # Find tasks with no dependencies or with all dependencies met
            executable_tasks = self._get_all_executable_tasks()

            async_tasks = []
            for task_id in executable_tasks:
                async_tasks.append(self._run_task(self.tasks[task_id]))
                self.remaining_tasks.remove(task_id)
            await asyncio.gather(*async_tasks)

            await asyncio.sleep(SCHEDULING_INTERVAL)
Run all tasks in self.tasks in parallel, respecting dependencies.
llama-index-packs/llama-index-packs-agents-llm-compiler/llama_index/packs/agents_llm_compiler/task_fetching_unit.py