How do I remove some remote participants based on an attribute so they don't get shown in the UI?

Would PARTICIPANT_JOINED in participants/reducer.js be a good starting point, or should I look somewhere else? I want to remove them before anything gets rendered

You could consider using the same hidden domain functionality that Jibri uses. Authenticate those participants to the XMPP domain configured as hiddenDomain in config.js, and they won’t appear in the UI. There is some discussion in this thread.