TL;DR: This 6-step prompt chain takes raw AR and CRM data, calculates a priority score for collections, drafts personalized dunning emails, and generates a CFO-ready dashboard.
The Breakdown
Managing unpaid invoices usually involves juggling messy spreadsheets and subjective decisions about who to contact first. The creator, u/Prestigious-Tea-6699, designed a prompt chain that acts as a full-stack finance department to solve this. It doesn’t just format data; it applies logic to determine which debts are actually risky.
The workflow operates in distinct stages:
- Data Cleaning: It standardizes two different data sources (Aging reports and CRM health) into clean tables.
- Scoring Logic: It applies a specific formula to calculate a “Collection Priority Score” based on due dates, dispute risks, and customer health.
- Action Planning: It segments accounts into priority bands (Critical, High, Medium, Low).
- Execution: It drafts the actual emails you need to send.
- Reporting: It summarizes the financial exposure for leadership.
Use Cases and Variations
This approach uses Persona Switching. By telling the AI to act as a “Senior AR Analyst,” then a “Data Scientist,” and finally a “Copywriter,” the author ensures the tone and output change appropriately for each step.
Why it works:
- Explicit Constraints: The prompt uses mathematical formulas (e.g., `Aging_Score = Days Past Due / 90`) rather than asking the AI to “guess” priority.
- Variable Definitions: Defining `[COMPANY_NAME]` and data inputs at the top prevents confusion later in the chain.
Try these variations:
- Adjust the Weights: If your company cares more about churn than disputes, change the multiplier in step 3 (e.g., `Health_Adjust * 0.5`).
- Change the Output: Ask the “Collections Team Lead” to generate a Slack update for the sales team instead of a list for the CFO.
Prompt of the Day
Here is the exact prompt chain provided by the author. Note that the tildes (`~`) represent breaks where you might need to pause or run the next section if your LLM doesn’t support long chains automatically.
Prompt:
VARIABLE DEFINITIONS
[COMPANY_NAME]=Name of the company whose receivables are being analyzed
[AR_AGING_DATA]=Latest detailed AR aging report (customer, invoice ID, amount, age buckets, etc.)
[CRM_HEALTH_DATA]=Customer-health metrics from CRM (engagement score, open tickets, renewal date & value, churn risk flag)
You are a senior AR analyst at [COMPANY_NAME].
Objective: Standardize and validate the two data inputs so later prompts can merge them.
Steps:
- Parse [AR_AGING_DATA] into a table with columns: Customer Name, Invoice ID, Invoice Amount, Currency, Days Past Due, Original Due Date.
- Parse [CRM_HEALTH_DATA] into a table with columns: Customer Name, Engagement Score (0-100), Open Ticket Count, Renewal Date, Renewal ACV, Churn Risk (Low/Med/High).
- Identify and list any missing or inconsistent fields required for downstream analysis; flag them clearly.
- Output two clean tables labeled “Clean_AR” and “Clean_CRM” plus a short note on data quality issues (if any). Request missing data if needed.
Example output structure:
Clean_AR: |Customer|Invoice ID|Amount|Currency|Days Past Due|Due Date|
Clean_CRM: |Customer|Engagement|Tickets|Renewal Date|ACV|Churn Risk|
Data_Issues: • None found
You are now a credit-risk data scientist.
Goal: Generate a composite “Collection Priority Score” for each overdue invoice.
Steps:
- Join Clean_AR and Clean_CRM on Customer Name; create a combined table “Joined”.
- For each row compute:
- Aging_Score = Days Past Due / 90 (cap at 1.2).
- Dispute_Risk_Score = min(Open Ticket Count / 5, 1).
- Renewal_Weight = if Renewal Date within 120 days then 1.2 else 0.8.
- Health_Adjust = 1 ‑ (Engagement Score / 100).
- Collection Priority Score = (Aging_Score * 0.5 + Dispute_Risk_Score * 0.2 + Health_Adjust * 0.3) * Renewal_Weight.
- Add qualitative Priority Band: “Critical” (>=1), “High” (0.7-0.99), “Medium” (0.4-0.69), “Low” (<0.4).
- Output the Joined table with new scoring columns sorted by Collection Priority Score desc.
You are a collections team lead.
Objective: Segment accounts and assign next best action.
Steps:
- From the scored table select top 20 invoices or all “Critical” & “High” bands, whichever is larger.
- For each selected invoice provide: Customer, Invoice ID, Amount, Days Past Due, Priority Band, Recommended Action (Call CFO / Escalate to CSM / Standard Reminder / Hold due to dispute).
- Group remaining invoices by Priority Band and summarize counts & total exposure.
- Output two sections: “Action_List” (detailed) and “Backlog_Summary”.
You are a professional dunning-letter copywriter.
Task: Draft personalized outreach templates.
Steps:
- Create an email template for each Priority Band (Critical, High, Medium, Low).
- Personalize tokens: {{Customer_Name}}, {{Invoice_ID}}, {{Amount}}, {{Days_Past_Due}}, {{Renewal_Date}}.
- Tone: Firm yet customer-friendly; emphasize partnership and upcoming renewal where relevant.
- Provide subject lines and 2-paragraph body per template.
Output: Four clearly labeled templates.
You are a finance ops analyst reporting to the CFO.
Goal: Produce an executive dashboard snapshot.
Steps:
- Summarize total AR exposure and weighted average Days Past Due.
- Break out exposure and counts by Priority Band.
- List top 5 customers by exposure with scores.
- Highlight any data quality issues still open.
- Recommend 2-3 strategic actions.
Output: Bullet list dashboard.
Review / Refinement
Please verify that:
- All variables were used correctly and remain unchanged.
- Output formats match each prompt’s specification.
- Data issues (if any) are resolved or clearly flagged.
If any gap exists, request clarification; otherwise, confirm completion.
If you found this workflow helpful, check out the full discussion on Reddit.
Streamline your collection process with this powerful prompt chain. Prompt included.
by u/Prestigious-Tea-6699 in ChatGPTPromptGenius