Here’s a rather long loom of me struggling with this issue and even documenting the inconsistency of replicability.
Short Summary
st.cache
seems to not work properly when modifying the state of predictive model.
Here’s an example of a function that gets triggered with every change
And here’s an example of a function that does not get triggered with every change
The mcmc.run
function is running a model which modifies the state of the mcmc object in the session_state, however, it should only be triggered when the arguments change.
For some reason, it’s triggered with every change.