Here’s a way of comping on a static modal vamp. The kind of thing that might be appropriate on a tune like ‘So What’ or ‘Impressions.
Learn the D Dorian mode on the D string. Then get it down on the G string. I’ve shown it here starting from D (on the G string) so you’ll hear it from a D tonality and not G, which you might do if you just played the right notes but started from G. Anyhow, if you play/record a lovely D minor chord and play these notes over it, it won’t matter what note you start from because you’ll be hearing it in the right way.
Next, play some notes on the D and G strings together. Here I’ve opted for 4ths. Learn this up the neck and then use it to comp. Think melodically with these dyads. Comp in 2 bar/4 bar/8 bar chunks.
If you can’t make it sound like music then you need to listen to how Bill Evans comps on ‘So What’. He’s rather good at that.