Update app.py
Browse files
app.py
CHANGED
|
@@ -69,21 +69,24 @@ def contextual_pitch_assistant(csv_file, query, sender_name):
|
|
| 69 |
style_instruction = "Balance clinical, patient, and business value."
|
| 70 |
|
| 71 |
# Build prompt
|
|
|
|
| 72 |
prompt = f"""
|
| 73 |
-
You are an expert in B2B
|
| 74 |
-
|
| 75 |
-
Write a short, natural-sounding HTML sales email for a dental clinic.
|
| 76 |
|
| 77 |
Rules:
|
| 78 |
-
-
|
| 79 |
-
-
|
| 80 |
- Adapt the pitch style: {style_instruction}
|
| 81 |
-
-
|
| 82 |
-
|
| 83 |
-
|
| 84 |
-
|
| 85 |
-
|
| 86 |
-
-
|
|
|
|
|
|
|
|
|
|
| 87 |
- Return only HTML — no markdown, no code fences.
|
| 88 |
|
| 89 |
Query:
|
|
@@ -93,6 +96,7 @@ CRM context (for your understanding, do not copy verbatim):
|
|
| 93 |
{row_to_text(row)}
|
| 94 |
"""
|
| 95 |
|
|
|
|
| 96 |
response = client.chat.completions.create(
|
| 97 |
model="gpt-4o-mini",
|
| 98 |
messages=[{"role": "user", "content": prompt}],
|
|
|
|
| 69 |
style_instruction = "Balance clinical, patient, and business value."
|
| 70 |
|
| 71 |
# Build prompt
|
| 72 |
+
|
| 73 |
prompt = f"""
|
| 74 |
+
You are an expert in B2B sales messaging, inspired by Challenger Sales and Jeb Blount’s prospecting techniques.
|
| 75 |
+
Your job is to write a short, natural-sounding HTML email pitch to a dental clinic.
|
|
|
|
| 76 |
|
| 77 |
Rules:
|
| 78 |
+
- Begin with "Dear {account_manager}," as the greeting.
|
| 79 |
+
- Anchor immediately in the clinic’s recent concern: "{notes}".
|
| 80 |
- Adapt the pitch style: {style_instruction}
|
| 81 |
+
- Apply Challenger logic:
|
| 82 |
+
* Start with the client’s voice or concern.
|
| 83 |
+
* Reframe with an insight (show a broader problem or missed opportunity).
|
| 84 |
+
* Link features → outcomes → business/patient/clinical impact.
|
| 85 |
+
* Use confident, but helpful tone — not pushy, not bland.
|
| 86 |
+
- Keep under 150 words.
|
| 87 |
+
- End with a strong, specific CTA (e.g. propose a short call or demo, suggest a time).
|
| 88 |
+
- Never use placeholders like "Your Company" or "[Your Name]".
|
| 89 |
+
- Close with "Best regards," followed by "{sender_name}".
|
| 90 |
- Return only HTML — no markdown, no code fences.
|
| 91 |
|
| 92 |
Query:
|
|
|
|
| 96 |
{row_to_text(row)}
|
| 97 |
"""
|
| 98 |
|
| 99 |
+
|
| 100 |
response = client.chat.completions.create(
|
| 101 |
model="gpt-4o-mini",
|
| 102 |
messages=[{"role": "user", "content": prompt}],
|