dashboarding
安装方式
先用 Prompt 核对来源与依赖。也可下载安装包。
用 AI 助手安装
复制提示词,让助手先核对固定版本和依赖。
查看 Prompt收起 Prompt
先检查当前 Agent 是否已安装 SkillPI Skill Finder。如果尚未安装,请按官方仓库的说明安装并启用:https://github.com/Findskills/skillpi。然后使用 Skill Finder 打开此 SkillPI 详情页并定位 "dashboarding":https://skillpi.com/zh/skills/deepskill-937c8ed56e3ded385a15389a09c2d2fc907063b4c47874b05a135601c968aa90。安装前核对上游来源和版本:https://github.com/Kilo-Org/kilo-marketplace。来源不一致时停止并说明差异。核对通过后,用 Skill Finder 安装目标 Skill,并报告安装路径和来源版本。
来源与配置
github.com
配置方式待核实
请查看原始来源中的适用工具、依赖和权限要求。
安装实测待补充
用于创建、修改与管理 Grafana 仪表板,包括面板、变量、数据转换与告警配置。适用于创建仪表板、添加时间序列或统计面板、配置模板变量与仪表板链接、使用数据转换、设置阈值、为服务构建仪表板或导出仪表板 JSON 等场景。触发关键词示例:创建仪表板、添加面板、时间序列面板、Grafana 仪表板 JSON、模板变量、仪表板变量、面板转换、阈值、统计面板、表格面板、Grafana 注释、仪表板文件夹。
介绍来源: third_party · Kilo-Org · 0.0.1 参考来源
SkillPi 解读
- 适合谁
- 翻译待完成,请参阅来源文档。
- 实测状态
- 未测试
文件浏览
Frontmatter
name: dashboarding
description: >-
Create, modify, and organise Grafana dashboards including panels, variables,
transformations, and alerting. Use when the user asks to create a Grafana
dashboard, add a panel, configure a time series or stat panel, add template
variables, set up dashboard linking, use transformations, configure
thresholds, build a dashboard for a service, or export dashboard JSON.
Triggers on phrases like "create dashboard", "add panel", "time series panel",
"Grafana dashboard JSON", "template variables", "dashboard variable", "panel
transformation", "threshold", "stat panel", "table panel", "Grafana
annotations", or "dashboard folder".
metadata:
category: observability
source:
repository: 'https://github.com/grafana/skills'
path: skills/grafana-core/dashboarding
license_path: LICENSE
commit: e8424d242290be2ae187a74b5fd854174f0c5411Grafana Dashboard Authoring
Dashboards are JSON documents stored in Grafana. Every dashboard has panels, variables, time range, and refresh settings. Understanding the JSON schema lets you programmatically create and modify dashboards via the API or Grafana Assistant tools.
Dashboard JSON structure
{
"title": "My Dashboard",
"uid": "my-dashboard-v1",
"tags": ["service", "production"],
"time": { "from": "now-1h", "to": "now" },
"refresh": "30s",
"timezone": "browser",
"schemaVersion": 41,
"templating": { "list": [] },
"annotations": { "list": [] },
"panels": []
}
Key fields:
uid- stable identifier used in URLs and API calls; keep it short and meaningfulschemaVersion- use41for Grafana 11+time.from/to- supports relative (now-1h,now-7d) and absolute ISO timestampsrefresh- auto-refresh interval ("30s","1m","5m",""for off)
Panel types and when to use them
| Panel | Use case |
|---|---|
| Time series | Any metric over time; the default choice for counters, rates, gauges |
| Stat | Single current value with optional sparkline (e.g. uptime, current RPS) |
| Gauge | Percent or value against a min/max (e.g. disk usage %) |
| Bar gauge | Compare multiple values side by side (e.g. top 10 services by RPS) |
| Table | Multi-column data (e.g. alert list with labels) |
| Heatmap | Distribution over time (e.g. request duration histogram) |
| Logs | Loki log streams |
| Traces | Tempo trace search |
| Text | Markdown documentation panels |
| Candlestick | OHLC/financial data (or min/max/avg patterns) |
| Node graph | Service dependency graphs |
Panel JSON structure
{
"id": 1,
"type": "timeseries",
"title": "Request Rate",
"gridPos": { "x": 0, "y": 0, "w": 12, "h": 8 },
"datasource": { "type": "prometheus", "uid": "${datasource}" },
"targets": [
{
"expr": "sum(rate(http_requests_total{job=\"$job\"}[5m])) by (status_code)",
"legendFormat": "{{status_code}}",
"refId": "A"
}
],
"fieldConfig": {
"defaults": {
"unit": "reqps",
"thresholds": {
"mode": "absolute",
"steps": [
{ "color": "green", "value": null },
{ "color": "yellow", "value": 1000 },
{ "color": "red", "value": 5000 }
]
}
},
"overrides": []
},
"options": {
"legend": { "calcs": ["mean", "max", "last"], "displayMode": "table", "placement": "bottom" },
"tooltip": { "mode": "multi", "sort": "desc" }
}
}
gridPos: The dashboard uses a 24-column grid. Common widths: full-width=24, half=12, third=8, quarter=6. Height in grid units (1 unit ≈ 30px).
Useful unit identifiers
# Rates
"reqps" -- requests per second
"ops" -- operations per second
"Bps" -- bytes per second
"percentunit" -- 0.0-1.0 as percentage
# Storage
"bytes" -- bytes (auto-scales to KB/MB/GB)
"decbytes" -- decimal bytes (1 KB = 1000 B)
# Time
"ms" -- milliseconds
"s" -- seconds
"dtdurationms" -- duration in ms (shows as "1h 2m 3s")
# Counts
"short" -- compact number (1.2k, 3.4M)
"none" -- raw number
Full list: Panel > Field > Unit dropdown in Grafana UI, or the units reference.
Template variables
Variables make dashboards reusable across environments and services.
Query variable (populates from metric labels):
{
"name": "job",
"type": "query",
"datasource": { "type": "prometheus", "uid": "prometheus" },
"query": { "query": "label_values(up, job)", "refId": "A" },
"refresh": 2,
"includeAll": true,
"multi": true,
"label": "Service"
}
Constant variable:
{
"name": "cluster",
"type": "constant",
"query": "production",
"label": "Cluster"
}
Datasource variable (switch data sources without editing queries):
{
"name": "datasource",
"type": "datasource",
"pluginId": "prometheus",
"includeAll": false,
"label": "Prometheus"
}
Use variables in queries:
# Reference a variable in a PromQL query
rate(http_requests_total{job=~"$job"}[5m])
# Multi-value variable uses regex OR automatically
# When $job = ["api", "worker"], it becomes job=~"api|worker"
Chain variables (second variable filters based on first):
{
"name": "pod",
"query": "label_values(kube_pod_info{namespace=\"$namespace\"}, pod)"
}
Transformations
Transformations run client-side after data is fetched, reshaping results without changing queries.
Common transformations:
"transformations": [
{
"id": "merge",
"options": {}
},
{
"id": "organize",
"options": {
"renameByName": { "Value #A": "Request Rate", "Value #B": "Error Rate" },
"excludeByName": { "Time": true }
}
},
{
"id": "calculateField",
"options": {
"alias": "Error %",
"mode": "reduceRow",
"reduce": { "reducer": "last" },
"binary": {
"left": "errors",
"right": "total",
"operator": "/"
}
}
},
{
"id": "filterByValue",
"options": {
"filters": [{ "fieldName": "Error %", "config": { "id": "greater", "options": { "value": 0.01 } } }],
"type": "include",
"match": "any"
}
}
]
Key transformation IDs: merge, organize, rename, calculateField, filterByValue,
groupBy, sortBy, limit, labelsToFields, seriesToRows, partitionByValues.
Dashboard linking
Panel link (click a panel to go somewhere):
"links": [
{
"title": "Go to details",
"url": "/d/details-dashboard?var-service=${__field.labels.service}",
"targetBlank": false
}
]
Dashboard link (top-right corner links):
"links": [
{
"title": "Runbook",
"url": "https://wiki.example.com/runbook/${job}",
"icon": "external link",
"targetBlank": true,
"type": "link"
}
]
Built-in variables for links:
${__value.raw}- current data point value${__field.labels.job}- label value from current series${__url.params}- current URL query parameters (pass-through)${__from}/${__to}- current time range as Unix ms
Annotations
Show events overlaid on time series panels (deployments, incidents, etc.).
Query annotation from Loki:
{
"datasource": { "type": "loki", "uid": "loki" },
"expr": "{job=\"deployments\"} |= \"deployed\"",
"name": "Deployments",
"iconColor": "blue",
"titleFormat": "{{service}} deployed",
"textFormat": "{{version}} by {{author}}"
}
Query annotation from Prometheus:
{
"datasource": { "type": "prometheus", "uid": "prometheus" },
"expr": "changes(kube_deployment_status_observed_generation{namespace=\"production\"}[5m]) > 0",
"step": "60s",
"name": "Deployments",
"iconColor": "blue",
"titleFormat": "Deploy: {{deployment}}"
}
Dashboard via API
# Create or update a dashboard
curl -s -X POST \
-H "Authorization: Bearer <API_KEY>" \
-H "Content-Type: application/json" \
"https://myorg.grafana.net/api/dashboards/db" \
-d '{
"dashboard": { <dashboard JSON> },
"folderUid": "my-folder",
"overwrite": true,
"message": "Updated via API"
}'
# Get a dashboard by UID
curl -s -H "Authorization: Bearer <API_KEY>" \
"https://myorg.grafana.net/api/dashboards/uid/my-dashboard-v1" | jq '.dashboard'
# Search dashboards
curl -s -H "Authorization: Bearer <API_KEY>" \
"https://myorg.grafana.net/api/search?query=kubernetes&type=dash-db" | \
jq '.[] | {uid, title, folderTitle}'
# Create a folder
curl -s -X POST \
-H "Authorization: Bearer <API_KEY>" \
-H "Content-Type: application/json" \
"https://myorg.grafana.net/api/folders" \
-d '{"uid": "platform-team", "title": "Platform Team"}'
Grafana scenes (app plugins)
For dashboards embedded in app plugins, use @grafana/scenes instead of raw JSON.
See the grafana-o11y:grafana-scenes skill for the React-based scenes API.
References
版本历史
-
skills-20261103210927-6c1b454
GitHub ↗
原版更新说明
Automated skills release from commit 6c1b4543cac1d45a80bf5904e4b69ac315117323
-
skills-20260928190452-ff51758
GitHub ↗
原版更新说明
Automated skills release from commit ff51758b06b8249007116184096765d47bdb7505
-
skills-20260924105536-d31110d
GitHub ↗
原版更新说明
Automated skills release from commit d31110d62dc0bd00c22f1d6f6a630d1e702a0049
-
skills-20260923085113-cea285e
GitHub ↗
原版更新说明
Automated skills release from commit cea285ef0e4d6ec47cd2fd9fdbca03813a3363c7
-
skills-20260922193956-97d7333
GitHub ↗
原版更新说明
Automated skills release from commit 97d7333d8200e5ac556c659c8669f3a83ba10866
此处仅展示最近 5 个版本。 在原站查看完整版本历史 ↗
当前收录版本
0.0.1
安全与评测信息
质量评测
满分100 · 来自 SkillPi LAB 实验室的评测报告。
亮点
- Grafana 仪表板创建和管理是运维监控领域的核心需求
- 覆盖从基础面板配置到高级功能如变量、转换、告警的完整工作流
- 提供丰富的实际应用场景和最佳实践指导
亮点
- 触发词覆盖全面,包含创建、修改、配置等关键操作场景
- 支持多种面板类型和时间序列相关术语
- 包含模板变量、转换、告警等高级功能触发词
亮点
- 文档结构清晰,从基础概念到高级功能层次分明
- 提供完整的 JSON 结构示例和字段说明
- 包含丰富的代码示例和实际使用场景
亮点
- 提供完整的 API 调用示例和参数说明
- 包含错误处理和最佳实践指导
- 工具来源明确,参数配置合理
取前四项原始分值的算术平均,四舍五入取整。可通过收录报告核对各项评分与说明,运行记录需单独查证。
正文静态检测
100 / 100 · skillpi-20261123-no-r3-v1
正文未命中当前规则。
分数仅反映正文中的规则命中,供使用前参考。附件与运行行为不在此评分范围内。
权限与使用前检查
根据当前主文档自动整理,命中内容可能是示例或防护说明;不是实际权限声明,也未覆盖附件、外部依赖或运行行为。
-
账号、密钥或授权
使用专用、最小权限账号,不把密钥粘贴到公开内容或命令日志;核对接收数据的服务与租户。
主文档提及 · 第 325, 336, 340, 346 行
文档引用的域名或地址
这些地址可能用于文档链接或示例,不是已批准的联网清单。使用前核对实际目的地及发送的数据。
- github.com
- grafana.com
- myorg.grafana.net
- wiki.example.com
安全评级与访问范围
safe · 静态证据核验,不代表运行安全保证。
使用前请由宿主核对并授权实际文件读写、外部服务和联网目的地;本站的核验不会授予任何运行权限。
用户讨论
还没有已核实的点评。