When you use %t you need to call the native SetGlobalTransTarget before hand. There's also the %T modifier which takes a client with it, which will ~automagically~ set the translation target to that client.
It also looks like you don't close any Datapack handles
Which would be responsible for the leak reported above. CompileRegex leaks in the main plugin, as well