Closed
Conversation
Add Pomodoro timer feature that controls perception layer (screenshot/keyboard/mouse capture) based on work sessions. Implements an idle-by-default strategy where perception only runs during active Pomodoro sessions. **Core Changes:** - Add PomodoroManager to handle session lifecycle and coordinate with perception layer - Implement session database storage (pomodoro_sessions, raw_records tables) - Create API handlers for starting/stopping Pomodoro sessions - Add migration system with initial schemas and Pomodoro feature migration **Perception Layer:** - Remove _pomodoro_mode flag from ScreenshotCapture (Pomodoro only controls start/stop) - Fix screenshot capture blocking issue by removing run_in_executor - Simplify screenshot loop to call capture() directly in async context - Improve timing accuracy by compensating for execution time in sleep **Architecture:** - Idle Mode (default): Perception layer stopped, zero resource usage - Active Mode (Pomodoro): Perception layer running, captures activity data - Session data persisted to database for deferred batch processing - SessionAgent paused during Pomodoro, resumes after for activity aggregation **Frontend:** - Add PomodoroTimer component with start/stop controls - Create pomodoro Zustand store for state management - Add Tauri event handlers for Pomodoro processing events - Add i18n translations for Pomodoro UI **Documentation:** - Update .project.md with Pomodoro mode principles and design rules - Document that Pomodoro has no system configuration parameters - Clarify that capture behavior (smart capture, deduplication) is not affected by Pomodoro mode **Technical Notes:** - macOS Core Graphics requires screenshot capture in main event loop context - Thread pool execution causes 30s blocking on sct.grab() - resolved by direct async calls - Loop timing controlled by asyncio.sleep() with execution time compensation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add Pomodoro timer feature that controls perception layer (screenshot/keyboard/mouse capture) based on work sessions. Implements an idle-by-default strategy where perception only runs during active Pomodoro sessions.
Core Changes:
Perception Layer:
Architecture:
Frontend:
Documentation:
Technical Notes:
Add dedicated Tauri event emitters for Pomodoro processing:
Resolves all TODOs in pomodoro_manager.py by integrating with the existing event system infrastructure.