# Hotel Confirmation Investigation — 2026-04-21 ## Problem Hotel confirmation email forwarded by Matt was not added to calendar. ## Root Cause Analysis ### 1. Missing .env Symlink (FIXED) The `.env` file with Gmail credentials was not symlinked to the services directory: - **Before:** No `.env` in `/home/hoffmann_admin/.openclaw/services/family_assistant/` - **After:** Symlinked to `/home/hoffmann_admin/.openclaw/workspace/scripts/.env` ### 2. Appointment Prompt Excluded Travel (FIXED) The appointment extraction prompt (`prompts/appointment_extract.txt`) did not explicitly include travel bookings: - **Before:** "What does NOT count: Delivery/shipping notifications, order confirmations" - **Issue:** Hotel confirmations likely classified as "order confirmations" and filtered out - **After:** Updated to explicitly include "Travel reservations: hotel bookings, flight confirmations, car rentals, train tickets" and clarified "product delivery/shipping" vs travel ### 3. Email Already Processed (LIKELY) The hotel confirmation email was likely already marked as **read** by a previous failed run: - `process --dry-run` shows 0 unread emails - `brain-backfill --days 3` found 3 emails but no hotel confirmation - The pipeline marks emails as read after processing (even on failure) ## Fixes Applied 1. ✅ Created `.env` symlink in services directory 2. ✅ Updated `appointment_extract.txt` prompt to include travel reservations 3. ✅ Clarified exclusion to "product delivery/shipping" (not travel) ## Verification Test the updated prompt: ```bash cd /home/hoffmann_admin/.openclaw/services/family_assistant python3 -c " from family_assistant.appointment_parser import parse_email_with_llm result = parse_email_with_llm( subject='Your Hotel Reservation Confirmation - Marriott', body='Reservation confirmed for Matthew Hoffmann. Check-in: April 25, 2026 at 3:00 PM. Check-out: April 27, 2026 at 11:00 AM. Hotel: Marriott Downtown Green Bay. Confirmation: ABC123.', from_addr='reservations@marriott.com' ) print(result) " ``` ## Next Steps 1. **For this hotel booking:** Manually add to calendar or forward the email again (mark as unread in Gmail first) 2. **Going forward:** Travel confirmations will be properly extracted 3. **Monitor:** Next hotel/flight confirmation should auto-process ## Prevention - Consider adding a "reprocess" command to handle emails that were incorrectly filtered - Add logging to track which emails were filtered and why - Consider a web UI for manually adding events when auto-extraction fails