How can a new python library be added such as ast or astor in the python interpreter?

try this solution Module for Internal Dosimetry in Nuclear Medicine

basically at the end do

install_and_import('astor')