working indexing and searching, it is slightly hacked though, will fix soon
Better trec indexing