Files
Yanxin Lu 36143fcd93 Add digest command to email processor
Read-only summary of recent decisions, grouped by action with
[auto]/[user] markers. Supports --recent N for multi-day lookback.
2026-03-13 11:17:43 -07:00

24 lines
1.1 KiB
Bash
Executable File

#!/usr/bin/env bash
# email-processor — wrapper script for the email processor.
#
# Usage:
# ./email-processor.sh scan # classify unseen emails
# ./email-processor.sh scan --recent 30 # last 30 days
# ./email-processor.sh scan --dry-run # classify only, no changes
# ./email-processor.sh scan --recent 7 --dry-run # combine both
# ./email-processor.sh review list # show pending queue
# ./email-processor.sh review 93 delete # act on envelope 93
# ./email-processor.sh review all delete # act on all pending
# ./email-processor.sh review accept # accept all suggestions
# ./email-processor.sh stats # show history stats
# ./email-processor.sh digest # today's processed emails
# ./email-processor.sh digest --recent 3 # last 3 days
#
# Requires: uv, himalaya, Ollama running with model.
set -euo pipefail
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
exec uv run --project "$SCRIPT_DIR" python "$SCRIPT_DIR/main.py" "$@"