changed term_finder.py to file with functions