@st.cache_resource
Also written: st.cache_resource, cache_resource
A Streamlit decorator that creates an object once and shares the same object with every session, such as an API client, a model, or the shared daily question counter. Use it for live objects, not for data you could save to a file.