Skip to content

feat: Added ai usage analytics#1

Open
irfanuddinahmad wants to merge 15 commits into
mainfrom
feature/github-ai-analytics
Open

feat: Added ai usage analytics#1
irfanuddinahmad wants to merge 15 commits into
mainfrom
feature/github-ai-analytics

Conversation

@irfanuddinahmad

@irfanuddinahmad irfanuddinahmad commented Apr 1, 2026

Copy link
Copy Markdown
Collaborator

This pull request introduces a unified domain-layer schema for AI-assisted coding activity, adds migration scripts to support the new schema, implements foundational API logic and new Claude, Cursor and Codex plugins. Additionally, it introduces a per-user project mapping table to support Grafana dashboard visibility and registers all new migrations. The most important changes are grouped below:

AI Activity Unified Schema and Migrations:

  • Added the AiActivity domain model in backend/core/models/domainlayer/ai/ai_activity.go to represent normalized, tool-agnostic records of AI-assisted coding activity. This model supports multiple providers and includes fields for code metrics, agentic outcomes, and cost/token metrics.
  • Introduced migration script 20260331_add_ai_activities_unified_schema.go to add and update the ai_activities table, including renaming legacy columns, and adding new fields for interface type and suggestion/acceptance counts.
  • Registered the new AiActivity table in the domain info registry and included it in the list of domain tables. [1] [2]

User-Project Mapping for Grafana:

  • Added a new user_project_mapping table and its migration script (20260311_add_user_project_mapping.go) to map user logins to project names, enabling per-user project visibility in Grafana dashboards. [1] [2]

These changes lay the groundwork for unified AI activity analytics and support for new AI tool plugins, while improving user/project management and plugin extensibility.

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

license-eye has checked 4044 files.

Valid Invalid Ignored Fixed
3164 2 878 0
Click to see the invalid file list
  • backend/plugins/codex/service/connection_test_helper.go
  • backend/plugins/cursor/service/connection_test_helper.go
Use this command to fix any missing license headers
```bash

docker run -it --rm -v $(pwd):/github/workspace apache/skywalking-eyes header fix

</details>

@arbisoft arbisoft deleted a comment from github-actions Bot Apr 1, 2026
@arbisoft arbisoft deleted a comment from github-actions Bot Apr 1, 2026
@arbisoft arbisoft deleted a comment from github-actions Bot Apr 1, 2026
@arbisoft arbisoft deleted a comment from github-actions Bot Apr 1, 2026
@irfanuddinahmad
irfanuddinahmad force-pushed the feature/github-ai-analytics branch from 1994e4e to 925150a Compare April 2, 2026 16:23
aimanmuzaffar95 added a commit that referenced this pull request Apr 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant