preliminary caching system (slightly faster but disorganized)