Notification script at arming - silent for persons out of home, loud those at home

Hi all,

My HA alarm system is “automatically” arming/disarming based on presence of persons.
For each person I have created a helper with status just left - away - just arrived, extended away.

I want to create a script that I can trigger when the alarm is arming.
The script should.

notify with sound - only users that are home (or just left / just arrived).
notify w/o sound - only users that are away / extended away.

Note that I have some users that I want to exclude (e.g, housekeeper).
And I use Pushover as notification service. I know how to do this.

I found some inspiration here
([notify] add notify service to person/zone attributes or create notify services for persons/zones · home-assistant · Discussion #586 · GitHub)

Can somebody help me create the script, not using zones as in the example but use my helpers instead. Script should also have the opportunity to exclude some users (such as the housekeeper).

Thanks for help!

Jules