| 18 | return f"System: {self.system_prompt}\nHistory: {self.conversation_history}\nCurrent Query: {self.current_query}" |
| 19 | |
| 20 | class MCTSNode: |
| 21 | def __init__(self, state: DialogueState, parent=None): |
| 22 | self.state = state |
| 23 | self.parent = parent |
| 24 | self.children = [] |
| 25 | self.visits = 0 |
| 26 | self.value = 0 |
| 27 | |
| 28 | class MCTS: |
| 29 | def __init__(self, simulation_depth, exploration_weight, client, model, request_config=None, request_id=None): |