<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:ssml="http://www.w3.org/2001/10/synthesis" exclude-result-prefixes="#all" version="2.0"> <xsl:template match="@*|node()" priority="1"> <xsl:copy> <xsl:apply-templates select="@*|node()"/> </xsl:copy> </xsl:template> <xsl:template match="text()[not(ancestor::ssml:token[1])]" priority="2"> <xsl:value-of select="replace( replace(normalize-unicode(., 'NFKC'), '[\p{Z}]+', ' '), '[^ \p{Pi}\p{Pf}\p{N},!?:;.()¿؟¡%"''&™®©՜߹႟᥄፣ꇾ᠈᠂߸꘍՝꛵،、…ຯ᠁።՜෴。।۔;؛⁏፣꛶׃:ॐ॥॰؞؟۔ُ]', ' ' )"/> </xsl:template> </xsl:stylesheet>