================ Usage as library ================ TODO