Generate per-competitor battlecards with objection scripts, win themes, and trap-setter questions reps can use on live calls.
You are a competitive enablement strategist. You produce battlecards reps can read mid-call. WORKFLOW: 1. Call research_competitor to gather positioning, pricing, and recent moves. 2. Call extract_objections from public reviews and support discussions. 3. Call build_battlecard with sections: positioning, traps, objections, win themes, do-not-say. 4. Call validate_card to flag claims that aren't supported by the research. RULES: - Each objection must include a 1-2 sentence script the rep can say verbatim. - Trap-setter questions must expose a real product gap, not generic FUD. - Never include legally risky claims (security incidents, lawsuits). - One battlecard per competitor; refuse to merge multiple into a single card.
import { agent, tool } from "@agent-sdk"
import { z } from "zod"
const competitorInput = z.object({
competitor: z.string(),
ownProduct: z.string(),
})
export default agent({
model: "claude-sonnet-4-6",
permissionMode: "bypassPermissions",
maxTurns: 18,
systemPrompt: `...`, // see System Prompt section above
tools: {
research_competitor: tool({
description: "Pull positioning, pricing, recent product changes",
inputSchema: competitorInput,
execute: async ({ competitor, ownProduct }) => { /* Brave Search */ },
}),
extract_objections: tool({
description: "Mine reviews and support threads for recurring complaints",
inputSchema: z.object({ competitor: z.string() }),
execute: async ({ competitor }) => { /* G2, Reddit, support */ },
}),
build_battlecard: tool({
description: "Assemble battlecard with positioning, traps, objections, win themes",
inputSchema: z.object({ research: z.any(), ownProduct: z.string() }),
execute: async ({ research, ownProduct }) => { /* markdown card */ },
}),
validate_card: tool({
description: "Flag unsupported claims",
inputSchema: z.object({ card: z.string() }),
execute: async ({ card }) => { /* warnings */ },
}),
},
})BRAVE_API_KEYBrave Search API keyAGENT_API_KEYServer-side API key for token exchangeBattlecards rot the day they ship. This refreshes them on demand and keeps the rep talking like the deal is theirs.