I've really enjoyed using node-red together with Home Assistant. Home Assistant manages the connections to devices and allows me to set up a nice UI, while node-red allows me to do more complex automation logic.
node-red is available as a hass.io add-on [1], with the Home Assistant node-red plugin pre-installed