Ecribes import despues el modulo, aqui el import random elige un numero aleatorio.
Este video me ayudo a enteder mas sobre esto, espero les pueda ayudar:
importing and using python modules by Pato Valdez is licensed under a Creative Commons Attribution 4.0 International License.