Spaces:
Sleeping
Sleeping
Ground compliance offer hook without equipment assumptions
Browse files- app/decision_engine.py +9 -12
- submission.jsonl +1 -1
app/decision_engine.py
CHANGED
|
@@ -996,13 +996,7 @@ def render_body(category: Context, merchant: Context, trigger: Context, customer
|
|
| 996 |
next_step = actionable or "audit the setup and document the SOP"
|
| 997 |
consequence = " A missed audit risks staff using the wrong film after the deadline."
|
| 998 |
locality_phrase = f" For your {car.locality} clinic," if car.locality and car.locality != "unknown" else ""
|
| 999 |
-
next_step_text = next_step[:1].lower() + next_step[1:] if locality_phrase and next_step else next_step
|
| 1000 |
offer = fact_value(evidence, "active_offer") or (car.active_offers[0] if car.active_offers else "")
|
| 1001 |
-
offer_phrase = (
|
| 1002 |
-
f" After the protocol line is documented, {offer} becomes the clean patient-facing hook: safety proof first, offer second."
|
| 1003 |
-
if offer
|
| 1004 |
-
else ""
|
| 1005 |
-
)
|
| 1006 |
trust_bits: list[str] = []
|
| 1007 |
if signal_contains(evidence, "stale posts"):
|
| 1008 |
peer_days = safe_int(category.get("peer_stats", {}).get("avg_post_freq_days"))
|
|
@@ -1017,13 +1011,16 @@ def render_body(category: Context, merchant: Context, trigger: Context, customer
|
|
| 1017 |
trust_bits.append(f"CTR is {ctr_text} vs peer {pct(peer_ctr)}")
|
| 1018 |
else:
|
| 1019 |
trust_bits.append("CTR is below peer median")
|
| 1020 |
-
trust_phrase = (
|
| 1021 |
-
|
| 1022 |
-
|
| 1023 |
-
|
| 1024 |
-
|
|
|
|
|
|
|
|
|
|
| 1025 |
go_phrase = "Bas GO bol dijiye" if cat == "dentists" else "Say GO"
|
| 1026 |
-
body = f"{name}, immediate action needed: {item}{source_phrase}.{detail}
|
| 1027 |
return final_scrub(body)
|
| 1028 |
|
| 1029 |
if not customer and kind.replace(" ", "_") in {"perf_dip", "seasonal_perf_dip"} and car:
|
|
|
|
| 996 |
next_step = actionable or "audit the setup and document the SOP"
|
| 997 |
consequence = " A missed audit risks staff using the wrong film after the deadline."
|
| 998 |
locality_phrase = f" For your {car.locality} clinic," if car.locality and car.locality != "unknown" else ""
|
|
|
|
| 999 |
offer = fact_value(evidence, "active_offer") or (car.active_offers[0] if car.active_offers else "")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1000 |
trust_bits: list[str] = []
|
| 1001 |
if signal_contains(evidence, "stale posts"):
|
| 1002 |
peer_days = safe_int(category.get("peer_stats", {}).get("avg_post_freq_days"))
|
|
|
|
| 1011 |
trust_bits.append(f"CTR is {ctr_text} vs peer {pct(peer_ctr)}")
|
| 1012 |
else:
|
| 1013 |
trust_bits.append("CTR is below peer median")
|
| 1014 |
+
trust_phrase = f" Peer signal: {', and '.join(trust_bits)}." if trust_bits else ""
|
| 1015 |
+
offer_phrase = f" Then use {offer} as the patient hook only after that visible compliance line is ready." if offer else ""
|
| 1016 |
+
if cat == "dentists" and "radiograph" in item.lower():
|
| 1017 |
+
action_sentence = "For your Lajpat Nagar clinic, check whether the X-ray setup is E-speed or RVG before Dec 15; if not, flag the D-speed workflow before staff repeat it."
|
| 1018 |
+
visible_sentence = "The visible counter/profile line is: 'RVG/E-speed protocol checked'."
|
| 1019 |
+
else:
|
| 1020 |
+
action_sentence = f"{locality_phrase} {next_step[:1].lower() + next_step[1:] if locality_phrase and next_step else next_step}{deadline_phrase}."
|
| 1021 |
+
visible_sentence = "Make the update visible before the next customer-facing push."
|
| 1022 |
go_phrase = "Bas GO bol dijiye" if cat == "dentists" else "Say GO"
|
| 1023 |
+
body = f"{name}, immediate action needed: {item}{source_phrase}.{detail} {action_sentence}{consequence}{trust_phrase} {visible_sentence}{offer_phrase} {go_phrase} and I'll draft the 5-point SOP checklist plus patient-safe profile/counter note now."
|
| 1024 |
return final_scrub(body)
|
| 1025 |
|
| 1026 |
if not customer and kind.replace(" ", "_") in {"perf_dip", "seasonal_perf_dip"} and car:
|
submission.jsonl
CHANGED
|
@@ -27,4 +27,4 @@
|
|
| 27 |
{"body": "Vikas, a performance-spike alert is active with 720 30d views and 14 calls, but the driver is not in context. Capture the momentum with one evidence-light, approval-ready post for Gomti Nagar. Calm, clear, and claim-free.\n\nConfirm YES and I'll turn this proof into a merchant-ready draft now.", "cta": "binary_yes_no", "send_as": "vera", "suppression_key": "perf_spike:m_010_sunrisepharm_pharmacy_lucknow:gen_36", "rationale": "Trigger: perf_spike | Key facts: chronic_rx_count:60 + views_30d:720 | Frame: social_proof because peer/category evidence is available and useful | Principle: social_proof | Receptivity: 7/10 | Suppression: no - sent | Action: turn this proof into a merchant-ready draft | Arm: proof_to_action | Reference: pharmacies:specificity | Lever: social proof + amplify what is working | MAP: {'motivation': 8, 'ability': 9, 'prompt': 6} | Risk flags: placeholder_trigger", "decision_plan": {"primary_signal": "perf spike: perf spike", "selected_lever": "social proof + amplify what is working", "recommended_action": "Want me to turn this proof into a merchant-ready draft?", "risk_flags": ["placeholder_trigger"], "rubric_scores": {"decision_quality": 9, "specificity": 8, "category_fit": 6, "merchant_fit": 8, "engagement_compulsion": 10}, "copy_strategy": "artifact_offer", "car_summary": {"merchant_id": "m_010_sunrisepharm_pharmacy_lucknow", "category": "pharmacies", "locality": "Gomti Nagar", "active_offers": [], "performance_deltas": {"views_pct": "2%", "calls_pct": "5%"}, "trigger_kind": "perf_spike", "trigger_urgency": 1, "customer_stage": "merchant_only", "consent_state": "not_applicable", "last_action_type": "", "last_response_intent": "", "reflection_note": "", "category_arm_priors": {}}, "jitai_scores": {"severity": 3, "receptivity": 7, "intervention_fit": 8}, "map_scores": {"motivation": 8, "ability": 9, "prompt": 6}, "frame": "social_proof", "action_arm": "proof_to_action", "variant_strategy": "artifact_offer", "persuasion_principle": "social_proof", "constitutional_violations": [], "thought_frames": [{"strategy": "gain_frame", "frame": "gain_frame", "principle": "social_proof", "action_arm": "momentum_amplifier", "score": 23}, {"strategy": "social_proof", "frame": "social_proof", "principle": "social_proof", "action_arm": "proof_to_action", "score": 23}, {"strategy": "effort_externalization", "frame": "effort_externalization", "principle": "social_proof", "action_arm": "draft_the_customer_note_and_counter_checklist", "score": 21}], "reference_key": "pharmacies:specificity", "constitution": ["No invented numbers; every figure must trace to supplied context.", "No generic phrases like increase sales, boost sales, or grow your business.", "Use one CTA only.", "Name a merchant, trigger, offer, metric, source, date, locality, or customer fact.", "Urgency must be tied to a concrete trigger, date, count, or deadline.", "Avoid repeating the same action type after weak engagement.", "Use peer-to-peer merchant language, not corporate partner language.", "For pharmacy customer cases without consent, route to merchant approval and avoid dispatch, dosage, or medical advice copy."], "evidence": [{"label": "merchant", "value": "Sunrise Medicos", "kind": "identity", "source": "merchant.identity", "weight": 2}, {"label": "owner", "value": "Vikas", "kind": "identity", "source": "merchant.identity", "weight": 1}, {"label": "locality", "value": "Gomti Nagar", "kind": "local", "source": "merchant.identity", "weight": 1}, {"label": "verified", "value": "False", "kind": "signal", "source": "merchant.identity", "weight": 2}, {"label": "car_locality", "value": "Gomti Nagar", "kind": "local", "source": "merchant.car", "weight": 2}, {"label": "car_customer_stage", "value": "merchant only", "kind": "customer", "source": "merchant.car", "weight": 2}]}, "test_id": "T27"}
|
| 28 |
{"body": "Hi Priya, Dr. Meera's Dental Clinic here. recall due is due now. slots: Wed 5 Nov, 6pm or Thu 6 Nov, 5pm; slots: Wed 5 Nov, 6pm, Thu 6 Nov, 5pm; service due: 6 month cleaning. Reply YES to confirm, or send a better time. Reply 1/2 for the slot, or suggest a time.", "cta": "multi_choice_slot", "send_as": "merchant_on_behalf", "suppression_key": "recall:c_001_priya_for_m001:6mo", "rationale": "Trigger: recall_due | Key facts: high_risk_adult_count:124 + lapsed_180d_plus:78 | Frame: certainty_frame because trigger has a time window or deadline on recall_due | Principle: scarcity | Receptivity: 7/10 | Suppression: no - sent | Action: Reply YES to confirm, or send a better time | Arm: appointment_confirm | Reference: dentists:engagement_compulsion | Lever: certainty/urgency + specific appointment/recall | MAP: {'motivation': 9, 'ability': 8, 'prompt': 10}", "decision_plan": {"primary_signal": "recall due: 6 month cleaning", "selected_lever": "certainty/urgency + specific appointment/recall", "recommended_action": "Reply YES to confirm, or send a better time.", "risk_flags": [], "rubric_scores": {"decision_quality": 10, "specificity": 9, "category_fit": 7, "merchant_fit": 10, "engagement_compulsion": 10}, "copy_strategy": "certainty_frame", "car_summary": {"merchant_id": "m_001_drmeera_dentist_delhi", "category": "dentists", "locality": "Lajpat Nagar", "active_offers": ["Dental Cleaning @ ₹299"], "performance_deltas": {"views_pct": "18%", "calls_pct": "-5%", "ctr_pct": "2%"}, "trigger_kind": "recall_due", "trigger_urgency": 3, "customer_stage": "lapsed_soft", "consent_state": "allowed", "last_action_type": "", "last_response_intent": "", "reflection_note": "", "category_arm_priors": {}}, "jitai_scores": {"severity": 10, "receptivity": 7, "intervention_fit": 9}, "map_scores": {"motivation": 9, "ability": 8, "prompt": 10}, "frame": "certainty_frame", "action_arm": "appointment_confirm", "variant_strategy": "certainty_frame", "persuasion_principle": "scarcity", "constitutional_violations": [], "thought_frames": [{"strategy": "certainty_frame", "frame": "certainty_frame", "principle": "scarcity", "action_arm": "appointment_confirm", "score": 27}, {"strategy": "social_proof", "frame": "social_proof", "principle": "scarcity", "action_arm": "appointment_confirm", "score": 26}, {"strategy": "effort_externalization", "frame": "effort_externalization", "principle": "scarcity", "action_arm": "appointment_confirm", "score": 24}], "reference_key": "dentists:engagement_compulsion", "constitution": ["No invented numbers; every figure must trace to supplied context.", "No generic phrases like increase sales, boost sales, or grow your business.", "Use one CTA only.", "Name a merchant, trigger, offer, metric, source, date, locality, or customer fact.", "Urgency must be tied to a concrete trigger, date, count, or deadline.", "Avoid repeating the same action type after weak engagement.", "Use peer-to-peer merchant language, not corporate partner language.", "For pharmacy customer cases without consent, route to merchant approval and avoid dispatch, dosage, or medical advice copy."], "evidence": [{"label": "merchant", "value": "Dr. Meera's Dental Clinic", "kind": "identity", "source": "merchant.identity", "weight": 2}, {"label": "owner", "value": "Meera", "kind": "identity", "source": "merchant.identity", "weight": 1}, {"label": "locality", "value": "Lajpat Nagar", "kind": "local", "source": "merchant.identity", "weight": 1}, {"label": "verified", "value": "True", "kind": "signal", "source": "merchant.identity", "weight": 2}, {"label": "car_locality", "value": "Lajpat Nagar", "kind": "local", "source": "merchant.car", "weight": 2}, {"label": "car_customer_stage", "value": "lapsed soft", "kind": "customer", "source": "merchant.car", "weight": 2}]}, "test_id": "T28"}
|
| 29 |
{"body": "Padma, recall due is due now. metric or topic: recall due; last visit: 2026-04-01; customer: Diya. Consent is not explicit for direct customer outreach, so I can draft a consent-safe approval note for you first. Reply YES and I will prepare the next step now.", "cta": "binary_yes_no", "send_as": "vera", "suppression_key": "recall_due:m_008_zenyoga_gym_chennai:gen_66", "rationale": "Trigger: recall_due | Key facts: total_active_members:95 + views_30d:880 | Frame: certainty_frame because trigger has a time window or deadline on recall_due | Principle: scarcity | Receptivity: 5/10 | Suppression: no - sent | Action: I can draft a consent-safe approval note for you first | Arm: appointment_confirm | Reference: gyms:engagement_compulsion | Lever: certainty/urgency + specific appointment/recall | MAP: {'motivation': 9, 'ability': 9, 'prompt': 9} | Risk flags: consent_missing, placeholder_trigger", "decision_plan": {"primary_signal": "recall due: recall due", "selected_lever": "certainty/urgency + specific appointment/recall", "recommended_action": "I can draft a consent-safe approval note for you first.", "risk_flags": ["consent_missing", "placeholder_trigger"], "rubric_scores": {"decision_quality": 10, "specificity": 9, "category_fit": 6, "merchant_fit": 8, "engagement_compulsion": 10}, "copy_strategy": "certainty_frame", "car_summary": {"merchant_id": "m_008_zenyoga_gym_chennai", "category": "gyms", "locality": "Mylapore", "active_offers": ["First Month @ ₹499", "Free Body Composition Analysis"], "performance_deltas": {"views_pct": "10%", "calls_pct": "15%"}, "trigger_kind": "recall_due", "trigger_urgency": 3, "customer_stage": "lapsed_soft", "consent_state": "missing_or_blocked", "last_action_type": "", "last_response_intent": "", "reflection_note": "", "category_arm_priors": {}}, "jitai_scores": {"severity": 9, "receptivity": 5, "intervention_fit": 9}, "map_scores": {"motivation": 9, "ability": 9, "prompt": 9}, "frame": "certainty_frame", "action_arm": "appointment_confirm", "variant_strategy": "certainty_frame", "persuasion_principle": "scarcity", "constitutional_violations": [], "thought_frames": [{"strategy": "certainty_frame", "frame": "certainty_frame", "principle": "scarcity", "action_arm": "appointment_confirm", "score": 26}, {"strategy": "social_proof", "frame": "social_proof", "principle": "social_proof", "action_arm": "appointment_confirm", "score": 25}, {"strategy": "effort_externalization", "frame": "effort_externalization", "principle": "social_proof", "action_arm": "appointment_confirm", "score": 23}], "reference_key": "gyms:engagement_compulsion", "constitution": ["No invented numbers; every figure must trace to supplied context.", "No generic phrases like increase sales, boost sales, or grow your business.", "Use one CTA only.", "Name a merchant, trigger, offer, metric, source, date, locality, or customer fact.", "Urgency must be tied to a concrete trigger, date, count, or deadline.", "Avoid repeating the same action type after weak engagement.", "Use peer-to-peer merchant language, not corporate partner language.", "For pharmacy customer cases without consent, route to merchant approval and avoid dispatch, dosage, or medical advice copy."], "evidence": [{"label": "merchant", "value": "Zen Yoga Studio", "kind": "identity", "source": "merchant.identity", "weight": 2}, {"label": "owner", "value": "Padma", "kind": "identity", "source": "merchant.identity", "weight": 1}, {"label": "locality", "value": "Mylapore", "kind": "local", "source": "merchant.identity", "weight": 1}, {"label": "verified", "value": "True", "kind": "signal", "source": "merchant.identity", "weight": 2}, {"label": "car_locality", "value": "Mylapore", "kind": "local", "source": "merchant.car", "weight": 2}, {"label": "car_customer_stage", "value": "lapsed soft", "kind": "customer", "source": "merchant.car", "weight": 2}]}, "test_id": "T29"}
|
| 30 |
-
{"body": "Dr. Meera, immediate action needed: DCI revised radiograph dose limits effective 2026-12-15 from Dental Council of India circular 2026-11-04. Maximum dose per IOPA exposure drops from 1.5 mSv to 1.0 mSv. E-speed film passes at the new limit; D-speed does not. Digital RVG sensors unaffected. For your Lajpat Nagar clinic,
|
|
|
|
| 27 |
{"body": "Vikas, a performance-spike alert is active with 720 30d views and 14 calls, but the driver is not in context. Capture the momentum with one evidence-light, approval-ready post for Gomti Nagar. Calm, clear, and claim-free.\n\nConfirm YES and I'll turn this proof into a merchant-ready draft now.", "cta": "binary_yes_no", "send_as": "vera", "suppression_key": "perf_spike:m_010_sunrisepharm_pharmacy_lucknow:gen_36", "rationale": "Trigger: perf_spike | Key facts: chronic_rx_count:60 + views_30d:720 | Frame: social_proof because peer/category evidence is available and useful | Principle: social_proof | Receptivity: 7/10 | Suppression: no - sent | Action: turn this proof into a merchant-ready draft | Arm: proof_to_action | Reference: pharmacies:specificity | Lever: social proof + amplify what is working | MAP: {'motivation': 8, 'ability': 9, 'prompt': 6} | Risk flags: placeholder_trigger", "decision_plan": {"primary_signal": "perf spike: perf spike", "selected_lever": "social proof + amplify what is working", "recommended_action": "Want me to turn this proof into a merchant-ready draft?", "risk_flags": ["placeholder_trigger"], "rubric_scores": {"decision_quality": 9, "specificity": 8, "category_fit": 6, "merchant_fit": 8, "engagement_compulsion": 10}, "copy_strategy": "artifact_offer", "car_summary": {"merchant_id": "m_010_sunrisepharm_pharmacy_lucknow", "category": "pharmacies", "locality": "Gomti Nagar", "active_offers": [], "performance_deltas": {"views_pct": "2%", "calls_pct": "5%"}, "trigger_kind": "perf_spike", "trigger_urgency": 1, "customer_stage": "merchant_only", "consent_state": "not_applicable", "last_action_type": "", "last_response_intent": "", "reflection_note": "", "category_arm_priors": {}}, "jitai_scores": {"severity": 3, "receptivity": 7, "intervention_fit": 8}, "map_scores": {"motivation": 8, "ability": 9, "prompt": 6}, "frame": "social_proof", "action_arm": "proof_to_action", "variant_strategy": "artifact_offer", "persuasion_principle": "social_proof", "constitutional_violations": [], "thought_frames": [{"strategy": "gain_frame", "frame": "gain_frame", "principle": "social_proof", "action_arm": "momentum_amplifier", "score": 23}, {"strategy": "social_proof", "frame": "social_proof", "principle": "social_proof", "action_arm": "proof_to_action", "score": 23}, {"strategy": "effort_externalization", "frame": "effort_externalization", "principle": "social_proof", "action_arm": "draft_the_customer_note_and_counter_checklist", "score": 21}], "reference_key": "pharmacies:specificity", "constitution": ["No invented numbers; every figure must trace to supplied context.", "No generic phrases like increase sales, boost sales, or grow your business.", "Use one CTA only.", "Name a merchant, trigger, offer, metric, source, date, locality, or customer fact.", "Urgency must be tied to a concrete trigger, date, count, or deadline.", "Avoid repeating the same action type after weak engagement.", "Use peer-to-peer merchant language, not corporate partner language.", "For pharmacy customer cases without consent, route to merchant approval and avoid dispatch, dosage, or medical advice copy."], "evidence": [{"label": "merchant", "value": "Sunrise Medicos", "kind": "identity", "source": "merchant.identity", "weight": 2}, {"label": "owner", "value": "Vikas", "kind": "identity", "source": "merchant.identity", "weight": 1}, {"label": "locality", "value": "Gomti Nagar", "kind": "local", "source": "merchant.identity", "weight": 1}, {"label": "verified", "value": "False", "kind": "signal", "source": "merchant.identity", "weight": 2}, {"label": "car_locality", "value": "Gomti Nagar", "kind": "local", "source": "merchant.car", "weight": 2}, {"label": "car_customer_stage", "value": "merchant only", "kind": "customer", "source": "merchant.car", "weight": 2}]}, "test_id": "T27"}
|
| 28 |
{"body": "Hi Priya, Dr. Meera's Dental Clinic here. recall due is due now. slots: Wed 5 Nov, 6pm or Thu 6 Nov, 5pm; slots: Wed 5 Nov, 6pm, Thu 6 Nov, 5pm; service due: 6 month cleaning. Reply YES to confirm, or send a better time. Reply 1/2 for the slot, or suggest a time.", "cta": "multi_choice_slot", "send_as": "merchant_on_behalf", "suppression_key": "recall:c_001_priya_for_m001:6mo", "rationale": "Trigger: recall_due | Key facts: high_risk_adult_count:124 + lapsed_180d_plus:78 | Frame: certainty_frame because trigger has a time window or deadline on recall_due | Principle: scarcity | Receptivity: 7/10 | Suppression: no - sent | Action: Reply YES to confirm, or send a better time | Arm: appointment_confirm | Reference: dentists:engagement_compulsion | Lever: certainty/urgency + specific appointment/recall | MAP: {'motivation': 9, 'ability': 8, 'prompt': 10}", "decision_plan": {"primary_signal": "recall due: 6 month cleaning", "selected_lever": "certainty/urgency + specific appointment/recall", "recommended_action": "Reply YES to confirm, or send a better time.", "risk_flags": [], "rubric_scores": {"decision_quality": 10, "specificity": 9, "category_fit": 7, "merchant_fit": 10, "engagement_compulsion": 10}, "copy_strategy": "certainty_frame", "car_summary": {"merchant_id": "m_001_drmeera_dentist_delhi", "category": "dentists", "locality": "Lajpat Nagar", "active_offers": ["Dental Cleaning @ ₹299"], "performance_deltas": {"views_pct": "18%", "calls_pct": "-5%", "ctr_pct": "2%"}, "trigger_kind": "recall_due", "trigger_urgency": 3, "customer_stage": "lapsed_soft", "consent_state": "allowed", "last_action_type": "", "last_response_intent": "", "reflection_note": "", "category_arm_priors": {}}, "jitai_scores": {"severity": 10, "receptivity": 7, "intervention_fit": 9}, "map_scores": {"motivation": 9, "ability": 8, "prompt": 10}, "frame": "certainty_frame", "action_arm": "appointment_confirm", "variant_strategy": "certainty_frame", "persuasion_principle": "scarcity", "constitutional_violations": [], "thought_frames": [{"strategy": "certainty_frame", "frame": "certainty_frame", "principle": "scarcity", "action_arm": "appointment_confirm", "score": 27}, {"strategy": "social_proof", "frame": "social_proof", "principle": "scarcity", "action_arm": "appointment_confirm", "score": 26}, {"strategy": "effort_externalization", "frame": "effort_externalization", "principle": "scarcity", "action_arm": "appointment_confirm", "score": 24}], "reference_key": "dentists:engagement_compulsion", "constitution": ["No invented numbers; every figure must trace to supplied context.", "No generic phrases like increase sales, boost sales, or grow your business.", "Use one CTA only.", "Name a merchant, trigger, offer, metric, source, date, locality, or customer fact.", "Urgency must be tied to a concrete trigger, date, count, or deadline.", "Avoid repeating the same action type after weak engagement.", "Use peer-to-peer merchant language, not corporate partner language.", "For pharmacy customer cases without consent, route to merchant approval and avoid dispatch, dosage, or medical advice copy."], "evidence": [{"label": "merchant", "value": "Dr. Meera's Dental Clinic", "kind": "identity", "source": "merchant.identity", "weight": 2}, {"label": "owner", "value": "Meera", "kind": "identity", "source": "merchant.identity", "weight": 1}, {"label": "locality", "value": "Lajpat Nagar", "kind": "local", "source": "merchant.identity", "weight": 1}, {"label": "verified", "value": "True", "kind": "signal", "source": "merchant.identity", "weight": 2}, {"label": "car_locality", "value": "Lajpat Nagar", "kind": "local", "source": "merchant.car", "weight": 2}, {"label": "car_customer_stage", "value": "lapsed soft", "kind": "customer", "source": "merchant.car", "weight": 2}]}, "test_id": "T28"}
|
| 29 |
{"body": "Padma, recall due is due now. metric or topic: recall due; last visit: 2026-04-01; customer: Diya. Consent is not explicit for direct customer outreach, so I can draft a consent-safe approval note for you first. Reply YES and I will prepare the next step now.", "cta": "binary_yes_no", "send_as": "vera", "suppression_key": "recall_due:m_008_zenyoga_gym_chennai:gen_66", "rationale": "Trigger: recall_due | Key facts: total_active_members:95 + views_30d:880 | Frame: certainty_frame because trigger has a time window or deadline on recall_due | Principle: scarcity | Receptivity: 5/10 | Suppression: no - sent | Action: I can draft a consent-safe approval note for you first | Arm: appointment_confirm | Reference: gyms:engagement_compulsion | Lever: certainty/urgency + specific appointment/recall | MAP: {'motivation': 9, 'ability': 9, 'prompt': 9} | Risk flags: consent_missing, placeholder_trigger", "decision_plan": {"primary_signal": "recall due: recall due", "selected_lever": "certainty/urgency + specific appointment/recall", "recommended_action": "I can draft a consent-safe approval note for you first.", "risk_flags": ["consent_missing", "placeholder_trigger"], "rubric_scores": {"decision_quality": 10, "specificity": 9, "category_fit": 6, "merchant_fit": 8, "engagement_compulsion": 10}, "copy_strategy": "certainty_frame", "car_summary": {"merchant_id": "m_008_zenyoga_gym_chennai", "category": "gyms", "locality": "Mylapore", "active_offers": ["First Month @ ₹499", "Free Body Composition Analysis"], "performance_deltas": {"views_pct": "10%", "calls_pct": "15%"}, "trigger_kind": "recall_due", "trigger_urgency": 3, "customer_stage": "lapsed_soft", "consent_state": "missing_or_blocked", "last_action_type": "", "last_response_intent": "", "reflection_note": "", "category_arm_priors": {}}, "jitai_scores": {"severity": 9, "receptivity": 5, "intervention_fit": 9}, "map_scores": {"motivation": 9, "ability": 9, "prompt": 9}, "frame": "certainty_frame", "action_arm": "appointment_confirm", "variant_strategy": "certainty_frame", "persuasion_principle": "scarcity", "constitutional_violations": [], "thought_frames": [{"strategy": "certainty_frame", "frame": "certainty_frame", "principle": "scarcity", "action_arm": "appointment_confirm", "score": 26}, {"strategy": "social_proof", "frame": "social_proof", "principle": "social_proof", "action_arm": "appointment_confirm", "score": 25}, {"strategy": "effort_externalization", "frame": "effort_externalization", "principle": "social_proof", "action_arm": "appointment_confirm", "score": 23}], "reference_key": "gyms:engagement_compulsion", "constitution": ["No invented numbers; every figure must trace to supplied context.", "No generic phrases like increase sales, boost sales, or grow your business.", "Use one CTA only.", "Name a merchant, trigger, offer, metric, source, date, locality, or customer fact.", "Urgency must be tied to a concrete trigger, date, count, or deadline.", "Avoid repeating the same action type after weak engagement.", "Use peer-to-peer merchant language, not corporate partner language.", "For pharmacy customer cases without consent, route to merchant approval and avoid dispatch, dosage, or medical advice copy."], "evidence": [{"label": "merchant", "value": "Zen Yoga Studio", "kind": "identity", "source": "merchant.identity", "weight": 2}, {"label": "owner", "value": "Padma", "kind": "identity", "source": "merchant.identity", "weight": 1}, {"label": "locality", "value": "Mylapore", "kind": "local", "source": "merchant.identity", "weight": 1}, {"label": "verified", "value": "True", "kind": "signal", "source": "merchant.identity", "weight": 2}, {"label": "car_locality", "value": "Mylapore", "kind": "local", "source": "merchant.car", "weight": 2}, {"label": "car_customer_stage", "value": "lapsed soft", "kind": "customer", "source": "merchant.car", "weight": 2}]}, "test_id": "T29"}
|
| 30 |
+
{"body": "Dr. Meera, immediate action needed: DCI revised radiograph dose limits effective 2026-12-15 from Dental Council of India circular 2026-11-04. Maximum dose per IOPA exposure drops from 1.5 mSv to 1.0 mSv. E-speed film passes at the new limit; D-speed does not. Digital RVG sensors unaffected. For your Lajpat Nagar clinic, check whether the X-ray setup is E-speed or RVG before Dec 15; if not, flag the D-speed workflow before staff repeat it. A missed audit risks staff using the wrong film after the deadline. Peer signal: peer clinics post every 14 days while your posts are 22 days stale, and CTR is 2% vs peer 3%. The visible counter/profile line is: 'RVG/E-speed protocol checked'. Then use Dental Cleaning @ ₹299 as the patient hook only after that visible compliance line is ready.\n\nThe fastest win is a same-day checklist before staff repeat the old process.\n\nSay GO and I'll draft the 5-point SOP checklist plus patient-safe profile/counter note now.", "cta": "binary_yes_no", "send_as": "vera", "suppression_key": "compliance:dci_radiograph:2026", "rationale": "Trigger: regulation_change | Key facts: digest_title:DCI revised radiograph dose limits effective 2026-12-15 + high_risk_adult_count:124 | Frame: certainty_frame because trigger has a time window or deadline on regulation_change | Principle: scarcity | Receptivity: 7/10 | Suppression: no - sent | Action: draft the checklist plus customer note | Arm: deadline_action | Reference: dentists:engagement_compulsion | Lever: certainty/urgency + urgency + compliance risk | MAP: {'motivation': 9, 'ability': 8, 'prompt': 10}", "decision_plan": {"primary_signal": "regulation change: dentists", "selected_lever": "certainty/urgency + urgency + compliance risk", "recommended_action": "Want me to draft the checklist plus customer note?", "risk_flags": [], "rubric_scores": {"decision_quality": 10, "specificity": 10, "category_fit": 7, "merchant_fit": 9, "engagement_compulsion": 10}, "copy_strategy": "artifact_offer", "car_summary": {"merchant_id": "m_001_drmeera_dentist_delhi", "category": "dentists", "locality": "Lajpat Nagar", "active_offers": ["Dental Cleaning @ ₹299"], "performance_deltas": {"views_pct": "18%", "calls_pct": "-5%", "ctr_pct": "2%"}, "trigger_kind": "regulation_change", "trigger_urgency": 4, "customer_stage": "merchant_only", "consent_state": "not_applicable", "last_action_type": "", "last_response_intent": "", "reflection_note": "", "category_arm_priors": {}}, "jitai_scores": {"severity": 10, "receptivity": 7, "intervention_fit": 9}, "map_scores": {"motivation": 9, "ability": 8, "prompt": 10}, "frame": "certainty_frame", "action_arm": "deadline_action", "variant_strategy": "artifact_offer", "persuasion_principle": "scarcity", "constitutional_violations": [], "thought_frames": [{"strategy": "certainty_frame", "frame": "certainty_frame", "principle": "scarcity", "action_arm": "deadline_action", "score": 28}, {"strategy": "loss_frame", "frame": "loss_frame", "principle": "scarcity", "action_arm": "recovery_nudge", "score": 27}, {"strategy": "effort_externalization", "frame": "effort_externalization", "principle": "scarcity", "action_arm": "draft_the_patient_note_or_checklist", "score": 25}], "reference_key": "dentists:engagement_compulsion", "constitution": ["No invented numbers; every figure must trace to supplied context.", "No generic phrases like increase sales, boost sales, or grow your business.", "Use one CTA only.", "Name a merchant, trigger, offer, metric, source, date, locality, or customer fact.", "Urgency must be tied to a concrete trigger, date, count, or deadline.", "Avoid repeating the same action type after weak engagement.", "Use peer-to-peer merchant language, not corporate partner language.", "For pharmacy customer cases without consent, route to merchant approval and avoid dispatch, dosage, or medical advice copy."], "evidence": [{"label": "merchant", "value": "Dr. Meera's Dental Clinic", "kind": "identity", "source": "merchant.identity", "weight": 2}, {"label": "owner", "value": "Meera", "kind": "identity", "source": "merchant.identity", "weight": 1}, {"label": "locality", "value": "Lajpat Nagar", "kind": "local", "source": "merchant.identity", "weight": 1}, {"label": "verified", "value": "True", "kind": "signal", "source": "merchant.identity", "weight": 2}, {"label": "car_locality", "value": "Lajpat Nagar", "kind": "local", "source": "merchant.car", "weight": 2}, {"label": "car_customer_stage", "value": "merchant only", "kind": "customer", "source": "merchant.car", "weight": 2}]}, "test_id": "T30"}
|