0c351738fa
- Added auto-retry event tracking and message-end event handling to improve agent completion detection. - Implemented is_effectively_complete() method to detect agent completion based on review sections, todo state, and quiet period. - Enhanced wait_for_settle() logic to handle auto-retry delays and graceful timeout recovery instead of immediate failure. - Added token usage tracking from partial message updates to capture intermediate token counts. - Refactored note_tool_end() to only update activity on error, removing redundant success case. - Removed last_activity updates from todo reminder and auto-clear handlers to simplify state management.