Cache example
Closes #767
Closes #787
Fix examples
closes #788