(self)
| 471 | ) |
| 472 | class MultiTurnWorkflowTest(unittest.IsolatedAsyncioTestCase): |
| 473 | async def asyncSetUp(self): |
| 474 | # configure the model |
| 475 | self.config = get_template_config() |
| 476 | self.config.mode = "explore" |
| 477 | self.config.model.model_path = get_model_path() |
| 478 | self.config.explorer.rollout_model.engine_num = 1 # self.engine_num |
| 479 | self.config.explorer.rollout_model.tensor_parallel_size = 1 # self.tensor_parallel_size |
| 480 | self.config.explorer.rollout_model.chat_template = CHAT_TEMPLATE |
| 481 | self.config.algorithm.repeat_times = 2 # self.repeat_times |
| 482 | self.config.explorer.rollout_model.enable_history = True # self.enable_history |
| 483 | self.config.check_and_update() |
| 484 | allocator = Allocator(self.config.explorer) |
| 485 | rollout_model, _ = await allocator.create_all_models() |
| 486 | self.model_wrapper = rollout_model[0] |
| 487 | await self.model_wrapper.prepare() |
| 488 | |
| 489 | async def test_multi_turn_workflow(self): |
| 490 | task = Task( |
nothing calls this directly
no test coverage detected