added initial framework for using plugins