You might have multiple triggers in some of your automations, and sometimes these triggers can be triggered within few minutes or even seconds. I will show you how to detect when an automation was last triggered in Home Assistant, so you can use this as an condition.

Add a condition, choose “Template”, and paste this into “Value template”.
The last number, is the number of minutes you want there to be between runs of the automation.
Relace “automation.roomba_notification_when_out” with the automation you are working on.
{% set nw = now() %}
{% set last = state_attr('automation.roomba_notification_when_out', 'last_triggered') %}
{{ 00 <= nw.hour < 24 and
(last is none or (nw - last).total_seconds() > 60 * 6) }}
This really helps me in automations with multiple triggers, or if I have multiple automations for the same action. It can be annoying to get spammed with Actionable Notifications, and this will help you put some time in between.
This was made and tested with Home Assistant version 2023.12.4