Reuse the server turn-budget planner for opt-in auto-commit retention, preserve manual full compaction and setup configuration, and handle zero retained turns when rebuilding pending tokens.
Refs #4415 (items 3 and 6).
Co-authored-by: tangtao <1024583279@qq.com>