Use type switch to be more safe when getting the type
tweaks
Proof of concept caching works