Skip to content

Weekly Review: /week command#21

Open
cristoforows wants to merge 1 commit into
mainfrom
wesley/weekly-review
Open

Weekly Review: /week command#21
cristoforows wants to merge 1 commit into
mainfrom
wesley/weekly-review

Conversation

@cristoforows

Copy link
Copy Markdown
Owner

Closes #16.

What

Auth-gated /week: an LLM-summarized review of the notes captured over the last 7 daily Drive files — the higher-altitude counterpart to /today.

Note: this was reworked from the original 'morning briefing' idea (issue #16), because that depended on the Google Calendar infrastructure which currently lives on an unmerged branch. /week is buildable on main today and reuses the existing OpenRouter LLM.

How

  • weekly.py (new): pure select_recent_daily (most recent 7 YYYY-MM-DD.md, newest first, ignores non-daily files), parse_blocks, build_review_input (groups notes by day for the prompt). week_command feeds the day-grouped notes to the LLM for a Themes / Action items / Highlights review; falls back to per-day counts if the LLM call fails. Summary runs off the event loop via asyncio.to_thread.
  • drive_handler.py: adds list_markdown_files and read_file (read-only).
  • bot.py: registers /week, adds to help/start text.

Test

  • tests/test_weekly.py: file selection (filter/sort/cap/empty), block parsing, prompt grouping. Full suite green (17 passed).

New weekly.py command (auth-gated). Selects the most recent 7 daily
Drive files, groups their captured notes by day, and asks the LLM
(reusing scheduler.create_llm) for a themed review (themes / action
items / highlights). Falls back to per-day counts if the LLM is
unavailable. File selection + parsing are pure functions. Closes #16.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Weekly Review: /week command

1 participant