i've made some changes which make it more accessible and less hackish