Added the unfinished refactored bdt script