persist to pickle, json