diff --git a/b2b_marketing_assistant_plan.md b/b2b_marketing_assistant_plan.md index 44182624..74cbe948 100644 --- a/b2b_marketing_assistant_plan.md +++ b/b2b_marketing_assistant_plan.md @@ -218,24 +218,4 @@ Das System liefert nun hochqualitative, faktenbasierte Analysen ("Grounding") mi -### Priorität 3: Erweiterung des Finalen Reports - - - -Um den Wert der Analyse zu steigern, werden die folgenden Informationen in den finalen Report integriert: - - - -* **Search Strategy Beschreibung ICP:** Eine detaillierte Beschreibung der Ideal Customer Profile (ICP) basierend auf der Analyse. - - - -* **Digital Signals:** Identifikation und Beschreibung relevanter digitaler Signale, die auf Kaufinteresse oder Engagement hinweisen. - - - -* **Target Pages:** Eine Liste der wichtigsten Zielseiten auf der Unternehmenswebsite, die für Marketing- und Vertriebsaktivitäten relevant sind. - - - diff --git a/b2b_marketing_orchestrator.py b/b2b_marketing_orchestrator.py index cefc77c0..801870f4 100644 --- a/b2b_marketing_orchestrator.py +++ b/b2b_marketing_orchestrator.py @@ -150,39 +150,6 @@ Fuehre fuer jede **[Rolle]** innerhalb der **[Fokus-Branche: {{focus_industry}}] Erstelle ONLY die finale Markdown-Tabelle. * **Table Columns:** *Fokus-Branche | Rolle | Kernbotschaft (2-3 sentences) | {{channels}}*. * **Requirement:** Your response must start with the heading \"## Schritt 6: Botschaften\" and contain ONLY die vollstaendige Markdown-Tabelle.""", - """# Aufgabe -Fuehre nun **Schritt 7 - Search Strategy Beschreibung ICP** durch. - -# Kontext: Validierte Ergebnisse aus vorherigen Schritten -{{previous_steps_data}} - -# Anweisungen fuer Schritt 7 -* Formuliere eine detaillierte Beschreibung des Ideal Customer Profile (ICP) basierend auf allen bisherigen Analyseergebnissen. -* Gehe auf Unternehmensmerkmale, Branchen, typische Painpoints und die relevantesten Rollen ein. -* **Output:** Eine Markdown-Tabelle mit Spalten: *Kriterium | Beschreibung | Begruendung/Quelle (URL oder Schritt-Referenz)*. -* **Format-Anforderung:** Antworte NUR mit den Ergebnissen fuer diesen einen Schritt. Deine Antwort muss mit der Ueberschrift \"## Schritt 7: Search Strategy Beschreibung ICP\" beginnen und die Markdown-Tabelle enthalten.""", - """# Aufgabe -Fuehre nun **Schritt 8 - Digital Signals** durch. - -# Kontext: Validierte Ergebnisse aus vorherigen Schritten -{{previous_steps_data}} - -# Anweisungen fuer Schritt 8 -* Identifiziere relevante digitale Signale, die auf Kaufinteresse, Engagement oder spezifische Beduerfnisse der Zielkunden hinweisen koennten. -* Denke an Verhaltensweisen auf der Unternehmenswebsite, in sozialen Medien, bei der Nutzung bestimmter Tools oder bei der Interaktion mit Inhalten. -* **Output:** Eine Markdown-Tabelle mit Spalten: *Digitales Signal | Beschreibung | Indikator fuer | Relevanz fuer ICP (URL oder Schritt-Referenz)*. -* **Format-Anforderung:** Antworte NUR mit den Ergebnissen fuer diesen einen Schritt. Deine Antwort muss mit der Ueberschrift \"## Schritt 8: Digital Signals\" beginnen und die Markdown-Tabelle enthalten.""", - """# Aufgabe -Fuehre nun **Schritt 9 - Target Pages** durch. - -# Kontext: Validierte Ergebnisse aus vorherigen Schritten -{{previous_steps_data}} - -# Anweisungen fuer Schritt 9 -* Identifiziere die wichtigsten Zielseiten (Target Pages) auf der analysierten Unternehmenswebsite, die fuer Marketing- und Vertriebsaktivitaeten relevant sind. -* Beruecksichtige Produkt-/Loesungsseiten, Branchenseiten, Fallstudien, Ueber-uns-Seiten, Kontaktseiten etc. -* **Output:** Eine Markdown-Tabelle mit Spalten: *Seitenname | URL | Relevanz fuer ICP/Marketing | Zugehoeriger Schritt (z.B. Angebot, Painpoint)*. -* **Format-Anforderung:** Antworte NUR mit den Ergebnissen fuer diesen einen Schritt. Deine Antwort muss mit der Ueberschrift \"## Schritt 9: Target Pages\" beginnen und die Markdown-Tabelle enthalten.""" ] SYSTEM_PROMPT_EN = """# System Role @@ -257,38 +224,39 @@ Now perform **Step 5 - Gains & Benefits per Role (WHY switch)**. * **Output:** Table: *Role | Gain (specific benefit) | Quantification (Hypothesis in EUR, h, %) | Source/Indication (URL)*. * **Format Requirement:** Respond ONLY with the results for this single step. Your response must start with the heading \"## Step 5: Gains & Benefits per Role\".""", """# Task -Now perform **Step 7 - Search Strategy ICP Description**. +Now perform **Step 6 - Marketing Message (HOW to speak)**. # Context: Validated results from previous steps {{previous_steps_data}} -# Instructions for Step 7 -* Formulate a detailed description of the Ideal Customer Profile (ICP) based on all previous analysis results. -* Address company characteristics, industries, typical pain points, and the most relevant roles. -* **Output:** A Markdown table with columns: *Criterion | Description | Justification/Source (URL or Step Reference)*. -* **Format Requirement:** Respond ONLY with the results for this single step. Your response must start with the heading \"## Step 7: Search Strategy ICP Description\" and include the Markdown table.""", - """# Task -Now perform **Step 8 - Digital Signals**. +# Inputs for this step +* **Desired channels for the message:** `{{channels}}` -# Context: Validated results from previous steps -{{previous_steps_data}} +# Instructions for Step 6: Chain-of-Thought Analysis & Copywriting -# Instructions for Step 8 -* Identify relevant digital signals that could indicate purchase interest, engagement, or specific needs of target customers. -* Consider behaviors on the company website, social media, use of specific tools, or interaction with content. -* **Output:** A Markdown table with columns: *Digital Signal | Description | Indicator for | Relevance for ICP (URL or Step Reference)*. -* **Format Requirement:** Respond ONLY with the results for this single step. Your response must start with the heading \"## Step 8: Digital Signals\" and include the Markdown table.""", - """# Task -Now perform **Step 9 - Target Pages**. +**FOCUS:** Create messages **EXCLUSIVELY** for the provided **Focus Industry: {{focus_industry}}**. +Ignore all other industries. Your goal is to create a specific message for EACH role within this ONE industry. -# Context: Validated results from previous steps -{{previous_steps_data}} +For each **[Role]** within the **[Focus Industry: {{focus_industry}}]**, perform the following thought process: -# Instructions for Step 9 -* Identify the most important target pages on the analyzed company website that are relevant for marketing and sales activities. -* Consider product/solution pages, industry pages, case studies, about us pages, contact pages, etc. -* **Output:** A Markdown table with columns: *Page Name | URL | Relevance for ICP/Marketing | Associated Step (e.g., Offer, Pain Point)*. -* **Format Requirement:** Respond ONLY with the results for this single step. Your response must start with the heading \"## Step 9: Target Pages\" and include the Markdown table.""" +1. **Step 6.1 (Analysis): Product-Role Fit.** + * Which product/solution from the "Offer" table (Step 1) is most relevant for the **[Role]**? + +2. **Step 6.2 (Analysis): Industry Use Case.** + * What are 1-2 typical use cases for the selected product in the **[Focus Industry]**? What does the **[Role]** actually do with it? + +3. **Step 6.3 (Analysis): Benefit Quantification.** + * Look at the Pain Points (Step 4) and Gains (Step 5) for the **[Role]**. + * Derive a concrete KPI relevant to the **[Role]**. + +4. **Step 6.4 (Synthesis): Formulate Message.** + * Synthesize the findings from 6.1-6.3 into a concise core message (2-3 sentences) following the structure: **Observation (Problem) -> Low-threshold Solution Idea -> Product Bridge -> Quantified Benefit.** + * Create variants of this message for the channels: {{channels}}. + +# Output Format +Create ONLY the final Markdown table. +* **Table Columns:** *Focus Industry | Role | Core Message (2-3 sentences) | {{channels}}*. +* **Requirement:** Your response must start with the heading \"## Step 6: Messages\" and contain ONLY the complete Markdown table.""" ] PROMPTS = { @@ -302,9 +270,6 @@ PROMPTS = { 'painPoints': 'Schritt 4: Painpoints je Rolle (WARUM)', 'gains': 'Schritt 5: Gains & Nutzen je Rolle (WARUM wechseln)', 'messages': 'Schritt 6: Marketingbotschaften je Segment & Rolle (WIE sprechen)', - 'searchStrategyICP': 'Schritt 7: Search Strategy Beschreibung ICP', - 'digitalSignals': 'Schritt 8: Digital Signals', - 'targetPages': 'Schritt 9: Target Pages', }, 'SUMMARY_TITLE': 'Kurzresuemee:', 'SUMMARY_TEXT_FOR_STEP1': [ @@ -322,9 +287,6 @@ PROMPTS = { 'painPoints': 'Step 4: Pain Points per Role (WHY)', 'gains': 'Step 5: Gains & Benefits per Role (WHY switch)', 'messages': 'Step 6: Marketing Messages per Segment & Role (HOW to speak)', - 'searchStrategyICP': 'Step 7: Search Strategy ICP Description', - 'digitalSignals': 'Step 8: Digital Signals', - 'targetPages': 'Step 9: Target Pages', }, 'SUMMARY_TITLE': 'Summary:', 'SUMMARY_TEXT_FOR_STEP1': [ @@ -470,7 +432,7 @@ def format_context_for_prompt(analysis_data, language): context = "" current_prompts = PROMPTS[language] step_titles = current_prompts['STEP_TITLES'] - step_keys = ['offer', 'targetGroups', 'personas', 'painPoints', 'gains', 'messages', 'searchStrategyICP', 'digitalSignals', 'targetPages'] + step_keys = ['offer', 'targetGroups', 'personas', 'painPoints', 'gains', 'messages'] for i, step_key in enumerate(step_keys): step_data = analysis_data.get(step_key) if step_data: @@ -568,7 +530,7 @@ def next_step(language, context_file, generation_step, channels, focus_industry= # Log the full response save_detailed_log(f"step{generation_step}", "response", response_text) - step_key = ['offer', 'targetGroups', 'personas', 'painPoints', 'gains', 'messages', 'searchStrategyICP', 'digitalSignals', 'targetPages'][generation_step - 1] + step_key = ['offer', 'targetGroups', 'personas', 'painPoints', 'gains', 'messages'][generation_step - 1] expected_title = current_prompts['STEP_TITLES'][step_key] title_match = re.search(rf'## {re.escape(expected_title)}\s*', response_text, re.IGNORECASE) content = response_text[title_match.end():].strip() if title_match else response_text