.claude/skills/ts-alert-optimizer/SKILL.md
Restructure and optimize alert rules for monitoring platforms (Sentry, PagerDuty, Datadog, OpsGenie). Use when someone asks to "reduce alert noise", "fix alert fatigue", "create alert rules", "set up escalation policies", "tune alerting thresholds", or "create on-call runbooks". Generates platform-specific alert configurations and tiered escalation policies.
npx skillsauth add eliferjunior/Claude alert-optimizerInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
This skill takes error analysis data (ideally from the error-monitoring skill) and generates optimized alert rules, severity tiers, escalation policies, and on-call runbooks. It turns a noisy alerting setup into a structured incident response system.
Ask for or infer:
Create a three-tier model (unless the user specifies otherwise):
| Tier | Criteria | Response Time | Channel | |------|----------|---------------|---------| | P1 - Critical | Revenue impact, data loss, security breach, >50% users affected | Immediate page | PagerDuty/SMS | | P2 - Warning | Degraded experience, >5% users affected, error rate spike | 1 hour | Slack channel | | P3 - Info | Known issues, cosmetic errors, self-healing transients | Weekly review | Log only |
For each error group, produce a platform-specific alert configuration:
Define who gets notified and when:
For each P1 alert, create a runbook with:
Input: Error audit showing PaymentProcessingError as P1, RedisTimeout as P3.
Output:
{
"rules": [
{
"name": "P1: Payment Processing Failure",
"conditions": [
{"id": "sentry.rules.conditions.event_frequency", "value": 1, "interval": "5m"}
],
"filters": [
{"id": "sentry.rules.filters.tagged_event", "key": "error_type", "value": "PaymentProcessingError"}
],
"actions": [
{"id": "sentry.integrations.pagerduty.notify_action", "service": "engineering-oncall"},
{"id": "sentry.integrations.slack.notify_action", "channel": "#incidents", "tags": "environment,transaction"}
],
"frequency": 5
},
{
"name": "P3: Redis Connection Timeout (Log Only)",
"conditions": [
{"id": "sentry.rules.conditions.event_frequency", "value": 100, "interval": "1h"}
],
"filters": [
{"id": "sentry.rules.filters.tagged_event", "key": "error_type", "value": "TimeoutError"}
],
"actions": [],
"frequency": 1440
}
]
}
Input: P1 alert for database deadlocks.
Output:
## RUNBOOK: Database Deadlock Detected
**Alert**: DatabaseError: deadlock detected in order processing
**Severity**: P1 — Revenue impact, orders fail silently
**Response**: Immediate — acknowledge within 5 minutes
### Diagnose
1. Check current DB connections: `SELECT * FROM pg_stat_activity WHERE state = 'active' ORDER BY query_start;`
2. Identify locked queries: `SELECT * FROM pg_locks WHERE NOT granted;`
3. Check if deployment happened in last 30 min (new query pattern?)
### Common Fixes
- Kill the blocking query: `SELECT pg_terminate_backend(<pid>);`
- If recurring post-deploy: rollback last migration
- If load-related: enable connection pooling or add read replica
### Escalate
- If not resolved in 15 min → page team lead
- If data corruption suspected → page engineering manager + DB admin
development
Expert guidance for Fireworks AI, the platform for running open-source LLMs (Llama, Mixtral, Qwen, etc.) with enterprise-grade speed and reliability. Helps developers integrate Fireworks' inference API, fine-tune models, and deploy custom model endpoints with function calling and structured output support.
development
Convert any website into clean, structured data with Firecrawl — API-first web scraping service. Use when someone asks to "turn a website into markdown", "scrape website for LLM", "Firecrawl", "extract website content as clean text", "crawl and convert to structured data", or "scrape website for RAG". Covers single-page scraping, full-site crawling, structured extraction, and LLM-ready output.
tools
Expert guidance for Firebase, Google's platform for building and scaling web and mobile applications. Helps developers set up authentication, Firestore/Realtime Database, Cloud Functions, hosting, storage, and analytics using Firebase's SDK and CLI.
development
When the user needs to build file upload functionality for a web application. Use when the user mentions "file upload," "image upload," "upload endpoint," "multipart upload," "presigned URL," "S3 upload," "file validation," "upload to cloud storage," or "accept user files." Handles upload endpoints, file validation (type, size, magic bytes), cloud storage integration, and upload status tracking. For image/video processing after upload, see media-transcoder.