It is not unfrequent to listen to performers who, when nothing concerning the dynamic is explicitely written in the score, tend to play louder whenever the phrase tends to go towards the higher register.
Notice that we are not claiming at all this one to be an objectively reasonable rule, but just that there are players who, consciously or unconsciously, do follow it.
So, in our tool one could import it among the used rules and listen whether the use of such a rule improve or not the overall musical effect.
The rule we are considering now is a typical example of a parametric rule, sice, whenever we wish it to be used, we first need to specify a parameter. This means also that we can experiment with this parameter listening at the effect of different performances one can obtain by varying it.
To better understand what this parameter means, let us look at how we have implemented such a rule. Given a phrase, we first represent it as a function from time to pithch. Of course what we obtain is a step function

pitch

  ^
  | 
  | 
  | 
  |-- 
  | 
  | 
  | 
  | 
  | 
  | 
  |------------------------------------------------- > time