Gå til indhold
Chat→ColleagueArbejd med migKontaktLær
cleverest
Tilbage til alle artikler

How to create an AI email assistant that drafts replies in your voice

Overview

This guide demonstrates building an automated email assistant using Google Workspace Studio that drafts replies matching your communication style and flags urgent messages.

Requirements

  • Google Workspace Studio access (studio.google.com)
  • Gmail account connected to Workspace
  • Personal email writing style guide
  • Google Chat enabled for notifications

Workflow steps

The system follows this sequence:

  1. Trigger: New email arrives
  2. Decision 1: Assess whether response is needed
  3. Drafting: AI generates reply using your style parameters
  4. Storage: Draft saved in Gmail thread
  5. Decision 2: Evaluate urgency level
  6. Notification: Send Chat alert for time-sensitive messages

Setup instructions

Creating the flow

Start by accessing Google Workspace Studio and selecting "New flow." Name your automation (e.g., "Email Assistant").

Choose "When I get an email" as your trigger. You can filter specific inboxes or keywords like "meeting" or "call" if managing multiple email addresses.

Decision logic

Add a "Decide" step asking whether emails require responses. The guide suggests this prompt:

"Does this email include an action item? This includes direct questions, deliverable requests, or approval needs. Exclude notifications, calendar invites, newsletters, marketing emails, and receipts."

Always add the email body as a variable so the system has content context.

Draft generation

Under the "Yes" branch, select "Ask Gemini." Include your writing style guide along with sender name, subject line, and email body variables in the prompt.

Add a substep to "Draft a reply," connecting the Gemini output to your Gmail inbox using the Email ID variable.

Urgency alerts

Create another decision step evaluating time sensitivity. The suggested prompt checks: "Does this express high urgency or request same-day/ASAP responses?"

If urgent, add "Notify me in chat" with the sender name, subject, and message content.

Activation

Select "Turn on" to activate the workflow, or use "Test run" to validate against recent emails first.

Continuous improvement

Collect examples of edited drafts and emails you wrote independently that represent your ideal style. After gathering 3-5 samples, Claude Code can analyze patterns in your corrections and suggest refinements to the writing instructions.

Store before/after versions and exemplars in a dedicated folder, then use Claude Code to identify systematic changes and update your style guidelines accordingly. Copy refined instructions back into the Gemini step.

Monitoring

Access "My flows" in Google Workspace Studio, then select "Activity" to review execution logs. Periodically verify decision accuracy and refine prompts as needed.