Files
copykar/monitoring/grafana/dashboards/copykar.json
T

305 lines
7.9 KiB
JSON

{
"annotations": {
"list": []
},
"editable": true,
"fiscalYearStartMonth": 0,
"graphTooltip": 1,
"id": null,
"links": [],
"liveNow": true,
"panels": [
{
"collapsed": false,
"gridPos": { "h": 1, "w": 24, "x": 0, "y": 0 },
"id": 100,
"title": "📌 Key Performance Indicators & Real-Time Queues",
"type": "row"
},
{
"collapsed": false,
"gridPos": { "h": 4, "w": 3, "x": 0, "y": 1 },
"id": 1,
"title": "Total Ingested",
"type": "stat",
"targets": [
{
"expr": "sum(copykar_posts_collected_total) or vector(0)",
"legendFormat": "Collected",
"refId": "A"
}
],
"fieldConfig": {
"defaults": {
"color": { "mode": "palette-classic" },
"thresholds": { "mode": "absolute", "steps": [{ "color": "blue", "value": null }] }
}
}
},
{
"collapsed": false,
"gridPos": { "h": 4, "w": 3, "x": 3, "y": 1 },
"id": 15,
"title": "📥 Redis Queue Depth",
"type": "stat",
"targets": [
{
"expr": "copykar_redis_queue_size or vector(0)",
"legendFormat": "Waiting Posts",
"refId": "A"
}
],
"fieldConfig": {
"defaults": {
"color": { "mode": "thresholds" },
"thresholds": {
"mode": "absolute",
"steps": [
{ "color": "green", "value": null },
{ "color": "orange", "value": 10 },
{ "color": "red", "value": 50 }
]
}
}
}
},
{
"collapsed": false,
"gridPos": { "h": 4, "w": 3, "x": 6, "y": 1 },
"id": 3,
"title": "Admin Approvals",
"type": "stat",
"targets": [
{
"expr": "sum(copykar_admin_actions_total{action=\"approved\"}) or vector(0)",
"legendFormat": "Approved",
"refId": "A"
}
],
"fieldConfig": {
"defaults": {
"thresholds": { "mode": "absolute", "steps": [{ "color": "green", "value": null }] }
}
}
},
{
"collapsed": false,
"gridPos": { "h": 4, "w": 3, "x": 9, "y": 1 },
"id": 4,
"title": "Admin Rejections",
"type": "stat",
"targets": [
{
"expr": "sum(copykar_admin_actions_total{action=\"rejected\"}) or vector(0)",
"legendFormat": "Rejected",
"refId": "A"
}
],
"fieldConfig": {
"defaults": {
"thresholds": { "mode": "absolute", "steps": [{ "color": "red", "value": null }] }
}
}
},
{
"collapsed": false,
"gridPos": { "h": 4, "w": 4, "x": 12, "y": 1 },
"id": 5,
"title": "Target Deliveries",
"type": "stat",
"targets": [
{
"expr": "sum(copykar_target_activity_total) or vector(0)",
"legendFormat": "Published",
"refId": "A"
}
],
"fieldConfig": {
"defaults": {
"thresholds": { "mode": "absolute", "steps": [{ "color": "purple", "value": null }] }
}
}
},
{
"collapsed": false,
"gridPos": { "h": 4, "w": 4, "x": 16, "y": 1 },
"id": 6,
"title": "AI Target Rewrites Total",
"type": "stat",
"targets": [
{
"expr": "sum(copykar_ai_requests_total) or vector(0)",
"legendFormat": "AI Calls",
"refId": "A"
}
],
"fieldConfig": {
"defaults": {
"thresholds": { "mode": "absolute", "steps": [{ "color": "cyan", "value": null }] }
}
}
},
{
"collapsed": false,
"gridPos": { "h": 4, "w": 4, "x": 20, "y": 1 },
"id": 16,
"title": "Review Queue Depth",
"type": "stat",
"targets": [
{
"expr": "copykar_posts_queue_gauge{status=\"pending_review\"} or vector(0)",
"legendFormat": "Pending Review",
"refId": "A"
}
],
"fieldConfig": {
"defaults": {
"thresholds": { "mode": "absolute", "steps": [{ "color": "yellow", "value": null }] }
}
}
},
{
"collapsed": false,
"gridPos": { "h": 1, "w": 24, "x": 0, "y": 5 },
"id": 101,
"title": "📡 Source & Target Channel Activity Breakdown",
"type": "row"
},
{
"collapsed": false,
"gridPos": { "h": 8, "w": 12, "x": 0, "y": 6 },
"id": 7,
"title": "Ingested Posts by Source Channel",
"type": "timeseries",
"targets": [
{
"expr": "sum by (title) (copykar_source_activity_total)",
"legendFormat": "Source: {{title}}",
"refId": "A"
}
]
},
{
"collapsed": false,
"gridPos": { "h": 8, "w": 12, "x": 12, "y": 6 },
"id": 8,
"title": "Published Posts by Target Channel",
"type": "timeseries",
"targets": [
{
"expr": "sum by (title) (copykar_target_activity_total)",
"legendFormat": "Target: {{title}}",
"refId": "A"
}
]
},
{
"collapsed": false,
"gridPos": { "h": 1, "w": 24, "x": 0, "y": 14 },
"id": 102,
"title": "🤖 AI Operations & Deduplication Analytics",
"type": "row"
},
{
"collapsed": false,
"gridPos": { "h": 8, "w": 12, "x": 0, "y": 15 },
"id": 10,
"title": "AI Requests by Action & Status",
"type": "timeseries",
"targets": [
{
"expr": "sum by (action, status) (rate(copykar_ai_requests_total[1m]) * 60)",
"legendFormat": "{{action}} ({{status}})",
"refId": "A"
}
]
},
{
"collapsed": false,
"gridPos": { "h": 8, "w": 12, "x": 12, "y": 15 },
"id": 11,
"title": "AI Latency (p95 & Average Duration in sec)",
"type": "timeseries",
"targets": [
{
"expr": "histogram_quantile(0.95, sum(rate(copykar_ai_latency_seconds_bucket[5m])) by (le, action))",
"legendFormat": "p95: {{action}}",
"refId": "A"
},
{
"expr": "rate(copykar_ai_latency_seconds_sum[5m]) / rate(copykar_ai_latency_seconds_count[5m])",
"legendFormat": "Avg: {{action}}",
"refId": "B"
}
]
},
{
"collapsed": false,
"gridPos": { "h": 1, "w": 24, "x": 0, "y": 23 },
"id": 103,
"title": "⚡ Container & System Telemetry",
"type": "row"
},
{
"collapsed": false,
"gridPos": { "h": 7, "w": 8, "x": 0, "y": 24 },
"id": 12,
"title": "Process CPU Usage (%)",
"type": "timeseries",
"targets": [
{
"expr": "rate(process_cpu_seconds_total{job=\"copykar\"}[1m]) * 100",
"legendFormat": "CPU Usage %",
"refId": "A"
}
]
},
{
"collapsed": false,
"gridPos": { "h": 7, "w": 8, "x": 8, "y": 24 },
"id": 13,
"title": "Process RAM Usage (MB)",
"type": "timeseries",
"targets": [
{
"expr": "process_resident_memory_bytes{job=\"copykar\"} / 1024 / 1024",
"legendFormat": "Memory (MB)",
"refId": "A"
}
]
},
{
"collapsed": false,
"gridPos": { "h": 7, "w": 8, "x": 16, "y": 24 },
"id": 14,
"title": "Active Threads & Open FDs",
"type": "timeseries",
"targets": [
{
"expr": "process_threads_total{job=\"copykar\"}",
"legendFormat": "Threads",
"refId": "A"
},
{
"expr": "process_open_fds{job=\"copykar\"}",
"legendFormat": "Open FDs",
"refId": "B"
}
]
}
],
"refresh": "5s",
"schemaVersion": 38,
"style": "dark",
"tags": ["copykar", "telegram", "ai", "telemetry", "redis"],
"time": {
"from": "now-1h",
"to": "now"
},
"timepicker": {},
"timezone": "browser",
"title": "Copykar Telegram Fleet Executive Dashboard",
"uid": "copykar-executive-dashboard",
"version": 4
}