Skip to content

feat(ai): persist hint usage and difficulty analytics (BA-081) - #745

Merged
MaryammAli merged 2 commits into
BlockDash-Studios:mainfrom
BobbyRichie2:feat/649-hint-usage-analytics
Aug 29, 2026
Merged

feat(ai): persist hint usage and difficulty analytics (BA-081)#745
MaryammAli merged 2 commits into
BlockDash-Studios:mainfrom
BobbyRichie2:feat/649-hint-usage-analytics

Conversation

@BobbyRichie2

Copy link
Copy Markdown
Contributor

Closes #649. Durable, user-scoped, deduplicated hint usage analytics with a REST endpoint and tests. Authored as BobbyRichie2.

…Dash-Studios#649)

- Track hint usage durably, keyed by userId:hintId (deduplicated per user)
- Persist records to Redis under hint:usage:... and unique-user sets under hint:users:...
- Add getHintUsageAnalytics() aggregating totalUses, uniqueUsers, usesByHint, usesByDifficulty
- Mirror Redis state into a fresh service instance so counts survive restarts
- Expose GET /ai/hints/analytics endpoint
- Add unit tests for dedup, user-scoping, difficulty distribution, and restart durability

@MaryammAli MaryammAli left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

@MaryammAli
MaryammAli merged commit 313ea98 into BlockDash-Studios:main Aug 29, 2026
1 of 2 checks passed
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.

BA-081 — Persist hint usage and difficulty analytics

2 participants