yep..
you would have to extend xpath functions to generate a random number.. something like this:
<xsl:stylesheet version="1.0" xmlns:inatos="uri://none" xmlns:xsl="
xmlns:msxsl="urn:schemas-microsoft-com:xslt">
<msxsl:script language="JavaScript" implements-prefix="inatos">
<![CDATA[
function rand()
{
return "" + Math.random();
}
]]>
</msxsl:script>
<xsl:template match="/">
<xsl:value-of select="inatos:rand()"/>
</xsl:template>
</xsl:stylesheet>
Heres something to do too, try to make the function take an argument from a node value , and seed the random number

Hint: you are passing a node to the function, and therefore have to treat it like a node, not an int!
This only works with MSXML, and you would have to find other ways of doing with other engines...
There are some good pre-made packages to do this sort of thing for other engines at
Hope that points you in the right direction...!