Extract Azure DevOps Pull Request metrics to SQLite and generate PowerBI-compatible CSVs.
Project description
ADO Git Repo Insights
[!NOTE] Python Compatibility: Requires Python 3.12 or later. Uses pandas 3.x.
Extract Azure DevOps Pull Request metrics to SQLite and generate PowerBI-compatible CSVs.
🚀 Quick Start
Choose your path:
| I want to... | Use |
|---|---|
| Analyze PRs for my team via Azure DevOps pipelines | ADO Extension |
| Run analysis locally or integrate into custom CI/CD | Python CLI |
☁️ Azure DevOps Extension
The ADO Extension provides a self-contained pipeline task with a built-in PR Insights Dashboard directly in your Azure DevOps project.
What you get:
- Pipeline task that extracts PR metrics automatically
- Interactive dashboard in your ADO project navigation
- No Python installation required
- PowerBI-compatible CSV exports
Get started: Extension User Guide
Minimal Pipeline Example
variables:
- group: ado-insights-secrets # Contains PAT_SECRET
steps:
- task: ExtractPullRequests@3
inputs:
organization: "MyOrg"
projects: "Project1,Project2"
pat: "$(PAT_SECRET)"
- publish: $(Pipeline.Workspace)/aggregates
artifact: aggregates
🐍 Python CLI
The Python CLI provides full control for local analysis, custom scripts, and non-ADO CI/CD systems.
# Install (recommended)
pipx install ado-git-repo-insights
# Extract → CSV → dashboard
ado-insights extract --organization MyOrg --projects "Project1,Project2" --pat $ADO_PAT --database ./ado-insights.sqlite
ado-insights generate-csv --database ./ado-insights.sqlite --output ./csv_output
ado-insights build-aggregates --db ./ado-insights.sqlite --out ./dataset
ado-insights dashboard --dataset ./dataset --open
Get started: CLI User Guide — covers uv and pip install paths, configuration files, and CI/CD integration.
📚 Documentation
👤 For End Users
| Document | Description |
|---|---|
| Extension User Guide | Complete setup for ADO Extension users |
| CLI User Guide | Complete setup for Python CLI users |
| Troubleshooting | Common issues and solutions |
📖 Reference
| Document | Description |
|---|---|
| CLI Command Reference | All CLI commands and options |
| Task Input Reference | Extension task configuration |
| CSV Schema | PowerBI-compatible output format |
| Dataset Contract | Dashboard data format specification |
| Architecture | System design and data flow diagrams |
⚙️ Operations
| Document | Description |
|---|---|
| Runbook | Monitoring, recovery, and operational procedures |
| Data Retention | Storage model and security posture |
🛠️ For Developers
| Document | Description |
|---|---|
| Contributing Guide | How to contribute to this project |
| Development Setup | Setting up the development environment |
| Testing Guide | Running and writing tests |
| Demo Data Versioning | Canonical demo build and parity policy |
| UI Bundle Sync | Dashboard UI synchronization process |
| Changelog | Version history and release notes |
📋 Governance
| Document | Description |
|---|---|
| Invariants | Non-negotiable system invariants |
| Definition of Done | Completion criteria for features |
| Verification Gates | Verification checkpoints |
⚖️ Feature Comparison
| Feature | CLI | Extension |
|---|---|---|
| Installation | pip install |
ADO Marketplace |
| Requires Python | Yes | No (bundled) |
| Pipeline syntax | Script steps | Task step |
| Works outside ADO | Yes | No |
| PR Insights Dashboard | Local server | Built into ADO |
| Configuration | YAML file or CLI args | Task inputs |
| Flexibility | Higher | Standard |
⚡ How It Works
- Extract — Fetches completed PRs from Azure DevOps REST API
- Store — Persists data in SQLite with UPSERT semantics
- Generate — Produces PowerBI-compatible CSVs and dashboard aggregates
- Visualize — View metrics in the PR Insights Dashboard
The system uses incremental extraction by default (daily) with optional backfill mode to catch late changes (reviewer votes, status updates).
Comment extraction is opt-in via --include-comments on extract; to cover PR comments for history that predates enabling it, run the one-time backfill-comments subcommand — see the extension guide or CLI guide.
🤖 ML Features (Optional)
The dashboard supports optional ML-powered features: time-series forecasting for cycle time and throughput (zero-config, no API key) and AI insights for bottleneck analysis (requires an OpenAI API key, ~$0.001–0.01 per pipeline run, only aggregated metrics sent — never PR content, identities, or code).
Setup and troubleshooting: Enable ML Features
🛠️ Developer Setup
- Recommended: open in a Dev Container — handles all per-platform tooling automatically.
- Native setup (advanced):
docs/development/setup.md. - Contributing:
CONTRIBUTING.md.
🔒 Security
PATs use minimum Code (Read) scope, are never logged, and are never persisted at rest. Full posture: docs/SECURITY.md.
💬 Support
- Issues & Features: GitHub Issues
- Publisher: OddEssentials
📄 License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ado_git_repo_insights-101.28.1.tar.gz.
File metadata
- Download URL: ado_git_repo_insights-101.28.1.tar.gz
- Upload date:
- Size: 9.0 MB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c42877bec3eeecb2612473a2667759310bb667a3220510a6e0e670ff80726b43
|
|
| MD5 |
98f62640cb4cef3c053377d1f4b82718
|
|
| BLAKE2b-256 |
336718184dbd16f6644feeee905ca590f12007de3624bbdc5d4e3980c08710f5
|
Provenance
The following attestation bundles were made for ado_git_repo_insights-101.28.1.tar.gz:
Publisher:
release.yml on oddessentials/ado-git-repo-insights
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
ado_git_repo_insights-101.28.1.tar.gz -
Subject digest:
c42877bec3eeecb2612473a2667759310bb667a3220510a6e0e670ff80726b43 - Sigstore transparency entry: 1733051534
- Sigstore integration time:
-
Permalink:
oddessentials/ado-git-repo-insights@678c2a9c1926de79ed6125c60126260a6f8ec0b6 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/oddessentials
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@678c2a9c1926de79ed6125c60126260a6f8ec0b6 -
Trigger Event:
push
-
Statement type:
File details
Details for the file ado_git_repo_insights-101.28.1-py3-none-any.whl.
File metadata
- Download URL: ado_git_repo_insights-101.28.1-py3-none-any.whl
- Upload date:
- Size: 358.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c440191519a95dc556a488ddaa87bd144d3ab3abf1938c10f443622ebde8db91
|
|
| MD5 |
b48f97d0639fa71443dacac00637d93d
|
|
| BLAKE2b-256 |
a1516d0e4ec03b0f2015af750733474f7765653c5db1c8ff67a19e4d35da43ab
|
Provenance
The following attestation bundles were made for ado_git_repo_insights-101.28.1-py3-none-any.whl:
Publisher:
release.yml on oddessentials/ado-git-repo-insights
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
ado_git_repo_insights-101.28.1-py3-none-any.whl -
Subject digest:
c440191519a95dc556a488ddaa87bd144d3ab3abf1938c10f443622ebde8db91 - Sigstore transparency entry: 1733051540
- Sigstore integration time:
-
Permalink:
oddessentials/ado-git-repo-insights@678c2a9c1926de79ed6125c60126260a6f8ec0b6 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/oddessentials
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@678c2a9c1926de79ed6125c60126260a6f8ec0b6 -
Trigger Event:
push
-
Statement type: