How do you come up with melodies if not improvising? I think every composers improvise, only in non-fixed composition like jazz you can't edit your work - not to mention the head part - since the solo part is also integral to whole composition. However, you can still not improvise in the way of ripping off.