agentleFS
gomarble-aigomarble-ai/marketing-agent/skills/meta-performance-analysis/SKILL.md

meta-performance-analysis

Skill15 starsChanged 36 days agoMITView on GitHub

Use when analyzing Meta (Facebook/Instagram) ad performance: account type detection, Pareto analysis, baselines, performance thresholds, issue diagnosis.

The file

We split this skill into the rules it gives an agent

9 rules. About 0 are common, 4 are distinctive, and 5 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈4

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 5

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Read promoted_object.custom_event_type from the ad set to determine the Primary Conversion Metric (PCM).

    line 14
  2. Very specific:

    If promoted_object is missing: ASK the user which conversion event is the business outcome.

    line 24
  3. Distinctive:

    Keep ads where cumulative % ≤ 90% — these are your Pareto ads.

    line 30
  4. Very specific:

    CRITICAL: Always include ad.effective_status (or adset.effective_status) filter.

    line 46
  5. Distinctive:

    Check comments for negative sentiment

    line 65
  6. Distinctive:

    If comments fine: test copy/creative variations with stronger CTA

    line 66
  7. Very specific:

    Check frequency — see fatigue signal in tool-fundamentals → Diagnostic Signals

    line 69
  8. Distinctive:

    MANDATORY: After completing the analysis, generate specific, actionable recommendations for each Pareto ad and for the account overall.

    line 74
  9. Very specific:

    If not loaded, use the meta-creative-analysis skill.

    line 114

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Meta Ads - Performance Analysis Workflow

Metric definitions (CTR, CPM, ROAS, CPL, CPR, conversion rate, account-type → PCM mapping, performance benchmarks, Pareto definition) live in meta/tool-fundamentals and auto-load with this skill. Do NOT redefine them here. This skill is the workflow for performance audits after the metrics are loaded.

Step 1: Identify Account Type & PCM

Read promoted_object.custom_event_type from the ad set to determine the Primary Conversion Metric (PCM). The mapping table is in tool-fundamentals → Account Type → Primary Conversion Metric.

Where to read it:

  • facebook_get_details_of_ad_account → returns account_structure.adsets with promoted_object for top spending ad sets. Use this first.
  • facebook_get_adset_details → use when you need conversion events for ad sets not in the account structure.

PROHIBITED: Never extract or infer conversion events from names. Ad set names frequently don't match the actual config.

Mixed accounts: group ad sets by their custom_event_type. Each group gets its own PCM. Do not mix conversion types.

If promoted_object is missing: ASK the user which conversion event is the business outcome.

Step 2: Pareto Pull (90% Spend)

  1. Get ad-level insights sorted by spend descending.
  2. Calculate cumulative spend percentage for each ad.
  3. Keep ads where cumulative % ≤ 90% — these are your Pareto ads.
  4. Focus analysis on Pareto ads.

Query for Pareto ads (MUST include active status filter):

Tool: facebook_get_adaccount_insights
level: "ad"
fields: ["ad_name", "ad_id", "adset_id", "adset_name", "spend", "impressions", "cpm", "ctr", "clicks", "actions", "action_values", "purchase_roas"]
date_preset: "last_30d"
filtering: [
  {"field": "impressions", "operator": "GREATER_THAN", "value": 0},
  {"field": "ad.effective_status", "operator": "IN", "value": ["ACTIVE"]}
]
sort: "spend_descending"

CRITICAL: Always include ad.effective_status (or adset.effective_status) filter. Without it, the API returns data for paused/deleted entities that had historical spend, producing analysis that includes inactive entities. Fetch ALL pages before analyzing — ad-level results paginate at 25 per page (see tool-fundamentals → Pagination).

Step 3: Establish Baselines

From the Pareto set, compute:

  • avg_cpm = mean CPM across Pareto ads
  • avg_ctr = mean CTR across Pareto ads
  • avg_pcm = mean ROAS (e-commerce) or mean CPL/CPR (lead gen / custom) across Pareto ads

These become the comparison points for individual-ad assessment. Apply the variance benchmarks from tool-fundamentals → Performance Benchmarks.

Step 4: Diagnose Issues

High CPM + Low PCM:

  • Expensive audience, not converting
  • Action: pause ad or test different targeting

Low CTR + Low PCM:

  • Ad not resonating with audience
  • Check comments for negative sentiment
  • If comments fine: test copy/creative variations with stronger CTA

Good metrics but declining trend:

  • Check frequency — see fatigue signal in tool-fundamentals → Diagnostic Signals
  • Action: new creative variations, not just budget changes

Step 5: Generate Recommendations

MANDATORY: After completing the analysis, generate specific, actionable recommendations for each Pareto ad and for the account overall.

Per-Ad Recommendations

For each Pareto ad, based on its diagnostic profile:

  • What to do: specific action (pause, scale, create variation, change targeting)
  • Why: metrics-based justification (e.g., "CPM 40% above Pareto avg with 0.3× ROAS")
  • How: concrete next steps

Account-Level Recommendations

Summarize the top 3–5 strategic recommendations:

  1. Budget reallocation (shift spend from poor → good performers; respect guardrails)
  2. Creative strategy (what's working, what to test next)
  3. Targeting adjustments (if CPM issues are widespread)
  4. Structure changes (campaign / ad set consolidation if needed)

Output Format

## Performance Summary

| Ad | Format | Spend | CPM | CTR | ROAS/CPA | Status |
|----|--------|-------|-----|-----|----------|--------|
| [Name] | Image | $X | $X | X% | X | [Scale/Pause/Test] |

**Benchmarks (Pareto avg)**: CPM: $X | CTR: X% | ROAS: X

## Recommendations

### Per-Ad Actions
1. **[Ad Name]**: [Action] — [Justification]
2. **[Ad Name]**: [Action] — [Justification]

### Strategic Recommendations
1. [Actionable recommendation with metrics basis]
2. [Actionable recommendation with metrics basis]
3. [Actionable recommendation with metrics basis]

If creative analysis is needed (video performance, hook rates, ad copy evaluation):

  • The Creative Analysis skill should already be loaded for audits.
  • If not loaded, use the meta-creative-analysis skill.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.