$npx -y skills add mgonto/executive-assistant-skills --skill email-draftingDraft email replies for Gonto's Gmail accounts (m@gon.to, gonto@hypergrowthpartners.com). Handles intro acceptances, scheduling intent, thanks/ack, and positive short replies. Use when user asks to draft or reply to an email, or when Gmail webhook triggers arrive for auto-draft c
| 1 | # Email Drafting Skill |
| 2 | |
| 3 | ## Config — read before starting |
| 4 | Read `../config/user.json` (resolves to `~/executive-assistant-skills/config/user.json`). |
| 5 | Extract and use throughout: |
| 6 | - `primary_email`, `work_email` — Gmail accounts |
| 7 | - `scheduling_cc` — scheduling assistant email (CC on all scheduling emails, mention in body) |
| 8 | - `scheduling_silent_cc` — silent CC for scheduling visibility (do NOT mention in email body) |
| 9 | - `signature` — sign-off for all drafts (e.g. "--gonto") |
| 10 | - `name` — short name for context |
| 11 | |
| 12 | Do not proceed until you have these values. |
| 13 | |
| 14 | ## Debug Logging (MANDATORY) |
| 15 | Read `../config/DEBUG_LOGGING.md` for the full convention. Use `python3 {user.workspace}/scripts/skill_log.py email-drafting <level> "<message>" ['<details>']` at every key step. Log BEFORE and AFTER every external call (gog gmail, mcporter, todoist-cli). On any error, log the full command and stderr before continuing. |
| 16 | |
| 17 | ## Overview |
| 18 | Auto-draft and manually-requested email drafts for {user.primary_email} and {user.work_email}. |
| 19 | |
| 20 | ## When to Use |
| 21 | - Gmail hook detects a trigger (intro, scheduling, thanks/ack, positive reply) |
| 22 | - User asks to draft/reply/send an email |
| 23 | - Action items cron identifies email follow-ups needed |
| 24 | |
| 25 | ## Architecture |
| 26 | - Detects triggers and creates Gmail drafts |
| 27 | - Handles all scheduling (slot-finding, conflict checking, calendar ops) |
| 28 | - NEVER proposes specific dates/times or creates calendar events |
| 29 | |
| 30 | ## Execution |
| 31 | - **"Reply" always means Reply All** — include all original To + CC recipients. Only exclude if user explicitly says to reply to one person. Exception: intro handling moves the introducer to BCC per the intro sequence below. |
| 32 | - **After sending any email/draft**, check if it fulfills an open Todoist task (send deck, intro, follow-up, etc.). If yes → complete the task immediately and confirm. |
| 33 | - **Hook/cron triggers**: Always run via isolated sub-agent (prevents memory/context contamination) |
| 34 | - **Direct user requests** ("draft a reply to X"): Main agent may execute directly, but must still follow all style rules and must NOT read MEMORY.md or daily memory files |
| 35 | |
| 36 | ## Rules (non-negotiable) |
| 37 | |
| 38 | ### Core |
| 39 | 1. **Draft-only mode** — never send automatically |
| 40 | 2. **Mirror inbound language** — match the language of the most recent non-automated message in the thread. If the thread has mixed languages, default to the language of the message you're replying to. |
| 41 | 3. **Always sign** — end every draft with `{user.signature}` |
| 42 | 4. **Low confidence** — don't draft; ask user for guidance |
| 43 | 5. **No dash punctuation** — no em-dash/en-dash in bodies. Use commas/periods. |
| 44 | 6. **Humanize** — before finalizing any draft, review it against `~/executive-assistant-skills/humanizer/SKILL.md`. Remove AI-writing markers: inflated symbolism, promotional tone, em-dash overuse, "delve"/"leverage"/"foster" vocabulary, rule-of-three patterns. Email-specific rules (no dashes, signature, brevity) take precedence over humanizer suggestions if they conflict. |
| 45 | |
| 46 | ### Intro Handling (required sequence) |
| 47 | 1. Thank introducer first |
| 48 | 2. Move introducer to BCC |
| 49 | 3. Reply to introduced contact directly |
| 50 | 4. CC `{user.scheduling_cc}` and `{user.scheduling_silent_cc}` for scheduling |
| 51 | 5. Include one line like: "Connecting {user.scheduling_cc_name} to find a time." |
| 52 | 6. **Do NOT mention `{user.scheduling_silent_cc}` in the email body** — silent CC only |
| 53 | |
| 54 | ### Scheduling Drafts |
| 55 | - **ALWAYS CC {user.scheduling_cc} AND {user.scheduling_silent_cc}** |
| 56 | - **NEVER propose specific dates or times** |
| 57 | - Just confirm willingness to meet + mention scheduling assistant will coordinate |
| 58 | - Example: "Connecting Alfred to find a time that works" |
| 59 | - **Do NOT mention {user.scheduling_silent_cc} in the email body** — she's CC'd silently for visibility |
| 60 | |
| 61 | ### Allowed Auto-Draft Classes |
| 62 | - Thanks/ack |
| 63 | - Scheduling intent |
| 64 | - Positive short replies |
| 65 | - Intro acceptance |
| 66 | |
| 67 | ### Notification Format |
| 68 | - `account + one-line intent + draft link` |
| 69 | - Example: `📧 Draft ({user.primary_email} → John): intro acceptance. https://mail.google.com/...` |
| 70 | |
| 71 | ## Draft Links |
| 72 | After creating a draft via `gog`, extract the draft ID from the response. |
| 73 | Gmail draft URL format: `https://mail.google.com/mail/u/?authuser={account_email}#drafts?compose={message_id}` |
| 74 | Use `authuser=m@gon.to` or `authuser=gonto@hypergrowthpartners.com` as appropriate. |
| 75 | |
| 76 | ## Trigger Detection |
| 77 | |
| 78 | ### A) Intro |
| 79 | - Cues: `intro`, `introduction`, `meet`, `connecting you`, `looping in`, `cc'ing` |
| 80 | - At least 2 external participants + clear handoff language |
| 81 | - Apply intro sequence exactly |
| 82 | |
| 83 | ### B) Scheduling Intent |
| 84 | - Cues: `find a time`, `schedule`, `availability`, `next week`, `calendar` |
| 85 | - Spanish cues: `agendar`, `agenda una`, `tenés un |