You almost surely don’t want to use the module hook but add mysomething.register_hook(...) on the variables.
For example I use (from the top of my head) mysomething.register_hook(lambda x: x.clamp(min=-10, max=10)) for recreating Graves’ handwriting RNN.
Best regards
Thomas