Marketing

A Prompt Library for Cold Email Variants

Antonio Evans8 min read

A clean desk scene showing a single printed one-page brief labeled 'Opener Rules' pinned above a laptop.
Key points

Key points

  1. 1A single versioned context file, passed with every request, keeps model-drafted openers consistent across variants.
  2. 2Reply rates split sharply by personalization depth, so the file must name which personalization sources are allowed and which are banned.
  3. 3CAN-SPAM requires accurate headers, a physical postal address, a working opt-out, and opt-outs honored within 10 business days, all of which the file must encode.
  4. 4The opener is written for a six-second decision window, so the file should cap length and force one specific, verifiable fact.

Why the opener needs a stable brief

A cold email is decided in seconds. One practitioner guide puts the attention window at roughly 6 seconds, barely enough time to read two sentences, and notes that the first line is often previewed in the inbox next to the subject line the Fundraise Insider guide. Another writer puts it at about 2.7 seconds before a reader decides whether to continue Carly Ayres on cold email. Either way, the opener carries most of the weight.

That is exactly why a language model needs a fixed brief rather than a fresh instruction each time. When you ask a model to "write a personalized opener" with no constraints, it optimizes for plausible-sounding text. It will reach for flattery, invent details, or drift into a different tone between runs. Give it the same file every time and the variance collapses to the parts that should vary: the prospect's facts and the campaign's angle.

The performance gap makes this worth the effort. Generic blasts average reply rates around 3.43% according to Instantly's benchmark report as cited by Autobound's cold email guide, while campaigns with signal-specific personalization reach about 18%, and smaller targeted campaigns of 50 recipients or fewer average 5.8% against 2.1% for larger lists, per Belkins data cited in the same guide. Consistency is not a style preference. It is how you stay on the good side of that split.

What belongs in the context file

Think of the file as a style guide a new hire would need on day one, written as instructions to a model. Six blocks cover almost everything:

  1. Audience definition. Who the recipient is, their role, their company stage, and the one problem this campaign addresses. For example: "VP of Ops at a 200 to 500 person logistics company that just opened a second warehouse."
  2. Allowed personalization sources. A closed list. "Funding rounds, leadership changes, hiring surges, published posts, and earnings call mentions only." Anything outside the list is out of bounds.
  3. Tone constraints. Plain, declarative, peer to peer. No exclamation marks. No adjectives about the prospect's company unless quoted.
  4. Banned phrases. The specific words that mark an email as a template.
  5. Length limits. A hard maximum for the opener, expressed in words and characters, plus what must appear in the first 90 characters because that is the preview snippet.
  6. Compliance lines. Sender identity, physical postal address, and the opt-out mechanism, since these are legal requirements, not style choices.

The order of a good file matters. Put the audience and sources first so the model reads the constraints before it reads the task, then repeat the length and format rules at the very end of the request. That closing reminder improves format compliance because models weight recent instructions more heavily, as one practitioner write-up on long-context output stability explains Lilian Li on stable output formats.

The worked example: one file, four blocks

Here is a compact version you can adapt. It is deliberately short: a context file that fits on one screen is easier to version and review than a sprawling one.

ROLE
You draft the first two sentences of a cold email. You do not write
the subject line, the body, or the call to action.

AUDIENCE
Role: operations leaders.
Company: 100-500 employees, physical operations (logistics, field service).
Trigger: opened a new site, changed leadership, or raised funding
in the last 90 days.

ALLOWED SOURCES
Only facts supplied in PERSON field. Never infer, never embellish.
If PERSON is empty, output NEEDS_DATA and stop.

TONE
Plain, specific, peer to peer. 8th grade reading level.
No superlatives. No exclamation marks. No questions in line one.

BANNED PHRASES
hope this finds you well, quick question, circle back, touch base,
synergy, game changer, reach out, pick your brain, just following up,
I wanted to, I noticed that you

LENGTH
Line 1: 12 to 22 words. Line 2: 10 to 18 words.
First 90 characters must contain the specific fact.

OUTPUT
Two lines of plain text. No greeting, no sign-off, no preamble.

Two choices in that file do real work. The NEEDS_DATA escape hatch stops the model from inventing a hook when the prospect record is thin, which is the failure mode that damages sender reputation. The 90-character rule forces the specific fact into the inbox preview, because that snippet often gets more screen space than the subject line Mixmax's opening line guide.

Feed it a person record like this:

{"PERSON": "New COO started 6 weeks ago per company newsroom; company opened a Dallas facility in the same quarter."}

Run it twice against two different models through one API and you should get near-identical shape with different content: "Your new COO inherits a Dallas site that opened the same quarter she started. Teams usually discover the ramp plan and the staffing plan disagree around week six." The second sentence is the only place the model gets creative, and the file told it exactly how much room it has.

If you need to run that same file across several models to compare tone, Quanta Inference gives you text models behind one OpenAI-compatible key, so you can test the brief without maintaining a separate integration per provider.

Comparison: what earns a place in the file and what does not

ElementPut it in the fileKeep it in the requestWhy
Audience and trigger definitionYesNoSame for every variant in a campaign
Allowed personalization sourcesYesNoPrevents invented facts at scale
Banned phrases listYesNoRules apply across all variants
Word and character limitsYesRepeat at endRecency helps format compliance
Prospect factsNoYesChanges per email
Campaign offer or askNoYesVaries by sequence step
Sender legal identity and addressYesNoCompliance requirement, never optional
Opt-out wordingYesNoMust be identical every send

The decision rule: if a rule would be wrong to break on one email, it belongs in the file. If it would be wrong to repeat identically on two emails, it belongs in the request.

Encoding compliance so the model cannot forget it

Commercial email in the US is governed by the CAN-SPAM Act, and the FTC's guide is blunt that there is no business-to-business exception the FTC compliance guide. The requirements that touch an opener-level prompt file are:

  • Accurate From, To, and Reply-To information.
  • A non-deceptive subject line.
  • A clear disclosure that the message is an ad.
  • A valid physical postal address.
  • A clear opt-out mechanism that works for at least 30 days.
  • Opt-out requests honored within 10 business days.

Penalties are per email, at up to $53,088 per message per the FTC's inflation-adjusted maximum, a figure repeated across compliance write-ups Transcend's CAN-SPAM guide and Usercentrics' compliance guide. Because the penalty attaches per message, a prompt file that omits the address or the opt-out line does not fail once. It fails on every send.

A practical pattern is to make the model never responsible for the footer. The file instructs the model to emit opener text only, and the sending system appends a fixed block containing the postal address, the ad disclosure, and the unsubscribe link. That split keeps the creative work and the legal work in different places, which also means you can update the address without re-reviewing every prompt.

There is a second compliance angle specific to CAN-SPAM: opt-out lists cannot be sold or transferred, and requests must be honored promptly Lewis Rice's compliance tips. Your generation pipeline should check suppression lists before drafting, not after. If a prospect is on the do-not-email list, the model should never be asked to write to them.

Structuring the file so variants stay honest

A prompt library is really a small software project. Treat it that way and three problems disappear.

Version it like code. Name the file with a semantic version, keep it in the same repository as your campaign definitions, and log which version produced which batch of openers. When a variant underperforms, you compare against the version, not your memory of what the instructions said.

Separate stable rules from campaign-specific sections. The audience, tone, bans, and compliance blocks rarely change. The trigger definition and the offer change per campaign. A single file with clearly marked sections works; separate files that get concatenated at request time work better once you run more than a handful of campaigns.

Add a rejection clause. Models follow negative instructions inconsistently. The reliable pattern is to make the model self-check: "Before returning, confirm the opener contains no banned phrase, is within the word limits, and mentions the supplied fact. If any check fails, rewrite once, then return READY or FAILED." This mirrors structured prompt practice, where explicit separators and a defined output shape reduce ambiguity ubiai on structured prompts.

System-level instructions carry more weight than user messages when the two conflict, so the file should be sent as the system prompt and the prospect facts as the user message Tetrate's system prompt guide. That hierarchy means a hastily written prospect record cannot accidentally override your tone rules.

Personalization sources worth allowing, and ones to ban

The single biggest quality lever in the file is the source list. Signal-based openers use real, timestamped events, and the frameworks that work consistently reference the amount and the stated use of funds, a competitor's move, a public metric, a mutual contact, or a specific piece of published work Fundraise Insider. A checklist for the allowed list:

  • Allow: funding announcements, leadership changes, job postings, published posts, earnings mentions, product launches, and verified local details for small businesses.
  • Ban: anything the model cannot cite from the supplied record, guesses about hobbies or family, generic praise, and any fact older than the window you define (90 days is a common choice).

The second list matters because shallow personalization is worse than none. Generic compliments signal that no research happened and are read as mass mail the Leadhaste guide. One rule in the file removes the entire category: "Every opener must contain one fact from the PERSON field, quoted or paraphrased without adding detail."

Length is the other honest constraint. Short, plain-text emails outperform dense ones, and a follow-up sequence should stay short and focused on the same offer Resquared on sequence length. If the opener is capped at 40 words total, the rest of the email has room to be a single ask. Set that number once in the file and every variant inherits it.

Testing variants without fooling yourself

Variants exist to be measured, so build the measurement into the file output. Ask the model to return the opener plus two fields: the personalization type it used, and the specific fact it referenced. Now your sending platform can group replies by personalization type without anyone reading emails by hand.

Run the comparison on qualified replies, not opens. Individual open tracking is no longer dependable, so a sequence should be judged on replies and conversations Resquared. With generic reply rates near 3.4% and signal-based campaigns near 18%, a useful test does not need enormous volume to show a difference, but it does need the same brief on both sides Autobound.

Three habits keep tests clean. Change one file block per test, so a change in the banned list is never bundled with a change in the audience. Hold the list of prospects constant across variants where you can. Keep a control opener written by a human in the rotation, because it tells you whether the file is helping or whether the model is simply fluent.

If the drafting, sequencing, and reporting work is better handed to someone who does it repeatedly, Quanta's experts take the brief and return finished deliverables, from the context file to the campaign copy Quanta Experts.

FAQ

FAQ

What is a prompt library for cold email openers?

It is a set of versioned context files that hold the rules every opener must follow, passed with each request to the model. The model supplies the phrasing and the prospect-specific content; the file supplies the audience, allowed sources, tone, bans, length, and compliance rules. One brief, many variants.

How long should the context file be?

Short enough that a reviewer can read it in one sitting. Most teams need under one page for audience, sources, tone, bans, length, and output format. Length constraints belong at the start of the system prompt and again at the end of the request, because models weight recent instructions more heavily Lilian Li.

Should the model write the unsubscribe link and postal address?

No. The FTC requires a valid physical address, an accurate sender identity, and an opt-out that works for at least 30 days, with requests honored within 10 business days, and penalties apply per email the FTC guide. Let the model draft the opener and have your sending system append a fixed footer so the legal block is never regenerated.

What should the model do when a prospect record is thin?

Return a failure signal rather than inventing a hook. Add a clause that the model must output a fixed marker when the personalization field is empty, and route those records to manual review or a different campaign. Invented details are the fastest way to burn a prospect and a domain.

How do I measure whether the file is working?

Group replies by the personalization type the model reports, and compare against a human-written control. Judge on qualified replies and conversations rather than opens, since individual open tracking is unreliable Resquared. Change one block per test so you know which rule moved the number.

Sources

Sources

  1. The Best Cold Email Opening Lines That Actually Get ...
  2. How to write a cold email - by Carly Ayres - Good Graf!
  3. Cold Email Guide 2026: Best Practices & Benchmarks | Autobound
  4. Prompt Engineering: Stable output format in long contexts
  5. 11 Cold Email Opening Lines to Boost Replies
  6. CAN-SPAM Act: A Compliance Guide for Business
  7. The CAN-SPAM Act: A complete 2026 compliance guide - Transcend.io
  8. The CAN-SPAM Act: Compliance Guide with Best Practices
  9. Practical Tips for CAN-SPAM Act Compliance | Billee Elliott McAuliffe
  10. Ensuring Consistent LLM Outputs Using Structured Prompts
  11. System Prompts: Design Patterns and Best Practices
  12. Best Cold Email Opening Lines That Get Replies Every Time
  13. How many emails should a cold outreach sequence include?
About the author

About the author

Antonio Evans
Antonio Evans

Antonio Evans is the founder of Quanta Intelligence and a fractional CTO who builds HIPAA-ready AI systems for health and life-science companies. Before that he was technical co-founder of FriendsEAT for twenty years, CEO of Socialdraft, and a data engineer at IBM. Antonio lives with his dog Santino in Lisbon, Portugal.

All articles