Anyway a few weeks later and a bored friday night dynamic salience expressions are born :) The salience value can now be derived from an expression that has full access to the variables bindings, ofcourse integer values can still be specified. Before, during conflict resolution, the salience value was read directly from the rule on each comparison, now when the Activation is created the salience value is determined once and stored in the Activation for comparison during conflict resolution. So now you can write things like have rules with the highest priced items combined with the shoppers bonus rating fire first:
rule "high value fires first"
salience (person.bonus * item.price)
person : Person()
item : Item()
MVEL is used for the salience expressions, as part of the pluggeable dialect system we have just built - I'll blog on pluggeable dialects and parsers next week.
Update -- Thanks to Johan Lindberg, who has pointed out that Clips and Jess allow the salience to be set via function calls in Jess/Clips.