Conversation
…hared metrics Co-authored-by: mnkiefer <8320933+mnkiefer@users.noreply.github.com>
Co-authored-by: mnkiefer <8320933+mnkiefer@users.noreply.github.com>
Co-authored-by: mnkiefer <8320933+mnkiefer@users.noreply.github.com>
Contributor
|
@copilot agentic-workflows server (configured in tools) and logs tool to collect metrics |
Copilot
AI
changed the title
[WIP] Create shared metrics collection infrastructure for agent performance
Add shared metrics collection infrastructure for agent performance analysis
Dec 24, 2025
…ctions API Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Contributor
Author
Updated to use the agentic-workflows tool (status and logs) as the primary data source for metrics collection. The GitHub MCP server is now used only for engagement metrics. This provides more efficient log retrieval, includes token usage and cost data, and simplifies data processing. Changes in commit aa8f667. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Meta-orchestrators (Agent Performance Analyzer, Campaign Manager, Workflow Health Manager) lacked centralized metrics for historical trend analysis, performance benchmarking, and early detection of degrading workflows.
Changes
New metrics-collector workflow (
.github/workflows/metrics-collector.md)memory/meta-orchestrators/metrics/{daily/YYYY-MM-DD.json, latest.json}Updated meta-orchestrators to consume shared metrics:
agent-performance-analyzer.md: Load metrics for trend analysis, compare current vs. historical performancecampaign-manager.md: Use metrics for campaign health assessment, velocity calculationsworkflow-health-manager.md: Leverage metrics for quality trend tracking, MTBF calculationsMetrics schema (JSON):
{ "timestamp": "2024-12-24T00:00:00Z", "workflows": { "workflow-name": { "safe_outputs": { "issues_created": 5, "prs_created": 2, ... }, "workflow_runs": { "total": 7, "successful": 6, "failed": 1, "success_rate": 0.857, "avg_duration_seconds": 180, "total_tokens": 45000, "total_cost_usd": 0.45 }, "engagement": { "issue_reactions": 12, "pr_comments": 8, ... }, "quality_indicators": { "pr_merge_rate": 0.75, "avg_issue_close_time_hours": 48.5, ... } } }, "ecosystem": { "total_workflows": 120, "active_workflows": 85, "overall_success_rate": 0.892, "total_tokens": 1250000, "total_cost_usd": 12.50 } }Architecture Benefits:
Enables historical trend analysis, anomaly detection, cost tracking, and reduces redundant GitHub API queries across meta-orchestrators.
Original prompt
This section details on the original issue you should resolve
<issue_title>Create Shared Metrics Collection Infrastructure for Agent Performance</issue_title>
<issue_description>## Problem
The agent ecosystem currently lacks centralized performance metrics collection and storage. This prevents:
Meta-orchestrators (Agent Performance Analyzer, Campaign Manager, Workflow Health Manager) need shared metrics to coordinate effectively and make strategic decisions.
Solution
Create a shared metrics collection infrastructure using repo-memory for persistence.
Architecture
1. Metrics Schema (JSON format in repo-memory)
{ "timestamp": "2024-12-24T12:00:00Z", "period": "daily", "workflows": { "workflow-name": { "safe_outputs": { "issues_created": 5, "prs_created": 2, "comments_added": 10, "discussions_created": 1 }, "workflow_runs": { "total": 7, "successful": 6, "failed": 1, "success_rate": 0.857 }, "engagement": { "issue_reactions": 12, "pr_comments": 8, "discussion_replies": 3 }, "quality_indicators": { "pr_merge_rate": 0.75, "avg_issue_close_time_hours": 48, "avg_pr_merge_time_hours": 72 } } }, "ecosystem": { "total_workflows": 120, "active_workflows": 85, "total_safe_outputs": 45, "overall_success_rate": 0.892 } }2. Storage Location
3. Collection Workflow
Create new workflow:
.github/workflows/metrics-collector.mdResponsibilities:
4. Consumer Integration
Update meta-orchestrators to read metrics:
Implementation Plan
Phase 1: Basic Collection (Week 1)
Phase 2: Enrichment (Week 2)
Phase 3: Integration (Week 3)
Phase 4: Visualization (Week 4)
Expected Benefits
✅ Enables:
✅ Improves:
Acceptance Criteria
Priority
High - Foundation for data-driven agent ecosystem management
Effort Estimate
Total: 12-16 hours across 4 weeks
Dependencies
Related
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.