The short answer is that the performance is affected by the number of rules and objects, the number of tests, how you order the tests in your rules, and how many tests/conditions are shared between rules.
You should rewrite rules for optimal performance by:
- Reordering tests and conditions so that the most discriminating conditions are moved to the beginning of the rule
- Sharing conditions
See the Adjusting conditions IBM ODM documentation.
You should also reduce the number of objects that need to be evaluated by rules, and the number of tests.
For your reference regarding Rete and IBM ODM:
RetePlus is designed to optimize the evaluation of large numbers of
rules across large numbers of objects. RetePlus filters the tests such
that irrelevant tests are not evaluated. Tests can be shared between
rules that use similar tests so that they do not need to be
re-evaluated for all the rules.
For the best results:
Common tests on different objects are shared.
The number of tests carried out are minimized.
Performance degrades when a single evaluation contains too many variable definitions and conditions.
The test uses less memory.