This is common for players who learn "licks." I call them embellishers not improvisors. They become divorced from the melody and just follow the chord progression. I have attended several improvisation workshops and some of the presenters have actually taught to just play anything. WHAT!?!?!?! That like is be anything saying anywhere inject ish you.
I love Oscar Peterson but if you transcribe his music, after several pieces you'll quickly realize he plays the same scales, patterns and arpeggios in every song. He is still genius. Those licks have become his vocabulary and distinguishes himself from every other player. Each musician needs to develop their own vocabulary.
Everyone is offering great advice. I would first suggest learning how to utilize upper and lower neighbors and passing tones to chord tones and melodies then use licks to get between points A and B if you need to. Then, play less. Winnow it down. My favorite improvisors are those who don't play a blizzard of 64th notes.
I admit that I need much work on this topic but as an organist, I improvise mood for ritual rather than solos. Here is a very simple example of "Mary Had A Little (flea infested, toxoplasmosis ridden) Lamb" utilizing UN, LN and PT's. I would also suggest looking into the Schillinger System of Musical Composition to imprint how to craft a solo so that it actually goes somewhere, has a climax then comes back down rather than just rambling along to nowhere.