rule engine implementation first session