feature/funnel-automation (the planned overhaul),
with each step flagged live / planned / retired.
English narrative · Hungarian subject lines quoted verbatim · regenerated 2026-06-18 from the other session's plan + Q1–Q13 conflict review.AUTOSEND_ENABLED kill-switch (default OFF) disables every auto-send at once./ghl/event stays a 200 inert stub. The dashboard is now the sole pipeline source of truth.neg_kind ∈ {angry, negative, soft_objection}: angry → drop/log (existing client → task);
clear negative at first touch only → auto one-liner → Lost; soft_objection → AI draft + Negative-Replies card (human). Classifier stays Gemini 2.5 Flash (no model change).clientsflow.hu" rule is reversed: known deal/lead → card; everything else → Notion "Logged" (not a Kanban card). Warmup/Instantly stays invisible.Two orthogonal things are marked on every message: who/what triggers the send and its build status.
The preview-&-arm invariant: no multi-email sequence ever leaves before Matt has seen its full copy + schedule in a stage-entry modal. The 10-no-edit streak only pre-fills the modal as a one-click "Approve & arm" — it never removes the modal or sends silently. A global AUTOSEND_ENABLED (default OFF) gates every auto-send.
feature/funnel-automation plan, not yet deployed
retired deliberately removed (mostly GHL)
[[dormant]] code exists but gated off / unreachable
[[not in backend]] spec-only, not built
handle_missive_incoming): drop warm-up/DMARC/Instantly, calendar RSVPs, out-of-office, internal senders, and Layer-0 automated/bulk mail before any AI call. Our own sent mail (_is_ours) still drops. Wise transfer → payment touchpoint.clientsflow.hu inbox now runs the full gate, then routes — known deal / genuine new lead (is_lead, conf ≥ 0.55) → card; everything else → Notion "Logged" (a log view, not a Kanban card). Warmup/Instantly stays invisible. (Reverses the 2026-06-18 "ignore main inbox" rule.)email_type, neg_kind ∈ {angry, negative, soft_objection}, is_lead, is_automated, booking_ok, confidence. Parser defaults neg_kind=soft_objection (safe → human) if absent.seq_*) immediately.Everything below begins at step 3's branch on email_type / neg_kind.
Grouped into families A–H by what the lead's reply was. Shared sub-paths (booking → call → proposal) are abbreviated after the first full listing.
matyas@clientsflow.hu + a "what changed" popup event. GHL conf retiredPAYMENT_PLANS=[50,100] (70% dropped)new_lead_unreachable; the one-active-sequence guard keeps them mutually exclusive.new_lead_unreachable sequence → preview modal shows every email + schedule. plannedNOSHOW_EMAIL_1/2/3_HU, timed immediate / +24h / +4 days, each embedding the signed booking link). Preview modal shows all 3 + schedule. planned — replaces the old 5-step AI loopproposal_due_date. plannedConditions on the arrows; each box shows the subject line (or "in-thread" / transactional) + a short summary. Colours follow the send-mode legend; cyan = armed auto-sequence (preview-&-armed first), dashed purple = dormant.
flowchart TD
subgraph Legend ["ℹ️ LEGEND (Send mode)"]
direction LR
L1["🟢 AUTO-SENT
reminders + first-touch goodbye only"]:::auto
L2["✍️→🟡 DRAFT→APPROVE
hand-authored, per-email"]:::gate
L3["🤖⚡ ARMED SEQUENCE
preview-&-arm modal, then auto"]:::seq
L4["🟡 MANUAL ACTION
no message"]:::man
L5["[DORMANT / RETIRED]"]:::dorm
end
subgraph Triage ["1. Inbound Ingest & Triage"]
START(["📨 Inbound Reply"]):::start
MAIN{"Main inbox?
R3 routing"}:::ai
CLS{"🤖 AI Classifier
(Gemini 2.5 Flash)
neg_kind 3-way"}:::ai
LOG["📝 Notion 'Logged'
(no card)"]:::man
START --> MAIN
MAIN -->|"no deal match"| LOG
MAIN -->|"known deal / new lead"| CLS
end
subgraph Booking ["2. Booking & Nudges (own booking app)"]
FR["✍️→🟡 First Reply
own-booking link"]:::gate
NUDGE["✍️→🟡 Nudge Ladder
Day 2 / 5 / 9 (kept)"]:::gate
UNREACH["🤖⚡ new_lead_unreachable
(armed sequence)"]:::seq
CALLSET["🟡 Manual Scheduler
event + conf email"]:::man
CLS -->|"interested / neutral"| FR
FR -->|"no booking"| NUDGE
FR -->|"rep called, no answer"| UNREACH
FR -->|"rep phoned, agreed time"| CALLSET
end
subgraph Meeting ["3. Meeting & Reminders"]
BOOKED["🟢 Own-booking Conf
page + email to Matt"]:::auto
MEET(["🟢 Meet Invite
'Weboldal Bemutató'"]):::auto
REMIND["🟢 Reminders 24h & 2h
(modal-exempt)"]:::auto
NOSHOW["🤖⚡ No-show Rebook
3 fixed emails (0 / +24h / +4d)"]:::seq
FR -->|"books"| BOOKED
NUDGE -->|"books"| BOOKED
UNREACH -->|"books"| BOOKED
CALLSET --> BOOKED
BOOKED --> MEET --> REMIND
REMIND -->|"attends"| CALL{"🟡 Sales Call"}:::man
REMIND -->|"no-show"| NOSHOW
NOSHOW -->|"rebooks"| BOOKED
end
subgraph Proposal ["4. Proposal & Chasing"]
PROP["✍️→🟡 Proposal Email
'Az ajánlatod' + DocuSeal/Stripe"]:::gate
CHASE["🤖⚡ Proposal Chase
(page-3 authored, armed)"]:::seq
ABANDON["🤖⚡ Abandoned Cart
signed, unpaid"]:::seq
CALL -->|"ready to buy"| PROP
PROP -->|"signs + pays ≤2h"| PREPAY["Stripe Payment"]:::sys
PROP -->|"signed, unpaid"| ABANDON
PROP -->|"sent, unsigned"| CHASE
CHASE -->|"signs"| PREPAY
ABANDON -->|"pays"| PREPAY
end
subgraph Delivery ["5. Onboarding & Delivery"]
ONB["✍️→🟡 Welcome Kit
'Üdv a fedélzeten!'"]:::gate
DEV["🟡 Waiting for Dev
(Dani Slack ping)"]:::man
BAL["✍️→🟡 Balance Due
[NO LIVE COPY]"]:::gate
HANDOVER["Handover Invite
[DORMANT]"]:::dorm
WON([🏆 WON]):::won
PREPAY --> ONB --> DEV
DEV -->|"full prepaid"| HANDOVER
DEV -->|"50% deposit"| BAL
BAL -->|"pays balance"| HANDOVER
HANDOVER --> WON
end
subgraph Negatives ["Negative replies (3-way)"]
ANGRY["🟢 Angry → drop/log
(client → task)"]:::auto
GOODBYE["🟢 First-touch goodbye
one-liner (modal-exempt)"]:::auto
SOFT["✍️→🟡 Soft objection draft
Negative-Replies card"]:::gate
NEGFUP["🤖⚡ Negative-followup
+2-day nudge (armed)"]:::seq
GHOST([👻 Ghosted]):::term
LOST([🪦 Lost — 60d nurture]):::term
REACT["🟢 Reactivation"]:::auto
CLS -->|"angry"| ANGRY
CLS -->|"negative + first touch + conf≥0.80"| GOODBYE
CLS -->|"soft_objection"| SOFT
GOODBYE --> LOST
SOFT -->|"arm follow-up"| NEGFUP
SOFT -->|"reply & mark lost"| LOST
NEGFUP -->|"books"| BOOKED
NEGFUP -->|"1 week silence"| GHOST
GHOST -->|"writes back"| REACT
LOST -->|"writes back"| REACT
REACT --> FR
end
CLS -->|"proposal_followup"| PF["✍️→🟡 Proposal Reply
Q&A, no book link"]:::gate
PF --> PROP
CLS -->|"ongoing client"| ONG["Client Message Task"]:::man
%% GHL retired
GHLX["🔵 GHL booking/stage sync
RETIRED — /ghl/event = inert 200"]:::dorm
classDef start fill:#e8f0fe,stroke:#2563eb,stroke-width:2px,color:#1c2230;
classDef ai fill:#ffffff,stroke:#5c6675,stroke-width:1.5px,color:#1c2230;
classDef auto fill:#e9f7ef,stroke:#1f9d55,color:#13502c;
classDef gate fill:#fdf6e3,stroke:#b7791f,color:#6b4a10;
classDef seq fill:#e0f7fb,stroke:#0e7490,color:#0b4250;
classDef man fill:#eef1f5,stroke:#64748b,color:#33414f;
classDef neg fill:#fdecea,stroke:#c0392b,color:#7d1f15;
classDef term fill:#eef1f5,stroke:#64748b,stroke-dasharray:4 3,color:#33414f;
classDef won fill:#e9f7ef,stroke:#1f9d55,stroke-width:2px,color:#13502c;
classDef dorm fill:#f3ecfa,stroke:#8a4baf,stroke-dasharray:5 3,color:#4d2a66;
classDef sys fill:#e8f0fe,stroke:#2563eb,color:#15336e;
| Message | Subject line (HU) | Source | Send mode | Status |
|---|---|---|---|---|
| Cold email (first touch) | Beszéljünk a weboldaladról, {keresztnév}? | Instantly (read-only) | 🟢 campaign | live |
| First reply | in-thread | AI + FIRST_REPLY_BLOCK_HU (own-booking link) | ✍️→🟡 | live |
| Booking confirmation | page + email to Matt | own booking app (handle_own_booking) | 🟢 | planned (GHL conf retired) |
| Meet invite | Weboldal Bemutató — {név} | MEET_* | 🟢 | planned (GCAL-driven) |
| Reminder 24h | Holnapi megbeszélés | REMINDER_24H_* | 🟢 auto (modal-exempt) | live |
| Reminder 2h | Megbeszélés | REMINDER_* | 🟢 auto (modal-exempt) | planned: 1h→2h, body fixed |
| Proposal email | Az ajánlatod — {cég} weboldal | AI + proposal_followup_email_hu | ✍️→🟡 | live |
| Nudge 1/2/3 | in-thread | NUDGE_INSTR_1/2/3 (Day 2/5/9) | ✍️→🟡 | live (kept as-is) |
| New-lead "couldn't reach" | in-thread | sequence engine | 🤖⚡ armed | planned |
| Proposal chase | in-thread | post-call page-3 editor / templates | 🤖⚡ armed | planned (was cron soft/firm) |
| Abandoned cart | in-thread "Már csak egy lépés 🙌" | ABANDONED_CART_INSTR | 🤖⚡ armed | planned (armed) |
| No-show rebook ×3 | in-thread "Lemaradtunk egymásról?" | NOSHOW_EMAIL_1/2/3_HU (0/+24h/+4d) | 🤖⚡ armed | planned — replaces 5-step AI loop |
| First-touch goodbye | in-thread "Köszönöm a visszajelzést, minden jót…" | NEGATIVE_REPLY_DEFAULT_HU | 🟢 auto (modal-exempt) | planned (first touch only, conf≥0.80) |
| Soft-objection draft | in-thread | AI objection-handling | ✍️→🟡 | planned (neg_kind=soft_objection) |
| Negative +2-day FUP | in-thread "Érdekes lehet a lehetőség?" | NEG_FUP_BODY_HU | 🤖⚡ armed | planned (armed, soft only) |
| Welcome kit / onboarding | Üdv a fedélzeten, {keresztnév}! 🎉 Indulunk | copy:email_welcome_kit | ✍️→🟡 | live |
| Balance due (50/50) | in-thread "Elkészült a weboldalad 🎉…" | BALANCE_DUE_BODY_HU | ✍️→🟡 | live, .md subject differs |
| Contract (megbízási szerződés) | DocuSeal doc | contract-copy.md → build_contract_html | — | planned: 6 sections, 50/50 fee |
| Handover / review request | Foglaljunk… / Hogy tetszik… | copy:email_handover_invite / _review_request | — | authored, not auto-sent |
| GHL booking confirmation + stage sync | GHL template / Workflow #1+#2 | GoHighLevel | 🔵 | retired (inert 200 stub) |
Regenerated from the parallel session's plan change-the-incoming-recursive-map.md (WS1–WS12 + Q1–Q13 conflict review) and LEAD_JOURNEYS.html. Rendering: Mermaid flowchart syntax.