Spaces:
Sleeping
Sleeping
Commit History
-
Closed-loop feedback: recipients reply, system digests, recap surfaces
Piers Lyon +1: Claude Opus 4.7 (1M context)Adds a feedback round-trip so each weekly digest learns from the recipient's reply to the previous one. Capture - Every lead in the email gets a stable feedback token (lead-<company-slug>-<isoYYYYwWW>) printed as a small grey tag next to the company name. - A "Help us tune this — just reply" footer is appended to every email body, telling recipients they can either quote a lead token ("lead-bentley-motors-2026w19 — already knew") or write naturally ("more food manufacturing", "loved the FDE theme"). - Reply-To remains the existing ADMIN_EMAIL convention; no recipient workflow change required. Ingest (feedback_ingest.py) - Polls the mailbox via the SAME Microsoft Graph app registration used for sendMail. Requires Mail.Read permission to be granted on the app — fails cleanly with a 403 in logs otherwise (digest still ships, recap section just renders empty). - Mailbox priority: FEEDBACK_INBOX > MS_GRAPH_REPLY_TO > ADMIN_EMAIL > MS_GRAPH_FROM_EMAIL. - For each new re…3395614