feat(planner): add execution context to prompts
Tests / Test passed: 977

This commit is contained in:
2026-07-16 10:25:20 +08:00
parent 240b7be7b8
commit 358f4623ba
9 changed files with 159 additions and 3 deletions
@@ -50,6 +50,9 @@ def create_execution_factories(
timeline=timeline,
planner=_host_agent_planner(resolved_host_agent_config),
planner_config=_host_agent_planner_config(),
device_platform_provider=lambda device_id: _device_platform(
manager, device_id
),
)
def create_workflow_runner() -> WorkflowRunner:
@@ -103,3 +106,15 @@ def _host_agent_planner(
client=CloudProxyToolCallingClient(resolved_config),
config=planner_config,
)
def _device_platform(manager: DeviceManager, device_id: str) -> str | None:
for device in manager.list_devices():
if device.id != device_id:
continue
if device.driver_type == "wda":
return "ios"
if device.driver_type == "uiautomator2":
return "android"
return None
return None