Added DocumentVector class to genericalize the code
added test for DocumentVector
removed unused code