adding logic to extract decision tree model