I think it depends... I'm a singer/lyricist who can't play an instrument, but I have a guy who I work closely with who can. Now, sometimes he'll send me a piece of music, in which case I'll immediately set about creating the melodies. However, sometimes I'll feel inspired and the lyrics will just come pouring out. In the latter case, I always try and be mindful of the rhythm of the words, so that when the time comes to put a melody to them, the task is a lot easier.
Like you said though, there ain't no magic formula and the best approach obviously depends on the person.