fixed more of searching infrastructure, first attempt at cache garbage collection, reorganize models in views.