Repository navigation
feat: add DevFlow analytics and data quality layer - #2
Closed
DanteBurbano27 wants to merge 11 commits into
Closed
DanteBurbano27 wants to merge 11 commits into
DanteBurbano27 wants to merge 11 commits into
Conversation
…portfolio aggregator
…defensible ratios
Owner
Author
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.
Overview
This PR delivers the complete Analytics, Data Quality, and Warehouse Modeling Layer for DevFlow Intelligence, developed by the autonomous Google Antigravity team.
It is built strictly on the upstream
RepositoryMetadatacontract without modifying or interfering with Codex-owned files (ingestion/**,storage/**,orchestration/**,observability/**,.github/**,pyproject.toml,requirements*.txt,.env*,.gitignore).Key Deliverables
Analytical Data Contract (
analytics/contracts/):RepositoryContract: Validates raw dictionaries andRepositoryMetadataagainst immutable schema version1.0.0.RepositoryRecord: Frozen, slotted, type-safe analytical dataclass enforcing UTC timezone awareness and nullability constraints.Derived Metrics & Fleet Aggregation (
analytics/metrics/):RepositoryMetricCalculator: Deterministically derivesdays_since_last_push,days_since_creation,activity_status(ACTIVE,STALE,INACTIVE,ARCHIVED,DISABLED), technical ratios (fork_to_star_ratio,issue_to_star_ratio,star_to_fork_ratio),community_interest_score, andsize_category.PortfolioAnalyticsAggregator: Aggregates multi-repository fleets with sums, averages, medians, language distributions, owner breakdowns, and leaderboards.Data Quality Framework (
analytics/quality/):DataQualityEngine: Programmatic, non-destructive validation engine.ERRORvsWARNING):repository_idand uniquefull_nameacross extraction batches.BigQuery-Ready SQL Models (
analytics/sql/):stg_github_repositories.sql(type casting, null coalescing, 64-bitFARM_FINGERPRINTsurrogate keys, windowed deduplication viaQUALIFY ROW_NUMBER()).int_repository_activity.sql(temporal diffs,SAFE_DIVIDEratios, activity classification).dim_repositories.sql,fct_repository_snapshots.sql(partitioned byDATE(snapshot_timestamp), clustered by(repository_id, language)),agg_language_summary.sql,agg_owner_summary.sql.Operational Diagnostic Scripts (
scripts/):scripts/check_analytics.py: End-to-end analytical workflow diagnostic.scripts/check_data_quality.py: Data quality evaluation diagnostic.Comprehensive Automated Tests (
tests/):Documentation & Portfolio Artifacts (
docs/,README.md):README.md: Professional portfolio documentation.docs/analytics/analytics_architecture.md: Analytics system architecture.docs/analytics/data_quality_framework.md: Rule catalog and runbook.docs/analytics/warehouse_models.md: BigQuery schema and optimization guide.Verification
python -m pytest: 95 passed in 0.70s.ruff check .: All checks passed.ruff format --check .: 50 files already formatted.git diff --stat origin/feature/dfi-006-repository-metadata: 0 Codex files touched.Ready for Codex review and final integration.