Each new email gets a reply drafted in your voice and filed under the original message in Gmail, with blanks where a fact is missing.

UsesClaudeGmail

Draft a reply to every new email in your voice

GmailGmailWhen an email arrives. Save it as email.When an email arrives. Save it as email.
ValuesSet aboutMe to blank.Set aboutMe to blank.
ValuesSet signOffName to blank.Set signOffName to blank.
ValuesSet deliveryMode to draft.Set deliveryMode to draft.
ValuesSet skipSenderPatterns to [noreply, no-reply, donotreply, do-not-reply, mailer-daemon, postmaster@, notifications@, bounce].Set skipSenderPatterns to [noreply, no-reply, donotreply, do-not-reply, mailer-daemon, postmaster@, notifications@, bounce].
ValuesSet skipSubjectPatterns to [out of office, automatic reply, auto-reply, autoreply, undeliverable, delivery status notification, read receipt].Set skipSubjectPatterns to [out of office, automatic reply, auto-reply, autoreply, undeliverable, delivery status notification, read receipt].
ValuesSet skipBodyPatterns to [unsubscribe, view this email in your browser, you are receiving this email because].Set skipBodyPatterns to [unsubscribe, view this email in your browser, you are receiving this email because].
ValuesSet minBodyChars to 20.Set minBodyChars to 20.
ValuesSet maxBodyChars to 6000.Set maxBodyChars to 6000.
ValuesSet fromHeader to email.from.Set fromHeader to email.from.
ValuesSet subjectHeader to email.subject.Set subjectHeader to email.subject.
ValuesSet bodyHeader to email.body.Set bodyHeader to email.body.
ValuesSet dateHeader to email.date.Set dateHeader to email.date.
Decisions & LoopsIf fromHeader is empty or subjectHeader is empty or bodyHeader is empty or…If fromHeader is empty or subjectHeader is empty or bodyHeader is empty or…
Yes
ValuesShow in the output: No email to work from. This workflow runs by itself when a new email arrives in Gmail: connect Gmail, turn the workflow on, and the next message that lands gets a drafted reply. Running it by hand has nothing to read..Show in the output: No email to work from. This workflow runs by itself when a new email arrives in Gmail: connect Gmail, turn the workflow on, and the next message that lands gets a drafted reply. Running it by hand has nothing to read..
Decisions & LoopsFinish the run.Finish the run.
No
No steps
TextExtract the first email address from fromHeader and save it as sender.Extract the first email address from fromHeader and save it as sender.
TextTrim subjectHeader and save it as subject.Trim subjectHeader and save it as subject.
TextTrim bodyHeader and save it as bodyText.Trim bodyHeader and save it as bodyText.
ValuesSet skipReason to blank.Set skipReason to blank.
Decisions & LoopsIf sender is blankIf sender is blank
Yes
ValuesChange skipReason to its From line carries no address a reply could go to.Change skipReason to its From line carries no address a reply could go to.
No
No steps
Decisions & LoopsIf skipReason is blankIf skipReason is blank
Yes
Decisions & LoopsFor each pattern in skipSenderPatterns:For each pattern in skipSenderPatterns:
Decisions & Loops If sender contains pattern (ignoring case) If sender contains pattern (ignoring case)
Yes
TextBuild the text it came from an unattended address (@sender) and save it as skipReason.Build the text it came from an unattended address (@sender) and save it as skipReason.
Decisions & LoopsStop repeating.Stop repeating.
No
No steps
No
No steps
Decisions & LoopsIf skipReason is blankIf skipReason is blank
Yes
Decisions & LoopsFor each pattern in skipSubjectPatterns:For each pattern in skipSubjectPatterns:
Decisions & Loops If subject contains pattern (ignoring case) If subject contains pattern (ignoring case)
Yes
TextBuild the text it is itself an automatic message (the subject says @pattern) and save it as skipReason.Build the text it is itself an automatic message (the subject says @pattern) and save it as skipReason.
Decisions & LoopsStop repeating.Stop repeating.
No
No steps
No
No steps
Decisions & LoopsIf skipReason is blankIf skipReason is blank
Yes
Decisions & LoopsFor each pattern in skipBodyPatterns:For each pattern in skipBodyPatterns:
Decisions & Loops If bodyText contains pattern (ignoring case) If bodyText contains pattern (ignoring case)
Yes
TextBuild the text it reads as bulk mail (the body says @pattern) and save it as skipReason.Build the text it reads as bulk mail (the body says @pattern) and save it as skipReason.
Decisions & LoopsStop repeating.Stop repeating.
No
No steps
No
No steps
Decisions & LoopsIf skipReason is blank and the length of bodyText is less than minBodyCharsIf skipReason is blank and the length of bodyText is less than minBodyChars
Yes
ValuesChange skipReason to there is too little text in it to reply to.Change skipReason to there is too little text in it to reply to.
No
No steps
Decisions & LoopsIf skipReason isn't blankIf skipReason isn't blank
Yes
ValuesShow in the output: No draft written for @subject: skipReason.Show in the output: No draft written for @subject: skipReason.
Decisions & LoopsFinish the run.Finish the run.
No
No steps
TextShorten bodyText to maxBodyChars characters (keeping words whole) and save it as emailForModel.Shorten bodyText to maxBodyChars characters (keeping words whole) and save it as emailForModel.
AI AgentRun an AI agent: Decide whether this email needs a reply and, if it does, draft it. THE EMAIL THEY RECEIVE… and save it as drafted.Run an AI agent: Decide whether this email needs a reply and, if it does, draft it. THE EMAIL THEY RECEIVE… and save it as drafted.
Decisions & LoopsIf drafted.output.needs_reply is noIf drafted.output.needs_reply is no
Yes
ValuesShow in the output: Read @subject and judged that it needs no reply, so no draft was written.Show in the output: Read @subject and judged that it needs no reply, so no draft was written.
Decisions & LoopsFinish the run.Finish the run.
Else if @drafted.output.needs_reply is not "yes"
Decisions & LoopsStop and report a problem: No draft was written for @subject from sender: the AI did not say clearly whether it needs a reply (it answered @drafted.output.needs_reply). Answer this email by hand.Stop and report a problem: No draft was written for @subject from sender: the AI did not say clearly whether it needs a reply (it answered @drafted.output.needs_reply). Answer this email by hand.
Otherwise
No steps
TextTrim drafted.output.reply with ** replaced by and save it as reply.Trim drafted.output.reply with ** replaced by and save it as reply.
Decisions & LoopsIf the length of reply is less than 20If the length of reply is less than 20
Yes
Decisions & LoopsStop and report a problem: No draft was written for @subject from sender: the AI said it needs a reply but only wrote @reply, which is too little to be a usable draft. Answer this email by hand.Stop and report a problem: No draft was written for @subject from sender: the AI said it needs a reply but only wrote @reply, which is too little to be a usable draft. Answer this email by hand.
No
No steps
Decisions & LoopsIf deliveryMode in lowercase is sendIf deliveryMode in lowercase is send
Yes
GmailGmailReply to email email.Reply to email email.reply
ValuesShow in the output: Sent a reply to @subject from sender, in the same conversation, unreviewed, because deliveryMode is send.Show in the output: Sent a reply to @subject from sender, in the same conversation, unreviewed, because deliveryMode is send.
No
GmailGmailDraft a reply to email email.Draft a reply to email email.reply
ValuesShow in the output: Draft saved in Gmail, under @subject from sender in the same conversation. Read it, edit it, send it.Show in the output: Draft saved in Gmail, under @subject from sender in the same conversation. Read it, edit it, send it.