optimize: implemented incremental save.