bringing the “state” of meditation into the compulsion when and where it happens. Since you have been practicing meditation for a while, you know the “feeling” of it, you know how different the mind is during meditation. So, during your day, when compulsion appears, bring in that meditation feeling. Then watch the difference in your body and mind before bringing the meditation and after it.
On the flip side, practice bringing your compulsion triggers inside your formal meditation practice. One day when you sit in meditation and feel your session is going deep, start bringing to mind the several triggers for your compulsion. Observe the effects of it in your body, in your nerves, in your mind. Learn to refine your attention to catch the “triggers” (external and internal) that produce that state. And observe how there is a space between you and the feeling – and the ability to choose to identify with it or not. To follow it or not.