|Stuff like this. Anything. Why not?|
Broadening your hearing
Doing this gives you a chance to hear how the technical patterns sound in the context of real music, and will help you move them into your actual playing— which is a major issue nearly everyone deals with. Since you'll be forcing these things into a musical setting where they don't necessarily belong, you're going to hear a lot of things happen—good and bad— which you never would have played on purpose. You'll be surprised at how often random things actually work together, though. It's a crash course in the Rubber Shirt principle— random musical ideas tend to work together because you put them together.
What and how
You can use anything that will work with the tempo and feel/rhythmic grid of the recording. You can decide for yourself how much you want to conform to the song: you could follow the form or phrasing of the song, changing exercises along with song phrases or sections, or not. You could also alternate exercises with playing time in the style of the track. On the more advanced end of things, if you're learning how how to play meter-within-meter, you could run exercises in 3/4 or 6/8 along with a song in 4/4, and practice improvising resolutions of the resulting polyrhythmic phrases to match the phrase endings in the song.
A musical standard
Often when doing your technical exercises in isolation with a metronome, you have no external reason to play them with some shape, so you play them with a “neutral” phrasing and dynamic level, and your one standard of progress tends to become simply more speed. Playing them along with music, suddenly the problem becomes how to make them sound and feel good with what you're hearing— which is the whole name of the game in actually playing music. For me, anyway; music is nearly always a process of making whatever you're playing feel good based on what you're hearing; it is almost never just a process of just rendering patterns perfectly. For me. That's not to say there's nothing to be gained by learning to render patterns precisely in a neutral, non-musical way, but that is a different process than the one you will use in actually making music.
More coming soon...