Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add commands/markifact/markifact-mcp/diagnose-underperformergit clone --depth 1 https://github.com/markifact/markifact-mcpWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/commands/markifact/markifact-mcp/diagnose-underperformer)<a href="https://agentmods.dev/commands/markifact/markifact-mcp/diagnose-underperformer"><img src="https://agentmods.dev/badge/commands/markifact/markifact-mcp/diagnose-underperformer.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00064 | $0.01614 |
| Opus 5 | $0.00032 | $0.00807 |
| Sonnet 5 | $0.00013 | $0.00323 |
| Haiku 4.5 | $0.00006 | $0.00161 |
Grade A, and why
diagnose-underperformer scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 107 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Goal
Pull the right report, walk a structured decision tree, and hand the user a ranked list of likely causes with the specific next op to call to fix it. No writes — diagnosis only.
Inputs to confirm (batch)
- Account name (substring) — required.
- Target — campaign / ad set / ad name or ID — required.
- Date range — default last 14 days; if the entity is < 14 days old, use its lifetime.
- Comparison window (optional) — previous 14 days, for trend.
- Primary KPI — conversions / ROAS / CPA / CPL — required if the entity has a conversion goal.
Workflow
- Discover ops. For Google Ads:
gads_select_accounts,gads_list_report_fields,gads_get_report,gads_get_account_history. For Meta:meta_ads_select_accounts,meta_ads_list_report_fields,meta_ads_get_report,meta_ads_get_account_history,meta_ads_get_adset_settings,meta_ads_get_campaign_settings. - Inspect with
get_operation_inputs. Always call*_list_report_fieldsbefore*_get_report— never guess metric/dimension names. - Resolve account with substring match.
- Pull the report at the right granularity (campaign / ad set / ad). Required metrics:
- Spend, impressions, clicks, CTR, CPC, conversions, conv rate, CPA / ROAS, frequency (Meta), search impression share + lost-to-budget + lost-to-rank (Google Search).
- Pull settings/history to check for recent edits that could have triggered the dip:
- Google:
gads_get_account_historyfiltered to this campaign — look for budget changes, bid strategy switches, status flips, asset changes. - Meta:
meta_ads_get_campaign_settings/meta_ads_get_adset_settingsfor current state,meta_ads_get_account_historyfor recent changes.
- Google:
- Walk the decision tree below and rank the matching diagnoses by likelihood + impact.
- Present: top 3 diagnoses, evidence from data, and the exact next op to call (or the matching slash command). Do not run any write op.
Decision tree
Branch A — Low impressions / low spend (entity not delivering)
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 4d ago First seen · 107 lines · 64 tokens per session scan A 04f8b1816998
diagnose-underperformer is a command published in the GitHub repository markifact/markifact-mcp (48 stars, last pushed 16d ago), licensed MIT. It adds 64 tokens to every session and 1,614 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other commands, from other repositories
set-context
Set the client context so all subsequent analyses are automatically tailored — store client name, industry, size, geography, and key facts.
pricing-analysis
Run a comprehensive pricing analysis — assesses current pricing, analyzes competition, estimates willingness-to-pay, designs optimal pricing architecture, quantifies revenue impact, and builds an implementation roadmap.
ma-assessment
End-to-end M&A assessment playbook — combines due diligence, financial modeling, competitive analysis, and strategic evaluation for acquisition targets.
turnaround-playbook
End-to-end turnaround playbook — diagnoses performance issues, identifies cost savings, designs operational improvements, and builds an implementation plan.
growth-strategy
End-to-end growth strategy playbook — chains market research, competitive analysis, strategy frameworks, financial modeling, and deliverable creation into a complete growth strategy.
change-plan
Create a comprehensive change management plan for a transformation initiative.