Note that Calibre uses forward slashes (/) for folders in Save to disk templates.
Plus given backslash is a special character for regex, I think the use of it in tags or custom columns might prove problematic for templates. Is there a reason for using \ in tags? If it's just to create folders for Save to disk templates, then you don't need to.
Example:
Save to disk template
Code:
{#fandom:re(\.,/)}/{#storyid}/{author} - {title}
#fandom (hierarchichal)
Xover.Buffy.Supernatural
#storyid
9797629
author
hoshi-ni-onegai
title
Eternal Oblivion
This will give me the following structure:
Code:
Xover/
Buffy/
Supernatural/
9797629/
hoshi-ni-onegai - Eternal Oblivion.epub