Auto-build a deal battlecard from past wins and losses

By General Input

When a deal reaches qualification, your rep gets a short brief on the closest past deals, what won or lost them, and which case studies to send.

Integrations

  • Pinecone
  • HubSpot
  • Slack

Type

Agentic Task

Categories

  • Sales

When a deal in HubSpot moves into a qualification stage, I want an agent to build a short battlecard for whoever owns it. Trigger this from a HubSpot webhook on deal stage changes, and only continue when the new stage is one of my qualification stages. Ignore stage changes that move a deal anywhere else.

Start by pulling the record with Get Deal using the deal ID from the webhook payload. Read the deal name, the associated company, the amount, the current stage and the owner. If industry is not set on the deal itself, follow the associated company and read it with Get Company. Resolve the owner with Get Owner so you have their name and email address.

Then search my Pinecone index of past closed deal notes, win/loss write-ups and case studies with Search Records to find the most similar deals we have already run. Build the query text out of what you just read: company name, industry, deal size, and anything else on the record that describes the shape of the deal. Ask for around ten matches and use reranking so the strongest comparisons come back first.

Only cite a past deal if its similarity score is above a threshold I can adjust. Default the threshold to 0.75 and put it somewhere obvious at the top of the workflow so I can tune it without digging through the logic. Discard everything below the threshold rather than demoting it to a weak mention. If nothing clears the threshold, say plainly that we have no close comparison for this deal in the index and stop there instead of stretching a weak match into false confidence. A brief that tells me there is no precedent is more useful than one that confidently cites a deal that is not really similar.

Write the battlecard as short plain text, no more than about 300 words. Cover which past deals resemble this one and why, what won or lost each of them, the objections that came up and how they were handled, and the two case studies worth sending to this buyer. Name every past deal you cite and note how close the match is, so the rep can judge the evidence rather than taking the summary on trust.

Attach the finished brief to the deal with Create Note, associated with the deal record so it shows up on the timeline. Then send the same text to the deal owner in Slack: open a direct message channel to them with Open a Conversation and post the brief with Send a Message, including a link back to the deal in HubSpot. If the owner cannot be matched to a Slack member, fall back to posting the brief in a sales channel I name and mention the owner by name in the text.

Assume the Pinecone index is already populated with past deal notes, win/loss write-ups and case studies. This workflow only reads from the index, it should never write back to it.

Related prompts

Explore more prompts
Call overdue Xero customers with an AI collections agentWin back LiveChat visitors whose chats went unansweredTurn Mailjet email clicks into ranked HubSpot follow-upsiMessage campaign console with pre-flight checks and delivery boardChat quality review board for LiveChat support leadsA searchable RFP answer library your bid team drafts fromSee which target accounts just started advertising on LinkedInAccount health board that puts product usage next to your CRMLook up a customer's full chat history mid conversationLusha prospecting workbench with credit-safe reveals