WIP: wrapper function based on github project