Do you know what a ghostwriter is? Someone who writes for another person. The word usually comes up around the autobiographies of famous people. Did that person really have time to write 800 pages about themselves? Or did somebody else do it for them? We don’t know the answer to that one. What we do know is how you can train an AI to be your own ghostwriter. Maybe not for the autobiography yet. We’ll start with something simpler – answering email in your own voice.
Today you’ll build a skill that reads a message from your inbox, picks up a saved profile of your writing, drafts a reply and leaves it in Gmail drafts. It won’t send it – at least not at first. Letting the AI send on its own is something you can switch on later, once you’re confident that what it writes no longer needs fixing.
Write a skill that drafts your replies
We covered writing your first skill using a morning plan as the example – go back there for the basics. You’ll create today’s skill much the same way: you tell Claude Code what to do and it writes the file. The difference is that this one has more to it, both in how it is put together and in what it does.
We suggest calling the skill writer, but that’s only a suggestion – the name becomes your command, so pick something you’ll enjoy typing, and remember you can always change it later. This lesson sticks with writer.
The writer will consist of two files. The first is the skill itself – the instruction saying what to do, step by step. The second, writing-style.md, is the material: a description of how you write. It goes into the references subdirectory, the usual name for the folder where a skill keeps material to be read when needed.
We split this into two files because there may be more than one style over time – one for clients, another for colleagues – and the writer should load only the one it needs at that moment.
Here is the prompt that creates the skill:
Save a global skill named writer. Run it also when I ask you to draft a reply to an email.
Before you save the skill, show me its contents and wait for my "ok".
The skill works like this:
1. Before writing a reply, read the file references/writing-style.md from this skill's directory.
2. Save the finished reply as a draft in Gmail. Never send it.
If writing-style.md does not exist yet, the skill writes no reply. Instead it reads my recent sent messages in Gmail and tries to learn my writing style from them. It skips automated notifications and messages that only contain someone else's pasted text, and it separates recurring traits from one-offs. Then it shows me what it has learned, waits for my corrections and only after those saves the file writing-style.md.
Claude Code will show you the skill for approval. Read it once and check that everything is there. If it is, write “ok”.
One skill, two files
Here’s what you now have:
writer/
├── SKILL.md
└── references/
└── writing-style.md
For now only SKILL.md exists. The second file arrives in a moment, the first time you run the skill.
Loading happens in three stages. At the start of a conversation Claude Code knows only the skill’s description – enough to recognise when it might help. Once you type /writer, it reads the instruction from SKILL.md. It reaches for the style file last of all, right before writing the reply.
The same arrangement pays off in any later skill where the procedure is short and the material behind it is long – contract templates, say, or your returns policy.
Teach the writer your voice from your own inbox
Before you run the skill for the first time, open a new conversation. Only then does Claude Code load the skill you have just saved. It also won’t remember the conversation in which you built it, so you’ll see straight away what really works in the file.
That first run isn’t for writing a reply yet. First the writer has to find out how you write.
You already have the material: your sent messages. You don’t copy anything anywhere or collect it into a separate file – Claude Code reads them straight from your mailbox through the Gmail connector. Write:
Read my recent sent messages in Gmail and learn my writing style from them.
A sensible sample is twenty-odd messages, ideally to different people. Automated notifications and messages that are nothing but someone else’s pasted text get skipped – that’s in the skill’s instruction, because there’s nothing about your voice to be found in them.
The writer picks up the traits that come through consistently: how long your sentences and paragraphs run, how formal you are, whether you open with a greeting at all, how you sign off, your signature, your punctuation, emoji, how you address people, and the phrases that keep coming back. It notes separately what you almost never do, and it separates recurring traits from one-offs – a single “Kind regards” from six months ago is not your style.
At this step Claude Code reads dozens of real messages from your mailbox, including what other people wrote to you. What that means for the data leaving your machine, and what you can do about it, we take apart in a separate tip.
Read your profile before the writer saves it
Once it has read your messages, the writer doesn’t save the file yet. First it tells you in plain words what it has learned – roughly like this:
“You write short paragraphs, usually with no greeting. You don’t use emoji. You sign off with ‘Thanks’ and your first name.”
Go through that list and answer in an ordinary sentence. For example:
That's all correct, except don't record that I always capitalise job titles. From now on I want them lower case. And add that I open with "Hello" to clients, never to the team.
Only after those corrections does the file writing-style.md come into existence.
This review is the most important moment of the lesson. Your mailbox shows how you have written until now, including everything about it you don’t much like. How the AI writes from here on is your call.
If the writer spots two clearly different ways of writing in your mailbox, you can ask it to split the profile – one for clients, say, and one for colleagues. Add a line to the skill’s instruction telling the AI how to tell which style to use. In our workshops two styles usually emerge: formal and relaxed.
Block sending before you start testing
“Never send it” in the skill’s instruction is a request, and the writer honours it. But the Gmail connector also has tools that really do send messages, so it’s worth putting a second layer next to the request – one that doesn’t depend on goodwill.
In your browser, go to Customize → Connectors, click the connected Gmail and find the Tool permissions section. Set Blocked on the tools that send messages, reply to them or forward them on. Leave the draft-creating tool available – without it the writer has nothing to save the reply with.
Connector tool permissions are covered in more detail in the lesson on connecting Gmail and Calendar.
The difference is practical: an instruction can be overridden by one careless sentence in a conversation, while a blocked tool simply won’t run. The line at the draft is one you draw yourself – it isn’t a limit on what the writer can do.
And you’re the one who will move it later. The block is there for the learning period, because today you don’t yet know what to expect from the writer. The next step isn’t full freedom either: you can set the sending tools to Needs approval, where the writer asks you before anything leaves your mailbox. Only once you’ve been saying yes for a few weeks, with nothing to fix along the way, is Always allow worth considering.
Try the writer on a real message
Time for the first test. Pick a straightforward message from your mailbox – one you can answer without reading an attachment.
/writer Reply to the last message about the meeting date.
The writer will find the message, read enough of the thread, reach for your profile and prepare a reply. At the end, it saves it as a draft and tells you it hasn’t sent anything.
Now open Gmail and go to Drafts. The reply should be sitting there waiting for you.
Fix the draft, and say whether the fix is permanent
The first reply rarely sounds right straight away, and that isn’t a failure of the exercise. Go back to the conversation and say what to change:
Too formal. I don't open with "Hello" to this person, just their first name. And cut the last paragraph.
The writer will fix the draft. And here comes the part that’s easy to forget: tell it how far your remark reaches.
- “That’s how I always write” – have it update the profile too.
- “Only in this message” – have it change the reply and leave the profile alone.
Without that distinction the style file turns, within a month, into a pile of exceptions with no rule left in it.
Train the writer in two phases
For the first week, don’t just tell the writer what to change – explain where the rule comes from and how widely it applies.
Don't use emoji in email to clients, they read as too informal coming from me. In messages to the team they can stay.
Giving the reason helps more than it looks. The writer then gets a rule instead of a single case, and applies it in situations you never spelled out.
Once you notice you’re no longer fixing every other sentence, it’s time for phase two. You now make small corrections directly in the message, before sending it. Then go back to the conversation:
Look at my last sent message in this thread and compare it with your draft.
The writer will draw a conclusion from the difference – but not every difference is a rule. Ask it to propose a change to your writing style only where it sees a recurring pattern, and to let a one-off decision pass without a trace.
One thing to keep in mind. The Gmail connector doesn’t read the contents of attachments, so when the reply depends on a file somebody sent you, you’ll have to supply what’s in it separately. It also can’t put an image in your signature – if yours is graphic, have the AI end the message before the sign-off and add the signature yourself in Gmail, using the pen icon in the bar at the bottom of the compose window.
What to take away from this lesson
A skill can have more than one file. SKILL.md holds the procedure; the references directory holds material that Claude Code reads only when it needs it.
Your style profile comes from real sent messages, but you are the one who approves it. The mailbox says what your messages have looked like so far; how the AI writes from now on is your decision.
An instruction and a blocked tool are two different layers. A request inside a skill can be overridden in conversation; connector permissions cannot. Both are there for the learning period, and both come off once the writer writes well enough that you stop correcting it.
Not every fix to one message is a new rule. Each time, say whether the change is about this one email or about your writing in general.
The writer learns faster when it knows why. “Do it differently” changes one sentence; “not like that, because…” changes every sentence after it.
Tasks
Tick these off as you go. The state is kept in your browser, so you can come back to this list tomorrow.
- Skill saved by Claude Code and showing up after the slash in a new conversation
- Style profile built from sent messages and corrected before the file was saved
- Gmail tools that send messages set to Blocked
- Skill run on one real message from your mailbox
- Draft found in Gmail and read through
- One correction passed on with a note saying whether it’s a rule or an exception