I have a notebook that I take with me everywhere. I free-write in it when there are situations that I know I can write a song about. I will just start writing everything that I can think of while trying to write some things that are kind of poetic or sound like they could be in a song. Then, after the music is written, I go back and look at my subjects to see which one I think woud go with what music. Then, I formulate it into a melody and get the song.