
Meta Ad Library + Claude Code: how I built a competitor positioning scraper, what the 18-column taxonomy looks like, and what I broke first.
I built a Meta Ad Library scraper for competitor positioning research. Pulls every active creative from a competitor's page, then runs Claude Code as a subprocess to classify each ad through an 18-column taxonomy (offer type, hook style, claim, CTA, audience signal, format, etc).
Output is a table you can read in 10 minutes. Tells you what story a competitor is paying to tell, on which audience, with which hooks. The Meta Ad Library is free and legally scrapeable. Most operators either don't know it exists or clicked through once and bounced because reading 400 ads by hand is brutal.
Pushed it as Chapter 15 of an open repo I'm building called gtm-coding-agent. Repo is a set of GTM workflows you can run from a CLAUDE.md file plus a script.
Direct link to the chapter: github.com/shawnla90/gtm-coding-agent/blob/main/chapters/15-meta-ad-intelligence.md
Four mistakes I made first, posting because they'll save you a weekend:
Multiplexing the classifier across multiple competitors in one pass. Output degrades fast. The classifier confuses which company a creative belongs to and starts attributing the wrong claims. One pass, one competitor, every time.
Going broad on scope. Pointing it at "all CRM vendors" produces a mess that tells you nothing actionable. One competitor, one campaign theme per pass.
Trusting the full 18-column taxonomy. The first time I ran it I realized only six columns were actually shaping a decision. The other twelve were taxonomy padding. Cut what you don't use. Ask Claude how to adapt it for your category.
Scaling before evaluating. Run it once on a competitor you know cold. Sanity check the table against what you already know. Then scale to ones you don't.
Claude Code as a subprocess is a pattern that took me a while to land on. The agent is not writing the analysis. It is running classification at scale. The judgment call about what to do with the table is still operator work. That distinction is the whole reason it works.
Shawn Tenam
Repo is public. Onboarding asks six questions and routes you to a chapter that matches your role:
git clone https://github.com/shawnla90/gtm-coding-agent.git ~/gtm-coding-agent
cd ~/gtm-coding-agent
claude
> help me set up
Happy to answer questions or take feature requests. or If you've built something similar I'd want to compare notes on taxonomy structure.