That's a relay job if you ask me.
I don't have any hands on with this issue. But DMs are a totally different note kind, so when "mentioning" someone that @ or npub is stored in the ciphertext so I client cant know about the mention until its decrypted? I'm curious where parsed cihpertext model overlaps with the rendering of new message "channels". Weird. How is this a relay issue? Relay should be unaware of a "mention" in a DM.