← Back to PRs

#11457: feat: Add hybrid memory mode with auto-created daily log templates

by Undertone0809 open 2026-02-07 20:53 View on GitHub →
stale
This PR adds an optional "hybrid" memory mode that automatically creates daily log templates while keeping manual control over content. ## Features - Auto-create daily log templates (empty structure with custom template) - Daily review reminders at configurable time - Session-end memory prompts after meaningful conversations - Fully backwards compatible (opt-in via memory.mode: "hybrid") ## Configuration ```json5 { "memory": { "mode": "hybrid", "hybrid": { "enabled": true, "dailyLog": { "enabled": true, "template": "# {{date}} - Daily Log\n\n## Notes\n\n## Key Learnings\n", "createDaysAhead": 1, "createAt": "22:00" }, "dailyReview": { "enabled": true, "at": "22:00" }, "sessionEnd": { "prompt": true, "minDurationMinutes": 5 } } } } ``` ## Files Added - src/memory/hybrid/daily-memory.ts - Daily log template management - src/memory/hybrid/daily-review.ts - Daily review reminder system - src/memory/hybrid/session-end-prompt.ts - Session-end prompting logic - src/memory/hybrid/index.ts - Public API exports ## Files Modified - src/config/types.memory.ts - Added MemoryMode and MemoryHybridConfig types - src/config/zod-schema.ts - Added Zod validation for hybrid config <!-- greptile_comment --> <h2>Greptile Overview</h2> <h3>Greptile Summary</h3> This PR introduces an opt-in `memory.mode: "hybrid"` configuration plus a `memory.hybrid` section, and adds a new `src/memory/hybrid/*` module set for daily log template creation, daily review reminders, and session-end prompting. The config surface is wired into `src/config/types.memory.ts` and validated via Zod in `src/config/zod-schema.ts`, while the new hybrid helpers live under `src/memory/hybrid/` and are re-exported via `src/memory/hybrid/index.ts`. <h3>Confidence Score: 2/5</h3> - Not safe to merge until the hybrid reminder/prompt paths are fixed to use valid agent workspace resolution and lint passes. - There is a definite runtime exception in the new hybrid code path due to calling `resolveAgentWorkspaceDir` without the required `agentId`, and there is at least one guaranteed unused variable that can fail CI lint/typecheck. These are straightforward to fix but must be resolved before merging. - src/memory/hybrid/daily-review.ts, src/memory/hybrid/session-end-prompt.ts <!-- greptile_other_comments_section --> <sub>(2/5) Greptile learns from your feedback when you react with thumbs up/down!</sub> **Context used:** - Context from `dashboard` - AGENTS.md ([source](https://app.greptile.com/review/custom-context?memory=0d0c8278-ef8e-4d6c-ab21-f5527e322f13)) <!-- /greptile_comment -->

Most Similar PRs