Resolve #9: Add @ttl_cache function decorator.