Как я устранил проблему с электронной почтой в малом бизнесе за 120 долларов – спасибо ChatGPT Plus и Claude
- ChatGPT Plus может справиться с этой задачей, но не смог ее реализовать.
- Ключевым моментом является обращение к другому ИИ для проверки работы вашего ИИ.
- Ответы на электронные письма клиентов не обязательно должны быть утомительными.
Это история успешной автоматизации ответов на электронные письма в службу поддержки клиентов небольшой компании, занимающейся электронной коммерцией. Это также история процесса, в ходе которого я постепенно терял перспективу и всерьез подумывал о том, чтобы задушить ChatGPT.
Все началось с того, что в компании моей жены, занимающейся электронной коммерцией, было слишком много электронной почты для обслуживания клиентов. Кроме того, я пишу колонку об искусственном интеллекте.
Ее компания, занимающаяся электронной коммерцией, продает цифровые товары для популярного хобби. Большинство писем в службу поддержки, которые она получает, - это просьбы о помощи в загрузке их продуктов, о проблемах с паролями и логином, а иногда и просьбы об использовании самих продуктов.
Также: Как использовать ChatGPT в работе – и мои 10 лучших советов по началу работы с agentic AI
Примерно половина этих запросов может быть обработана с помощью шаблонных ответов. Именно так моя жена отвечала на большинство своих электронных запросов все это время. Она создала несколько шаблонов TextExpander, которых было достаточно для многих законных запросов.
Лишь небольшая часть (около 1-2%) входящих электронных писем, которые она получает, связана с реальными запросами клиентов. Остальное - это различные виды спама, рекламные акции PayPal и огромное количество новостных рассылок, почти ни на одну из которых она на самом деле не подписана.
Все это приходит на адрес электронной почты компании, так что все это не связано с ее личной перепиской. Это большая удача, потому что я смог поработать над автоматизацией работы компании, не подвергая риску ее личную электронную почту.
ИИ должен выполнять два основных рабочих процесса: идентифицировать и разделять входящие электронные письма, а затем обрабатывать поток электронной почты таким образом, чтобы после идентификации каждое сообщение могло быть обработано надлежащим образом.
К сожалению, разнообразие электронной почты было таким, что фильтров Gmail было недостаточно. Они не смогли разобраться в тонкостях, например, в том, как отличить рекламное электронное письмо PayPal от того, в котором ей нужно было немедленно ответить на жалобу клиента. Такого рода дифференциация - это то, в чем AI очень хорошо разбираются.
Я занимаюсь процедурным (или детерминированным) программированием на протяжении десятилетий. Это тот вид программирования, в котором один шаг следует за другим. Как программист, я определяю шаги и условия для выполнения действий. Это первый раз, когда я создаю программу, в которой рабочий процесс сам выбирает свой собственный план действий.
Также: Как я использовал ChatGPT, чтобы разобраться с ремонтом поврежденного игрового ПК – буквально
Отправной точкой стал поиск способа обрабатывать входящие электронные письма в службу поддержки клиентов. Я был полон решимости выяснить, смогу ли я получить ее тарифный план ChatGPT Plus стоимостью 20 долларов в месяц, чтобы управлять всем этим. На самом деле, именно это она и делает.
Attempt #1: The one with the spreadsheetMy biggest and most time-consuming mistake was letting ChatGPT design and architect the solution, and then trusting for almost four weeks that it actually knew what it was doing.
But its design seemed really solid and credible. By the time this phase was over, I felt like a homeowner who hires a contractor who provides really solid plans and asks for half of the payment upfront, only to discover that the contractor has no idea how to deliver real work from those beautiful plans.
ChatGPT designed a multi-tier orchestration system around a shared Google spreadsheet. The tiers included:
- Program control and intake
- Classification
- Order/payment analysis
- Support triage
- Spam safety
- Gmail execution
- Final mapping, response selection, and verification
- Scheduling and checkpoints
The idea is that every message (using the message’s unique ID) would go through one or more of these phases, until the message was either responded to and filed, or just filed. My wife already had a very carefully curated label system for email message filing. The AI was trained to file into that system. Anything that couldn’t be handled by the AI would be placed into a "Human Attention Required" folder for my wife to handle personally.
Also: 5 ways I actually use ChatGPT Work in my small business to save time and money
Initially, the AI collected 240 messages from the backlogged inbox. This was a representative sampling of the types of messages that came into the support inbox. From this, we developed an organizing structure that accounted for most mail types: customer mail, orders, payments, vendors, security notices, newsletters, solicitations, and spam.
Then we went through what seemed like a never-ending cycle where the AI attempted to identify classification characteristics, created a spreadsheet where I rated the AI’s classification of each email, and then the AI adjusted its understanding based on my validations.
Once the AI understood the focus of each email, it needed to map the various message types to the desired action. These actions included reply and file, file without replying, move to the Human Attention Required folder, treat as spam, or (at least for the first few weeks) some bonkers AI-demented characterization that had nothing to do with anything in the known universe.
We went over and over the unfamiliar and edge-case messages until the AI finally developed a good understanding of the customer service email that came in each week.
The AI set up separate ChatGPT conversations for each stage, and constantly asked me to copy and paste instructions between the conversations. The idea was that one conversation would classify the emails. One would determine if any were orders or payment-related emails. One would properly categorize support emails. One would construct replies, and so on.
Also: Use ChatGPT Plus? Switching to Gemini could cut your bill – by $144 a year for me
But ChatGPT can’t invoke various conversations as services, yet that was the architecture we were building. The AI assigned procedural names to each of the conversations, regularly calling them components, and insisting it could treat those conversations as real software components.
This was the first time I ever tried to build this sort of system with AI, so I went along for the ride.
Until I lost patience. That brought me to the second failed attempt.
Attempt #2: The first one with a skillI finally reached the end of my patience and confronted ChatGPT. It continued to insist that the process we were hammering away on would work. But I’ve worked with contract programmers before, and there’s a kind of static in the air when they’re blowing smoke up your assignment.
ChatGPT was no different, although it was a bit more obsequious and acted a bit more willing to help than most contractors I’ve sparred with.
Eventually, I convinced it that the multiple conversation sessions weren’t working and there had to be a better way. I asked it, "What about turning this all into a skill?" ChatGPT thought this was a grand idea.
So it proceeded to scan the spreadsheet, which by this time had become a 73-tab monster. From that, it constructed a skill with a 12-stage processing pipeline, formal rules, checkpoints, verification procedures, and mechanisms intended to prevent duplicate processing or lost messages. The multi-tier conversation sessions became that 12-stage multi-tier pipeline in the ChatGPT skill.
Test runs apparently worked. The AI ran 59 unit tests and 139 regression tests to ensure the process was reliable. It reported zero mismatches. But there were gotchas. Oh, my there were gotchas.
Also: I let ChatGPT Work and Claude Cowork loose on my files – only one made me nervous
First, even after all those tests, the system didn’t actually work. It turns out the tests validated rules running internal to the model and simulated outcomes. It didn’t actually test unattended email processing.
The schedule automations failed. They were unable to coordinate the pipeline stages, processed no actual Gmail changes, and then stopped, without any mechanism to recover and continue.
The second attempt, during which I tried to turn the overly complicated email-management system into a reliable autonomous service, merely added more complexity without fixing the underlying problem, which was that it just couldn’t execute the pipeline reliably.
Attempt #3: The one where I brought Claude in to consultI’ve found that Claude provides an excellent orchestration layer for other AIs. I’ve used it to build a series of AI systems running on my local Mac Studio home lab system. I’ll probably talk more about that in a future article. In any case, having been very successful in having Claude review and instruct another AI, I decided to set it loose on my ChatGPT woes.
The first thing I did was have ChatGPT build a complete dossier on its actions, for delivery to Claude. Claude was not amused. It described ChatGPT’s work as, "A failed bank-grade architecture for a hobby-download site which contradicted David’s requirements and resulted in excess complexity without value."
I mean, have you ever seen any contractor approve of another contractor’s work? Whether it’s coding or plumbing, if someone else did it, it’s crap. But Claude did have a point. ChatGPT’s plan was ineffective and wildly too complex.
My goal was still to run the system through my wife’s $20/mo ChatGPT Plus account, but I decided to use my $100/mo Claude Max account to develop the skill and operations that would then be deployed to my wife’s e-commerce service accounts. This worked out really well.
First, Claude discarded most of the learnings in the spreadsheet. Instead, it took a much more interesting approach. Claude asked me to go to the support account’s Google Takeout, and export the entire email history. It then read in that export. From all that email history, it derived rules about the kinds of emails the account received and how they were responded to.
Also: Claude Code vs. Codex: Why I use both and how to choose one (if you must)
The export was a 5.24GB file containing 88,777 messages, including a history of 40,580 sent messages.
This was a support account, so I wasn’t too concerned about sharing its entire history with Claude. I would not have been comfortable doing this with a personal account or one with critical business data. That said, rather than having to go through weeks of test attempts and corrections, Claude learned the entire support history of my wife’s e-commerce operation in less than an hour, during which time I had lunch.
Claude then went through and figured out how messages were filed. Since this was a critical (and quite time-consuming) part of the workflow, this mapping was essential. It identified most of the key customer support questions, and how they were answered, so that we could work off a series of templates. Likewise, it identified what were business pitches, spam, and other types of messages that could either be filed or discarded.
All of this went into a Google Doc called the "Mail Bot Rulebook." We’ll come back to that in a few minutes.
Claude built the workflowThen, Claude started working on establishing a workflow.
The first thing it did was test what kept going wrong with the ChatGPT workflow. The key failing was that ChatGPT could not reliably send Gmail messages. Most best practices recommend leaving emails in the Drafts email box, so a human can review and send them out.
But a big part of this project was to ensure customers were responded to autonomously, which meant the AI had to be able to send email.
Claude suggested breaking this into two clear components: a scheduled ChatGPT event and a scheduled Google Apps script. The first is non-deterministic. The second is procedural.
ChatGPT has a timed event where, once a day, it reads the rulebook and processes the day’s incoming messages. Those it can file, it does. If there are messages that need a response, the rulebook guides the AI on whether the email is dropped into the "Human Attention Required" or whether a response message should be drafted using one of the ten pre-built response templates.
Also: I gave Claude Cowork 7 non-coding jobs, and it earned a spot in my toolbox
If an incoming request merits a template response, ChatGPT creates a draft response and places it in the Gmail Drafts folder. The original customer inquiry remains untouched and stays in Gmail’s inbox.
Then, once an hour, a script built in Google Apps Script is triggered by Google Apps Script, completely outside of ChatGPT. It looks at the messages in the Drafts folder, and qualifies them based on a set of clear criteria:
- It will send email messages signed with the AI support rep’s assigned name, or ones with a very specific key phrase indicating the email message is urgent and critical. That second type of message is sent directly to my wife. Critical system problems and any payment processing service issues qualify.
- The script will only send drafts that are at least 10 minutes old and will send no more than 10 drafts per run.
- After each draft is sent, it confirms that draft is in Sent Items, then assigns the original incoming email an Inquiries label and removes it from the Inbox. Anything it can’t confirm has been sent is left in the Inbox. So far, the only things that get hung up in the Inbox are Google’s own security alerts, which Gmail won’t allow either Apps Script or ChatGPT to touch.
Over the first two weeks, the rulebook was revised 15 times with minor tweaks. At this point, the system has been running reliably for a while.
Claude retains knowledge of its actions but is no longer actively involved in the project, which now is a reliable, hands-off, unattended ChatGPT and Apps Script workflow.
The numbers justify the systemBefore this, every time my wife opened the customer support email, she was faced with a wall of garbage. We tested one backlog to come up with some stats. Of the 1,689 messages in that backlog, there were only 25 messages from real customers. That’s roughly 1.5% of the incoming email during a given session.
Of those 25, about half could be answered automatically. Only half really need human attention. We could have actually increased those template responses more, but my wife likes to see the "look what I did" and "I love your product" types of messages, so the AI was configured to avoid responding to those automatically.
That leaves her with 11 messages of the 1,689 session messages that actually need her response. Not only is that a substantial workload reduction, it’s also an enormous cognitive load and stress reduction as well.
Where before, every look at the session’s incoming email required a gut check and burned willpower, checking customer support email is now something my wife looks forward to.
Here’s the analogy that fully describes the results of this project. Imagine the mail room of a large company. Initially, the company’s chief product expert had to sift through every email coming into the company for the few needing subject matter expertise. Now, those few emails are delivered right to the chief product expert’s desk, so her time can be better spent building business value (and all the other amazing things my wife does every day).
If you decide to undertake a project like this, I recommend these six considerations:
- Make the project as small and limited as possible.
- Try to avoid doing anything that’s mission critical.
- Expect it to go longer and be more of a pain than you could possibly imagine.
- Don’t hesitate to get one AI to evaluate another AI’s plans.
- Keep in mind that AIs have a hard time with procedural workflows.
- Limit the AI’s access to email and company systems, and definitely don’t let the AI into your personal email or business confidential services. You have no idea what it might decide to try to send.
I have to say that building this system was a slog. I did not enjoy it. But the resulting value of her little $20/month ChatGPT Plus plan applied to this solution is almost incalculable.
This is where AI shines. We don’t have a team of customer support reps who the AI is putting out of business. My wife is the sole operator of her business. So the AI didn’t put anyone out of work. Instead, it freed her up and increased the quality of service provided to customers. Already, we’ve had a number of "Thank you, that helped," emails back from customers who received timely and helpful responses from the AI.
And yeah, I recognize that "Thank you, that helped" messages are still incoming email messages. Those are the sorts of messages you want to see every morning.
Good luck. If you have tried or are trying something like this, let us know how it went in the comments below.
You can follow my day-to-day project updates on social media. Be sure to subscribe to my weekly update newsletter, and follow me on Twitter/X at @DavidGewirtz, on Facebook at Facebook.com/DavidGewirtz, on Instagram at Instagram.com/DavidGewirtz, on Bluesky at @DavidGewirtz.com, and on YouTube at YouTube.com/DavidGewirtzTV.
>
