Even if you're improvising the fact that beforehand you know certain things will work helps you make those improvisations successful. It really helps to have a certain amount of knowledge about musical structure.
Death be not proud though some have called thee Mighty and dreadful for thou art not so. For those whom thou think'st thou dost overthrow. Die not poor death nor yet canst thou kill me.