I think the way to do this is by having a constraints module. We can have some built in constraint check (like weight, thresholds, etc), and we can have the ability for the user to build their own in the module based on reading from a tally output (or where ever). The input would then require the user to specify the function name and any required parameters (ex tally number).