gpt-3.5-turbo-0301· OpenAI
WildChat-4.8M (AI2)
Write a yaml file to turn on a switch when roomba is away from dock, and turn switch off…
- User
Write a yaml file to turn on a switch when roomba is away from dock, and turn switch off when roomba returns to dock
- Assistant
trigger: # When the state of the roomba changes platform: state entity_id: sensor.roomba_status condition: # Check if roomba is away from the dock condition: template value_template: "{{ states('sensor.roomba_status') == 'Away from Dock' }}" action: # Turn on the switch service: switch.turn_on entity_id: switch.my_switchtrigger: # When the state of the roomba changes platform: state entity_id: sensor.roomba_status condition: # Check if roomba is back at the dock condition: template value_template: "{{ states('sensor.roomba_status') == 'Back to Dock' }}" action: # Turn off the switch service: switch.turn_off entity_id: switch.my_switchNote: replace
sensor.roomba_statusandswitch.my_switchwith your own entity names. Also, ensure that thesensor.roomba_statusentity is reporting the status correctly.
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.