If you are coming up with better ideas by just playing, that's cool and is probably what you should do. Humming something over a rhythm helps get ideas out quicker, and if you record yourself humming over a track. It gives you a guideline to what and how to play the solo when you go to figure out what kind of solo and how you want it to sound. Here's how I do it.
1) Hum over the entire part I want to solo over. Usually take a few takes and then choose the one I think expresses a better sounding solo.
2) Go back and measure by measure take what I hummed and figure it out on the guitar. Like I hummed, "da dadada" over a C chord. Then I mess with the C major scale and find something that sounds cool using the "da dadada" I hummed as a foundation of what to play.
Fact is alot of time and unless you sing excellently in tune, the notes you hummed might be alittle flat or sharp. Or you could use what you hummed to figure out something that sounds cooler. Another tip is not to play so much attention to the exact notes you hummed, but how they progress melodically.
So say the second note you hummed was higher than the first, and then it follows this pattern.
higher, lower, same, higher, lower.
You know when you apply the scale, the melody from note to note should follow the same pattern. Often it is possible to figure how high or low the interval is from note to note.
You still have to figure out what it is you hummed and also fix it melodically so that it all fits together. What benefit and problem humming and recording yourself remedies is, "what should I do or play next". And if you go by what you hummed, it should progress for one idea to the next rather smoothly. Both of these are common problems faced by novice soloists and some professionals.
Humming gets the ideas out. The two or three important things to pay the most attention to are:
1) the rhythmic progression of what you hummed. Even when you go back and actually add the solo, it's good not to change the rhytmic progression. Rhythm is the most common cause of breaking the progression of the musical idea. You can add ornamentation but keep the rhythmic motive the same.
2) The melodic progression from note to note (higher or lower). This you can change to make the solo sound better with the harmony play under it. But like the rhythmic motive, be careful not to change the basic interval progression too much.
3) Any synthetic sounds you emulate in your humming. Example would be a wild tremelo or pick slide. You can imitiate the sound where you want it and then just figure out later.
Hopefully that helps. Humming out ideas shouldn't be a strict process, your basically just brainstorming ideas out in sound. Then using your guitar training to make into actually music.
"My whole life is a dark room...ONE BIG DARK ROOM" - a.f.i.