first attempt at #428
add caching