Defining a pattern as string for use in hydra

I would like to be able to define a pattern as a string in one of the format accepted by tidal (note, struct, etc) so that I can then process it and reuse it in hydra.

For example I have a note pattern with silences:

  "[0 - - 0] [- 3] [- 3 - -] [-2]"

I want to use it in hydra kaleid function using H, however the - aren’t correct values for kaleid and this triggers errors in the console.I would like to programatically replace values like - => 0 before feeding it to H in hydra.
Is that possible?

The problem I am facing currently is that I can’t call .replaceAll on the string as they seem to all be preprocessed and converted to an object.