What
A `smriti watch` command that monitors agent log directories via `fs.watch()` and auto-ingests new/changed sessions in real-time.
Why
Currently ingestion is manual (`smriti ingest claude`). Developers forget to run it, or run it too late after context is cold. Auto-ingestion means Smriti always has the latest session data available for search and recall.
Tasks
Files
- `src/watch.ts` — new Watch daemon implementation
- `src/index.ts` — Add `watch` command to CLI
- `src/config.ts` — Add watch-related config vars
- `test/watch.test.ts` — new Watch daemon tests (using temp directories)
Acceptance Criteria
Testing
bun test test/watch.test.ts # Unit tests with temp dirs
smriti watch # Manual: start watching
# In another terminal, use Claude Code — sessions should auto-ingest
smriti watch --status # Check daemon status
smriti watch --stop # Stop cleanly
What
A `smriti watch` command that monitors agent log directories via `fs.watch()` and auto-ingests new/changed sessions in real-time.
Why
Currently ingestion is manual (`smriti ingest claude`). Developers forget to run it, or run it too late after context is cold. Auto-ingestion means Smriti always has the latest session data available for search and recall.
Tasks
Files
Acceptance Criteria
Testing