diff --git a/monitoring/grafana/dashboards/copykar.json b/monitoring/grafana/dashboards/copykar.json new file mode 100644 index 0000000..75f2cc9 --- /dev/null +++ b/monitoring/grafana/dashboards/copykar.json @@ -0,0 +1,138 @@ +{ + "annotations": { + "list": [] + }, + "editable": true, + "fiscalYearStartMonth": 0, + "graphTooltip": 0, + "id": null, + "links": [], + "liveNow": false, + "panels": [ + { + "collapsed": false, + "gridPos": { "h": 6, "w": 6, "x": 0, "y": 0 }, + "id": 1, + "title": "Total Posts Collected", + "type": "stat", + "targets": [ + { + "expr": "sum(copykar_posts_collected_total)", + "legendFormat": "Collected Posts", + "refId": "A" + } + ] + }, + { + "collapsed": false, + "gridPos": { "h": 6, "w": 6, "x": 6, "y": 0 }, + "id": 2, + "title": "Total Duplicates Caught", + "type": "stat", + "targets": [ + { + "expr": "sum(copykar_duplicates_detected_total)", + "legendFormat": "Duplicates", + "refId": "A" + } + ] + }, + { + "collapsed": false, + "gridPos": { "h": 6, "w": 6, "x": 12, "y": 0 }, + "id": 3, + "title": "Admin Approvals", + "type": "stat", + "targets": [ + { + "expr": "sum(copykar_admin_actions_total{action=\"approved\"})", + "legendFormat": "Approved", + "refId": "A" + } + ] + }, + { + "collapsed": false, + "gridPos": { "h": 6, "w": 6, "x": 18, "y": 0 }, + "id": 4, + "title": "Posts Published", + "type": "stat", + "targets": [ + { + "expr": "sum(copykar_posts_published_total)", + "legendFormat": "Published", + "refId": "A" + } + ] + }, + { + "collapsed": false, + "gridPos": { "h": 8, "w": 12, "x": 0, "y": 6 }, + "id": 5, + "title": "Post Ingestion Rate (per minute)", + "type": "timeseries", + "targets": [ + { + "expr": "rate(copykar_posts_collected_total[1m]) * 60", + "legendFormat": "Channel {{source_channel_id}}", + "refId": "A" + } + ] + }, + { + "collapsed": false, + "gridPos": { "h": 8, "w": 12, "x": 12, "y": 6 }, + "id": 6, + "title": "Duplicates Detected by Method", + "type": "timeseries", + "targets": [ + { + "expr": "rate(copykar_duplicates_detected_total[1m]) * 60", + "legendFormat": "Method: {{method}}", + "refId": "A" + } + ] + }, + { + "collapsed": false, + "gridPos": { "h": 8, "w": 12, "x": 0, "y": 14 }, + "id": 7, + "title": "AI Latency (p95 / Average in seconds)", + "type": "timeseries", + "targets": [ + { + "expr": "histogram_quantile(0.95, sum(rate(copykar_ai_latency_seconds_bucket[5m])) by (le, action))", + "legendFormat": "p95 - {{action}}", + "refId": "A" + } + ] + }, + { + "collapsed": false, + "gridPos": { "h": 8, "w": 12, "x": 12, "y": 14 }, + "id": 8, + "title": "Pending Queue Depth", + "type": "timeseries", + "targets": [ + { + "expr": "copykar_posts_queue_gauge", + "legendFormat": "Status: {{status}}", + "refId": "A" + } + ] + } + ], + "refresh": "10s", + "schemaVersion": 38, + "style": "dark", + "tags": ["copykar", "telegram"], + "time": { + "from": "now-1h", + "to": "now" + }, + "timepicker": {}, + "timezone": "", + "title": "Copykar Telegram Fleet Dashboard", + "uid": "copykar-fleet-metrics", + "version": 1 +}