I think it would be better if you would explain what you are trying to do, and when it should happen in non-rule terms. "I want the bathroom light to go on except when I double tap a switch" or something like that.
I found it to be easier to have Private Boolean separated out of the main rule. It makes it easier to write, easier to diagnose, and you can reuse the PB in multiple rules if desired. You certainly can have it incorporated like you did, but to me two shorter and simpler rules was far better than one convoluted one.
But to me, this looks like Motion Lighting (as mentioned above) could handle things much simpler than this rule. If you want lights to have a warning before going out, or to fade out, then I really like Lights On Motion Plus community app. It has some really slick features that I think Motion Lighting should have had. [RELEASE] Lights on Motion Plus (dim before off, remember individual bulb states, etc.)