> ## Documentation Index
> Fetch the complete documentation index at: https://docs.permutive.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Optimizing a campaign in flight

> Review how a live campaign is delivering by targeted cohort, check its reach against the booking, and find cohorts to extend it.

export const RailStep = ({step, title, note = '', docLink = '', docPages = '', docTitle = 'From the brief — highlighted for this page', docWide = false}) => <li className={step === '1' ? 'agent-chat-rail-step is-active' : 'agent-chat-rail-step'} data-step={step}>
    <a className="agent-chat-note-title" href={`#step-${step}`}>{title}</a>
    <div className="agent-chat-note-body">
      <div>
        {note.split('`').map((part, i) => i % 2 === 1 ? <a key={i} href={`/api/mcp/${part}`}><code>{part}</code></a> : <span key={i}>{part}</span>)}
        {docLink && <button type="button" className="agent-chat-doc-link" popovertarget={`doc-step-${step}`}>
            {docLink} →
          </button>}
      </div>
    </div>
    {docLink && <div id={`doc-step-${step}`} popover="auto" className={docWide ? 'agent-chat-document agent-chat-document-annotated agent-chat-document-wide' : 'agent-chat-document agent-chat-document-annotated'}>
        <div className="agent-chat-document-header">
          <span>{docTitle}</span>
          <button type="button" popovertarget={`doc-step-${step}`} popovertargetaction="hide" aria-label="Close">✕</button>
        </div>
        <div className="agent-chat-document-pages">
          {docPages.split(';').map(src => src.trim()).filter(Boolean).map((src, i) => <img key={src} src={src} alt={`${docTitle}, part ${i + 1}`} noZoom />)}
        </div>
      </div>}
  </li>;

export const StepRail = ({children}) => <aside className="agent-chat-rail" aria-label="Steps">
    <ol className="agent-chat-rail-list">{children}</ol>
  </aside>;

export const ResponsePart = ({step, title, children}) => <section id={`step-${step}`} className="agent-chat-turn agent-chat-part" data-turn-step={step}>
    <div className="agent-chat-turn-label">{step}. {title}</div>
    {children}
  </section>;

export const AnnotatedTurn = ({step, title, children}) => <section id={`step-${step}`} className="agent-chat-turn" data-turn-step={step}>
    <div className="agent-chat-turn-label">{step}. {title}</div>
    {children}
  </section>;

export const AnnotatedConversation = ({children}) => <div className="agent-chat-conversation">{children}</div>;

export const ResponseFull = ({children}) => <details className="agent-chat-full">
    <summary></summary>
    <div className="agent-chat-full-body">{children}</div>
  </details>;

export const ResponseExcerpt = ({children}) => <div className="agent-chat-excerpt">{children}</div>;

export const AgentResponse = ({tools = '', skill = '', children}) => <div className="agent-chat-agent">
    {skill && <div className="agent-chat-tools">
        Using skill: <code>{skill}</code>
      </div>}
    {tools && <div className="agent-chat-tools">
        Used Permutive MCP
        {tools.split(',').map(t => t.trim()).filter(Boolean).map((tool, i) => <span key={tool}>
            {i === 0 ? ': ' : ', '}
            <a href={`/api/mcp/${tool}`}><code>{tool}</code></a>
          </span>)}
      </div>}
    <div className="agent-chat-body">{children}</div>
  </div>;

export const UserPrompt = ({children}) => <div className="agent-chat-user">
    <div className="agent-chat-user-bubble">{children}</div>
  </div>;

<Note>
  The Permutive MCP server is in a **testing phase with partnering customers**.
  Access is invitation-only and the tool interfaces may change. If you would like
  access, please contact your Permutive representative.
</Note>

## Scenario

A campaign is live and your ad-ops team needs to know how it's delivering and
optimize it to meet the booked requirements.

Normally, you would export delivery reports from Google Ad Manager, work out in a
spreadsheet which targeted cohorts are driving results, check whether the
targeting can still reach what the advertiser booked, and search through your
cohorts for ones to extend it with.

## How the Permutive MCP server powers the agent

With the Permutive MCP server, your agent is able to automate this by:

* **Review your campaigns** — campaign delivery from Google Ad Manager is
  available to the agent, so you can list and filter campaigns without leaving
  the conversation
* **Analyze performance by cohort** — impressions, CTR and viewability for each
  targeted cohort show which audiences are driving results, and which are just
  taking delivery
* **Close reach gaps** — the agent measures current reach against the booking,
  and finds cohorts that correlate with the audience you're already reaching,
  with the overlap, index and net-new users for each

## Example conversation

<AnnotatedConversation>
  <StepRail>
    <RailStep step="1" title="List your campaigns" note="Start with what's running. Campaign delivery comes from Google Ad Manager, so you don't need to open it to see what's live." />

    <RailStep step="2" title="The agent lists your campaigns" note="The agent uses `list_campaigns`. By default it returns campaigns that use Permutive targeting, and the agent says so." />

    <RailStep step="3" title="Ask how a campaign is performing" note="Name the campaign and the metrics you care about, broken down by targeted cohort." />

    <RailStep step="4" title="The agent breaks down delivery by cohort" note="`get_campaign` returns impressions, CTR and viewability for each targeted cohort, with each cohort's share of delivery and its CTR against the campaign average." />

    <RailStep step="5" title="The agent spots inverted delivery" note="The agent doesn't just report the figures. It points out that delivery is inverted: the smallest cohort has the best CTR, while the endemic Auto Intenders cohort takes most of the impressions — and checks there's audience to shift weight towards." />

    <RailStep step="6" title="Check reach against the booking" note="Give the booked reach and say what to do if targeting falls short. Asking for non-endemic cohorts steers the agent beyond the campaign's own category." />

    <RailStep step="7" title="The agent measures the gap" note="The agent measures the current targeting with `measure_audiences`, restricted to the US: 2.57M users, about 429k short of the booking — and confirms there's no US activity to draw on from other workspaces." />

    <RailStep step="8" title="The agent finds correlated cohorts" note="`find_audience_extensions` and `compare_audience` find cohorts outside automotive and finance whose users index highly against the audience already being reached, with the net-new users each would add." />

    <RailStep step="9" title="The agent recommends a combination" note="Rather than stopping at the first cohort that clears 3M, the agent sizes a combination with a 19% buffer, and explains why it adds new users rather than repeating existing ones." />

    <RailStep step="10" title="The agent explains what to avoid" note="The agent reuses the step 5 finding — narrow cohorts outperform — to argue against the obvious high-volume pick, then flags its caveats and offers to check each cohort's track record." />
  </StepRail>

  <AnnotatedTurn step="1" title="List your campaigns">
    <UserPrompt>
      Give me a list of my campaigns in Permutive, show their name and if they are live
    </UserPrompt>
  </AnnotatedTurn>

  <AnnotatedTurn step="2" title="The agent lists your campaigns">
    <AgentResponse tools="get_orgs_and_workspaces, list_campaigns">
      You have 3 Permutive-targeted campaigns across your Quorrane Media workspaces:

      | Campaign | Live? |
      | - | - |
      | Meridian Motors — Electric SUV Launch | Yes |
      | Coastline Holidays — Late Summer Breaks | Yes |
      | Summit Sportswear — Playoff Series | No |

      This only covers campaigns using Permutive targeting. Let me know if you'd like all GAM campaigns included, or delivery figures alongside each one.
    </AgentResponse>
  </AnnotatedTurn>

  <AnnotatedTurn step="3" title="Ask how a campaign is performing">
    <UserPrompt>
      Let's look at how Meridian Motors is performing — show me impressions, CTR
      index and viewability by targeted cohort.
    </UserPrompt>
  </AnnotatedTurn>

  <AgentResponse tools="get_campaign">
    <ResponsePart step="4" title="The agent breaks down delivery by cohort">
      **Meridian Motors — Electric SUV Launch** (live)

      Campaign totals: 4.25M impressions, 0.42% CTR, 71.3% viewability.

      | Targeted cohort | Impressions | Share | CTR | CTR index | Viewability |
      | - | - | - | - | - | - |
      | Auto Intenders — regular readers (7d) | 1.88M | 44% | 0.48% | 1.14 | 73% |
      | Household income \$100k+ | 1.45M | 34% | 0.61% | 1.45 | 75% |
      | Finance & Investing — regular readers (7d) | 640k | 15% | 0.74% | 1.76 | 70% |
    </ResponsePart>

    <ResponsePart step="5" title="The agent spots inverted delivery">
      The pattern is inverted against delivery: the smallest cohort performs best. Finance & Investing is pulling 76% above the campaign average CTR on only 15% of impressions, while Auto Intenders — the obvious endemic pick and the biggest slice at 44% — is barely above average at 1.14.

      Worth noting Auto Intenders only has available users in Quorrane Media US (1.6M), whereas the other two cohorts reach across all four workspaces. So there's headroom to shift weight toward Finance & Investing and \$100k+ without running out of audience. Want me to size what a reweighted mix would reach, or check the line items behind that Auto Intenders skew?
    </ResponsePart>
  </AgentResponse>

  <AnnotatedTurn step="6" title="Check reach against the booking">
    <UserPrompt>
      Meridian have booked this for 3 million unique users in the US.

      Can our current targeting reach that? If not, find me non-endemic cohorts that
      correlate with the audience we're already reaching.
    </UserPrompt>
  </AnnotatedTurn>

  <AgentResponse tools="get_workspace_details, measure_audiences, find_audience_extensions, compare_audience">
    <ResponsePart step="7" title="The agent measures the gap">
      Current targeting is short of the booking. Let me get reportable figures on the best non-automotive candidates.

      **No — current targeting reaches 2.57M US users, about 429k short**

      Measured over the last 30 days in Quorrane Media US, restricted to USA activity:

      | Cohort | US unique users |
      | - | - |
      | Auto Intenders — regular readers (7d) | 1,273,750 |
      | Finance & Investing — regular readers (7d) | 812,000 |
      | Household income \$100k+ | 732,500 |
      | **Combined (deduplicated)** | **2,570,750** |

      That's 86% of the 3M booking. Worth noting all US-side reach sits in the US workspace — the EU and APAC workspaces have no USA activity at all, so there's nothing to pull in from elsewhere in the org.
    </ResponsePart>

    <ResponsePart step="8" title="The agent finds correlated cohorts">
      **Non-endemic extensions**

      These correlate with the audience you're already reaching but sit outside automotive and finance content. Index is relative to the average US user in the workspace:

      | Cohort | Users | Index | Net-new users | Overlap with seed |
      | - | - | - | - | - |
      | Travel Enthusiasts — regular readers (7d) | 696,500 | 1.93 | +491,000 | 8.0% |
      | Frequent Shoppers — enthusiasts | 271,250 | 1.74 | +199,250 | 2.8% |
      | Frequent Shoppers — frequent visitors | 479,000 | 1.57 | +364,000 | 4.5% |
      | College educated | 1,024,250 | 1.49 | +791,000 | 9.1% |
      | Frequent Shoppers — regular readers (7d) | 745,000 | 1.44 | +581,000 | 6.4% |
      | Household income \$50k–\$100k | 558,000 | 1.39 | +439,750 | 4.6% |
      | Empty nesters | 456,000 | 1.36 | +361,500 | 14.1% |
    </ResponsePart>

    <ResponsePart step="9" title="The agent recommends a combination">
      Travel Enthusiasts is the standout: highest affinity of anything non-automotive in the library, and on its own it clears the booking — adding it takes deduplicated reach to **3,061,750**. That's a thin 2% margin though.

      For more headroom, adding Travel Enthusiasts plus both narrower Frequent Shoppers cohorts gets you to **3,580,750**, a 19% buffer. Frequent Shoppers indexes well (1.57–1.74) and overlaps the seed very little, so it's genuinely additive rather than repeating users you already have.
    </ResponsePart>

    <ResponsePart step="10" title="The agent explains what to avoid">
      I'd steer away from College educated despite the volume — index 1.49 is respectable but it's a broad demographic cohort, and given the campaign's pattern so far (the narrowest cohort, Finance & Investing, is outperforming on CTR at 1.76 index while broad Auto Intenders lags at 1.14), volume from a broad cohort is likely to drag CTR down.

      Two caveats on the above: the reach figures are a 30-day window against a campaign that is still running, and the Frequent Shoppers estimates came back at lower confidence than the others, so treat their exact numbers as indicative. If you want, I can check whether Travel Enthusiasts or Frequent Shoppers have a targeted track record on your past campaigns before you commit.
    </ResponsePart>
  </AgentResponse>
</AnnotatedConversation>

## Tips

* **Ask for non-endemic cohorts**: Saying "non-endemic" steers the agent away
  from more of the same category, towards audiences that behave like yours but
  sit outside it.
* **Give the target you're working to**: Stating the booked reach lets the agent
  measure the gap and tell you how much headroom each option leaves.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.