According to this thread on plotly forum, it seems it is not possible to make persistence work when the value of the component is set by a callback. Perhaps it is possible to circumvent this with a dcc.Store component.
persistence
dcc.Store