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 skills/planetscale/claude-plugin/07-schema-recommendations-agent-loopnpx skills add planetscale/claude-plugin --skill 07-schema-recommendations-agent-loopgit clone --depth 1 https://github.com/planetscale/claude-pluginWrote 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/skills/planetscale/claude-plugin/07-schema-recommendations-agent-loop)<a href="https://agentmods.dev/skills/planetscale/claude-plugin/07-schema-recommendations-agent-loop"><img src="https://agentmods.dev/badge/skills/planetscale/claude-plugin/07-schema-recommendations-agent-loop.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.00037 | $0.00758 |
| Opus 5 | $0.00018 | $0.00379 |
| Sonnet 5 | $0.00007 | $0.00152 |
| Haiku 4.5 | $0.00004 | $0.00076 |
Grade A, and why
planetscale-schema-recommendations-agent-loop 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.
This is a copy
100% identical to planetscale-schema-recommendations-agent-loop — 0 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.
How it starts
The opening of the file, as written. The whole thing — 119 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Schema recommendations agent loop
Purpose
Use PlanetScale schema recommendations as high-quality input to agents. Convert recommendations into safe implementation plans, issues, branches, migrations, or pull requests. Do not apply recommendations directly.
Inputs
Collect:
- Open schema recommendations.
- Recommendation type.
- Affected table, keyspace, schema, and query pattern.
- Suggested DDL.
- Supporting Insights evidence.
- Application repository and migration system.
- Engine: Vitess or Postgres.
- Target branch.
Recommendation types to recognize
- Add index for inefficient query.
- Remove redundant index.
- Prevent primary key ID exhaustion.
- Drop unused table.
- Upgrade legacy charset or collation.
- Other DDL recommendation.
Triage questions
For each recommendation, answer:
- Is this still open and relevant?
- Which query patterns triggered it?
- Which application code paths generate those queries?
- Is the recommendation safely expressible in the application’s migration framework?
- Does the ORM/schema source of truth need to change?
- Can it be tested on a non-production branch?
- What is the expected impact on reads, writes, storage, and deploy time?
- Is there a rollback or revert path?
- Is there a competing recommendation or migration?
Engine-specific implementation path
Vitess
Recommended path:
- Create or use a development branch.
- Apply the schema change to that branch only after approval.
- Open a deploy request only after approval.
- Use deploy request review to inspect schema, shard impact, data-loss warnings, lint errors, and conflicts.
- Use normal safe migration path unless instant deployment is explicitly justified.
- Deploy only after approval.
- Monitor Insights and anomaly state after deployment.
Default output before approval: issue or PR with migration proposal, not a live deploy request.
Postgres
Recommended path:
- Convert DDL into the application’s migration framework where possible.
- Test against a non-production branch.
- Run application tests and relevant query checks.
- Open PR.
- Apply production migration only after approval.
- Use backups/PITR runbook as recovery plan, not as a substitute for migration review.
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 · 119 lines · 37 tokens per session scan A d94bfcc4e511
planetscale-schema-recommendations-agent-loop is a skill published in the GitHub repository planetscale/claude-plugin (4 stars, last pushed 3d ago), licensed Apache-2.0. It adds 37 tokens to every session and 758 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. It is 100% identical to planetscale-schema-recommendations-agent-loop, differing in 0 lines, and is treated as a copy.
Other skills, from other repositories
stale-sweep
Sweep the googleapis/mcp-toolbox repo for issues and PRs with no real activity in N days (default 60), sort each by whose silence it is (the author's, ours, or nobody's), and draft the nudge or close comment. Use whenever a maintainer asks for a stale sweep, backlog cleanup, or an SLO check, e.g. "stale sweep", "find…
skip-test-with-issue
Skip a flaky or broken test with proper issue tracking. Use when asked to skip a test, disable a test, or mark a test as flaky.
archive
Query the Switchboard plan archive — the SQLite cold store (kanban-archive.db) that holds plans aged out of the hot kanban board, plus the optional legacy DuckDB archive.
debug-failed-run
Debug a failed Activepieces flow run end-to-end: given a flow run id (or BullMQ job id), find why it failed, cross-referencing the live BullMQ job + Postgres rows (SSH script on the DevOps box), the centralized ClickHouse logs (ClickStack MCP), and the code in this repo, then categorize the failed-job backlog on…
ecosystem-intake
Use when monitoring a curated ecosystem source and you need to turn new items into concrete adopt/adapt/reject backlog candidates — combines GitHub-native reading with SQL triage and repository-fit scoring.
jira-operations
JIRA cache and performance operations. TRIGGERS: 'warm the cache', 'warm cache', 'cache status', 'clear cache', 'cache warm', 'cache for project', 'discover project', 'project discovery', 'cache hit rate', 'optimize performance', 'rate limit'. Use for JIRA API performance optimization and project context discovery.…