(
self,
model_config: ModelConfig | None = None,
agent_config: AgentConfig | None = None,
confirmation_callback: Callable[[str], bool] | None = None,
takeover_callback: Callable[[str], None] | None = None,
)
| 62 | """ |
| 63 | |
| 64 | def __init__( |
| 65 | self, |
| 66 | model_config: ModelConfig | None = None, |
| 67 | agent_config: AgentConfig | None = None, |
| 68 | confirmation_callback: Callable[[str], bool] | None = None, |
| 69 | takeover_callback: Callable[[str], None] | None = None, |
| 70 | ): |
| 71 | self.model_config = model_config or ModelConfig() |
| 72 | self.agent_config = agent_config or AgentConfig() |
| 73 | |
| 74 | self.model_client = ModelClient(self.model_config) |
| 75 | self.action_handler = ActionHandler( |
| 76 | device_id=self.agent_config.device_id, |
| 77 | confirmation_callback=confirmation_callback, |
| 78 | takeover_callback=takeover_callback, |
| 79 | ) |
| 80 | |
| 81 | self._context: list[dict[str, Any]] = [] |
| 82 | self._step_count = 0 |
| 83 | |
| 84 | def run(self, task: str) -> str: |
| 85 | """ |
nothing calls this directly
no test coverage detected