Add MLAI Championships coworking leaderboard#163
Open
ceejaymoss wants to merge 1 commit into
Open
Conversation
Adds a public coworking_leaderboard intent that ranks members by booking count over a window (default last 7 days) and renders a celebratory Slack message with medals and mentions. Triggered by phrases like "MLAI championships", "leaderboard", "who came in the most this week". Backend support requires include_users=true on the coworking report endpoint; missing/empty users degrade to a friendly empty-state. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
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.
Summary
coworking_leaderboardRoo intent — triggered by phrases like "MLAI championships", "leaderboard", "who came in the most this week" — that ranks members by coworking bookings over a window (default last 7 days) and renders a celebratory Slack message with medals 🥇🥈🥉 and<@user>mentions.get_coworking_report) extended withinclude_users=Truekwarg; ifmlai-backenddoesn't (yet) ship ausersarray, Roo degrades to a friendly empty-state rather than crashing.Context
Yana asked in Slack whether Roo could "extract specific users from the data… 'MLAI championships - who's come in the most in the last week / month'… and just highlight the community". This implements the Roo-side intent + formatter; the backend change to populate per-user data is tracked separately (see README admin setup section).
What's in the PR
roo/clients/mlai_backend.py—include_userskwarg onget_coworking_reportroo/skills/executor.py— intent routing, handler, helpers (_is_coworking_leaderboard_request,_parse_leaderboard_limit,_coworking_leaderboard_label,_format_coworking_leaderboard)roo/agent.py+skills/mlai_points/SKILL.md— fast-path trigger phrasesroo/tests/test_coworking_leaderboard.py(14 tests) + extensions totest_mlai_backend_client.pyandtest_agent_routing.py— 67 tests passingREADME.md— admin setup section documenting the manual Slack-channel +mlai-backendendpoint steps that have to happen outside this repoTest plan
?include_users=truesupport to/api/v1/points/coworking/report/#mlai-championshipsand invites Roo#mlai-championships, run@Roo MLAI championships this weekand confirm the medals/mentions/footer render correctly@Roo top 10 members last month— confirm range parsing + limit overrideusersmissing, confirm empty-state copy renders instead of an error🤖 Generated with Claude Code