rename RuleTree to ruleTree to not confuse as a class
fix string patching