Run metrics reports for APIView Copilot. Use for: run metrics, metrics report, generate metrics, monthly metrics, metrics for March, metrics for January, adoption metrics, comment quality, quality trends, save metrics, metrics charts.
npx skills add https://github.com/Azure/azure-sdk-tools --skill run-metrics
Unless the user says otherwise, always apply these defaults:
production--charts--exclude)--save unless the user explicitly asks to save (e.g. "save it", "persist", "write to DB")quality-trends report for the same period.The user will typically specify a calendar month by name (e.g. "March", "January 2025"). Resolve to the full month date range:
| User says | start_date | end_date |
|-----------|-----------|----------|
| "March" (current year) | YYYY-03-01 | YYYY-03-31 |
| "January 2025" | 2025-01-01 | 2025-01-31 |
| "March 1 to March 15" | YYYY-03-01 | YYYY-03-15 |
| "2025-06-01 to 2025-06-30" | 2025-06-01 | 2025-06-30 |
When only a month name is given without a year, use the current year. Be careful with month lengths (28/29/30/31 days).
Show the resolved command and run it immediately in a single foreground terminal invocation with a 180-second timeout (timeout: 180000). Before running, clean up stale output so you never accidentally present old results.
Important: Do NOT use 2>&1 — that merges stderr log messages (e.g. "Saved: output\charts\adoption.png") into the JSON output file, producing invalid JSON. Pipe stdout through Out-File -Encoding UTF8 so the output file is always valid UTF-8 JSON.
Full terminal command (cleanup + run):
New-Item -ItemType Directory -Path output -Force | Out-Null; if (Test-Path output/metrics_output.json) { Remove-Item output/metrics_output.json }; if (Test-Path output/charts) { Remove-Item output/charts/* -Force }; python cli.py report metrics -s <start_date> -e <end_date> --charts | Out-File -Encoding UTF8 output/metrics_output.json
After the command completes, read the output file with read_file to get the JSON results — do NOT use a separate terminal command. Then use view_image (not a terminal command) to display the chart PNGs. This means the entire workflow requires only one terminal invocation.
# March 2025, production, all languages, with charts (typical request)
python cli.py report metrics -s 2025-03-01 -e 2025-03-31 --charts
# Staging environment
python cli.py report metrics -s 2025-03-01 -e 2025-03-31 --charts --environment staging
# Exclude specific languages
python cli.py report metrics -s 2025-03-01 -e 2025-03-31 --charts --exclude Java Golang
# Custom date range
python cli.py report metrics -s 2025-03-10 -e 2025-03-20 --charts
# Save to database (ONLY when user explicitly requests)
python cli.py report metrics -s 2025-03-01 -e 2025-03-31 --charts --save
The quality-trends report is the companion chart view for metrics work.
The quality-trends command uses --months plus an optional --end-date, not a start date.
Convert the requested metrics window into an inclusive calendar-month count:
| Window | Use for --months |
|--------|--------------------|
| 2026-03-01 to 2026-03-31 | 1 |
| 2026-03-01 to 2026-03-15 | 1 |
| 2026-01-15 to 2026-03-02 | 3 |
Use the same resolved end date from the metrics request for --end-date.
if (Test-Path output/charts/comment_bucket_trends.png) { Remove-Item output/charts/comment_bucket_trends.png -Force }; python cli.py report quality-trends --months <month_count> --end-date <end_date>
Optional additions:
After it completes, summarize the terminal output and use view_image to show the saved chart at output/charts/comment_bucket_trends.png.
If the user asks to save after a metrics run (e.g. "okay save it", "persist that", "write to DB"), re-run the same command with --save appended. Keep all other flags identical to the previous run.
| Flag | Type | Default | Description |
|------|------|---------|-------------|
| --start-date / -s | string | required | Start date (YYYY-MM-DD) |
| --end-date / -e | string | required | End date (YYYY-MM-DD) |
| --environment | string | production | production or staging |
| --exclude | list | none | Space-separated language names to exclude |
| --charts | flag | off | Generate PNG charts to output/charts/ |
| --save | flag | off | Persist metrics to Cosmos DB (never use unless user explicitly requests) |
When --charts is enabled, 4 PNGs are saved to output/charts/:
| Out-File -Encoding UTF8 output/metrics_output.json and read the file afterward. Do NOT use > which produces UTF-16 in PowerShell 5.1.output/metrics_output.json and output/charts/* before running. This prevents presenting stale results if the command fails silently.2>&1: This merges stderr log lines (e.g. "Saved: ...") into the JSON output file, producing invalid JSON. Only redirect stdout.isBackground=false and timeout: 180000 (3 min). Do NOT use isBackground=true and poll — that causes repeated user approval prompts.New-Item -ItemType Directory not mkdir: mkdir is aliased differently across shells. Use New-Item -ItemType Directory -Path output -Force | Out-Null for reliable directory creation.read_file and view_image: After the command finishes, use read_file for the JSON and view_image for charts. Do NOT launch additional terminal commands to read the file.python cli.py not .\avc: The avc.bat script may resolve to system Python. Use python cli.py report metrics ... to ensure the correct environment.report quality-trends with --months and optional --end-date, not --start-date.c, c++, typespec, swagger, xml are always excluded automatically — no need to add them.Comprehensive spreadsheet creation, editing, and analysis with support for formulas, formatting, data analysis, and visualization. When Claude needs to work with spreadsheets (.xlsx, .xlsm, .csv, .tsv, etc) for: (1) Creating new spreadsheets with formulas and formatting, (2) Reading or analyzing data, (3) Modify existing spreadsheets while preserving formulas, (4) Data analysis and visualization in spreadsheets, or (5) Recalculating formulas
Use this skill any time a spreadsheet file is the primary input or output. This means any task where the user wants to: open, read, edit, or fix an existing .xlsx, .xlsm, .csv, or .tsv file (e.g., adding columns, computing formulas, formatting, charting, cleaning messy data); create a new spreadsheet from scratch or from other data sources; or convert between tabular file formats. Trigger especially when the user references a spreadsheet file by name or path — even casually (like \"the xlsx in my downloads\") — and wants something done to it or produced from it. Also trigger for cleaning or restructuring messy tabular data files (malformed rows, misplaced headers, junk data) into proper spreadsheets. The deliverable must be a spreadsheet file. Do NOT trigger when the primary deliverable is a Word document, HTML report, standalone Python script, database pipeline, or Google Sheets API integration, even if tabular data is involved.
Picks random winners from lists, spreadsheets, or Google Sheets for giveaways, raffles, and contests. Ensures fair, unbiased selection with transparency.
Query openFDA API for drugs, devices, adverse events, recalls, regulatory submissions (510k, PMA), substance identification (UNII), for FDA regulatory data analysis and safety research.
MATLAB and GNU Octave numerical computing for matrix operations, data analysis, visualization, and scientific computing. Use when writing MATLAB/Octave scripts for linear algebra, signal processing, image processing, differential equations, optimization, statistics, or creating scientific visualizations. Also use when the user needs help with MATLAB syntax, functions, or wants to convert between MATLAB and Python code. Scripts can be executed with MATLAB or the open-source GNU Octave interpreter.
UMAP dimensionality reduction. Fast nonlinear manifold learning for 2D/3D visualization, clustering preprocessing (HDBSCAN), supervised/parametric UMAP, for high-dimensional data.
Creating interactive data visualisations using d3.js. This skill should be used when creating custom charts, graphs, network diagrams, geographic visualisations, or any complex SVG-based data visualisation that requires fine-grained control over visual elements, transitions, or interactions. Use this for bespoke visualisations beyond standard charting libraries, whether in React, Vue, Svelte, vanilla JavaScript, or any other environment.
Access AlphaFold 200M+ AI-predicted protein structures. Retrieve structures by UniProt ID, download PDB/mmCIF files, analyze confidence metrics (pLDDT, PAE), for drug discovery and structural biology.
Take azure/run-metrics from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.