prometheus
Skill15 starsChanged 42 days agoMITView on GitHub
Expert Prometheus monitoring assistance covering PromQL, metric types (Counter, Gauge, Histogram), scrape configs, and Alertmanager. Use when collecting and querying operational metrics across microservices.
9 other projects use a version of this.
Adopted by
Most recently taken up by
- CloudChef/atlasclaw-providerstheir own version, first seen Nov 8, 2026
- MidnightDarling/collatetheir own version, first seen Nov 1, 2026
- grafana/skillstheir own version, first seen Oct 27, 2026
- Egoushka/agent-skillstheir own version, first seen Sep 26, 2026
- Samuele95/prometheustheir own version, first seen Jul 25, 2026
- addxai/enterprise-harness-engineeringtheir own version, first seen Apr 17, 2026
Other versions9 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 9
- grafana/skills★ 302same name
- addxai/enterprise-harness-engineering★ 44same name
- CloudChef/atlasclaw-providers★ 17same name
- wpank/ai★ 11same name
- Samuele95/prometheus★ 10same name
- MidnightDarling/collate★ 8same name
- ffsshhttiikk/opencode-agents-skills★ 2same name
- isYaoNoistu/claudecode-skills★ 1same name
- Egoushka/agent-skills★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository350 other files it gives its agents.
- airflowSkill
- catboostSkill
- claudeSkill
- comfyuiSkill
- cursor-aiSkill
- dalleSkill
- daskSkill
- dbtSkill
- deepseekSkill
- fastaiSkill
- geminiSkill
- github-copilotSkill
- huggingfaceSkill
- jaxSkill
- jupyterSkill
- kerasSkill
- langchainSkill
- lightgbmSkill
- llamaindexSkill
- llamaSkill
- matplotlibSkill
- midjourneySkill
- mistralSkill
- mlflowSkill
- nltkSkill
- numpySkill
- ollamaSkill
- openai-gptSkill
- opencvSkill
- pandasSkill
- perplexitySkill
- plotlySkill
- polarsSkill
- pytorchSkill
- raySkill
- scikit-learnSkill
- seabornSkill
- spacySkill
- sparkSkill
- stable-diffusionSkill
- tensorflowSkill
- vaexSkill
- weights-biasesSkill
- whisperSkill
- xgboostSkill
- api-gatewaySkill
- clean-architectureSkill
- cqrsSkill
- domain-driven-designSkill
- event-drivenSkill
- event-sourcingSkill
- graphqlSkill
- grpcSkill
- hexagonalSkill
- microservicesSkill
- modular-monolithSkill
- monolithSkill
- rest-apiSkill
- sagaSkill
- serverlessSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
2 rules. 0 are common, 0 are distinctive, and 2 are very specific to this project.
0
Common
Most of the 5 edited versions we read keep these.
0
Distinctive
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 125
Use kubernetes_sd_configs with metric path annotations:
- Very specific: line 154
Use recording rules (record: job:metric:rate5m) for complex PromQL expressions queried by dashboards.
“Common” is measured: kept by at least 6 in 10 of the 5 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Prometheus
Prometheus is the CNCF graduated monitoring and alerting toolkit, featuring a multi-dimensional data model with time-series metrics, PromQL, and native OpenTelemetry ingestion.
When to Use
- Cloud-Native Time-Series Monitoring: Scraping, storing, and querying numerical metrics from infrastructure and applications.
- PromQL Quantitative Querying: Computing request rates, 99th percentile latencies, error ratios, and saturations.
- Automated Service Discovery: Dynamically discovering Kubernetes pods, EC2 instances, and Consul nodes to scrape.
- Alerting Rules & Alertmanager Integration: Evaluating threshold rules and dispatching alerts to on-call engineers.
Quick Start
# prometheus.yml
global:
scrape_interval: 15s
scrape_configs:
- job_name: "node"
static_configs:
- targets: ["localhost:9100"]Core Concepts
Prometheus Scrape Configuration (prometheus.yml)
Configuring scrape jobs with relabeling:
global:
scrape_interval: 15s
evaluation_interval: 15s
rule_files:
- "alert_rules.yml"
scrape_configs:
- job_name: "prometheus"
static_configs:
- targets: ["localhost:9090"]
- job_name: "api-microservices"
scrape_interval: 10s
metrics_path: "/metrics"
kubernetes_sd_configs:
- role: pod
namespaces:
names: ["production"]
relabel_configs:
- source_labels: [__meta_kubernetes_pod_annotation_prometheus_io_scrape]
action: keep
regex: "true"
- source_labels: [__meta_kubernetes_pod_container_port_number]
action: keep
regex: "8080"Production Alerting Rules (alert_rules.yml)
Defining SLO-based alert thresholds:
groups:
- name: API_SLO_Alerts
rules:
- alert: HighHttpErrorRate
expr: |
(
sum(rate(http_requests_total{status=~"5.."}[5m]))
/
sum(rate(http_requests_total[5m]))
) * 100 > 5
for: 2m
labels:
severity: critical
annotations:
summary: "High HTTP 5xx error rate on {{ $labels.service }}"
description: 'Service {{ $labels.service }} error rate is {{ $value | printf "%.2f" }}% (> 5% SLO threshold).'Exposing Custom Metrics in Python
Instrumentation using official Prometheus Python client:
from prometheus_client import start_http_server, Counter, Histogram
import time
REQUEST_COUNTER = Counter(
'http_requests_total',
'Total count of HTTP requests processed',
['method', 'endpoint', 'status']
)
REQUEST_DURATION = Histogram(
'http_request_duration_seconds',
'Histogram of HTTP request latency in seconds',
['endpoint'],
buckets=(0.01, 0.05, 0.1, 0.25, 0.5, 1.0, 2.5, 5.0)
)
@REQUEST_DURATION.labels(endpoint='/api/orders').time()
def process_order():
time.sleep(0.08)
REQUEST_COUNTER.labels(method='POST', endpoint='/api/orders', status='200').inc()
# Start metrics endpoint server on port 8000
start_http_server(8000)Common Patterns
High-Throughput Scrape Config with Kubernetes Service Discovery
Problem: Static IP scraping configurations fail as pods scale dynamically in Kubernetes.
Solution:
Use kubernetes_sd_configs with metric path annotations:
scrape_configs:
- job_name: "kubernetes-pods"
kubernetes_sd_configs:
- role: pod
relabel_configs:
- source_labels: [__meta_kubernetes_pod_annotation_prometheus_io_scrape]
action: keep
regex: true
- source_labels: [__meta_kubernetes_pod_annotation_prometheus_io_path]
action: replace
target_label: __metrics_path__
regex: (.+)
- source_labels:
[__address__, __meta_kubernetes_pod_annotation_prometheus_io_port]
action: replace
regex: ([^:]+)(?::\d+)?;(\d+)
replacement: $1:$2
target_label: __address__Best Practices
Do:
- Adhere strictly to the Four Golden Signals (Latency, Traffic, Errors, Saturation) when building PromQL alert rules.
- Configure appropriate histogram buckets around your service SLO targets (e.g. 100ms, 200ms, 500ms).
- Use recording rules (
record: job:metric:rate5m) for complex PromQL expressions queried by dashboards. - Store long-term historical metrics using remote-write storage (Thanos, Cortex, or VictoriaMetrics).
Don't:
- Introduce high-cardinality label values (user IDs, email addresses, order IDs) into metric labels.
- Set scrape intervals too low (< 5s) across large fleets; it overloads target scrapers and storage.
- Alert on simple transient spikes; always use
for: 2morfor: 5mto filter temporary noise.
Troubleshooting
| Error | Cause | Solution |
Target shows DOWN in Prometheus Targets UI | Scrape target port firewalled or application metrics path crashing. | Test target endpoint manually: curl http://<pod-ip>:<port>/metrics. |
High memory usage / Prometheus OOM | High churn in metric series (high cardinality tags like UUIDs or user emails). | Audit and drop unbounded labels using metric_relabel_configs. |
PromQL: many-to-many matching not allowed | Vector matching join (on(...)) without group_left or group_right modifiers. | Add group_left or group_right to specify many-to-one relationship. |
References
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
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.

