Commit Graph

44 Commits

Author SHA1 Message Date
hikari d2be204188 chore: remove news feed feature
Node.js CI / CI (pull_request) Failing after 11s
Security Scan and Upload / Security & DefectDojo Upload (pull_request) Successful in 50s
Removes the hourly RSS news posting functionality, including the
postNews module, rss interface, lastRssItems tracking, and the
rss-parser dependency.
2026-03-09 13:11:55 -07:00
hikari 1ebe240475 feat: add slash commands and context menu command (#16)
Node.js CI / CI (push) Successful in 28s
Security Scan and Upload / Security & DefectDojo Upload (push) Successful in 2m41s
## Summary

This PR adds a suite of slash commands and a context menu command to Amari, along with shared utilities and quality improvements across the board.

### New Commands
- **`/create-issue`** — generates a GitHub issue on a specified repo using AI-drafted content (title, description, acceptance criteria)
- **`/create-task`** — creates a task in Naomi's Leantime instance with an AI-drafted description and configurable priority
- **`/onboard-mentee`** — automates the mentorship onboarding flow (GitHub invite, forum thread, role assignment)
- **Forward to Owner** (context menu, message command) — forwards any message to Naomi with action buttons (contributed by @teklu)

### Shared Utilities
- **`src/utils/makeAiRequest.ts`** — a single wrapper around the Anthropic SDK for all AI calls, with Amari's personality prompt baked in and full error handling
- **`src/events/handleInteractionCreate.ts`** — extracted interaction handler (was inline in `index.ts`) to keep complexity under control

### Quality Improvements
- `ephemeral: true` → `flags: [ MessageFlags.Ephemeral ]` (deprecated API removed)
- Full `try/catch` + `logger.error` audit across all modules (`logMenteeJoin`, `checkAchievements`, `processMentorshipRole`, `processGitHubEvent`)
- `deployGlobal.ts` replaced with a static `commands.json` payload for manual registration
- Amari's personality prompt updated to reflect her actual character — warm, observant, and relentlessly caring

### Notes
- `CLIENT_ID` is needed in 1Password at `op://Environment Variables - Naomi/Amari/client id` for the `commands.json` registration call
- The forward-to-owner command (PR #13, contributed by @teklu) is fully preserved with original commit authorship

 This PR was created with help from Hikari~ 🌸

Co-authored-by: Naomi Carrigan <commits@nhcarrigan.com>
Co-authored-by: Teklu <tekluabayneh@gmail.com>
Reviewed-on: #16
Co-authored-by: Hikari <hikari@nhcarrigan.com>
Co-committed-by: Hikari <hikari@nhcarrigan.com>
2026-03-03 15:05:09 -08:00
hikari 5e149a29e4 feat: mentorship improvements and name mention notifications (#14)
Node.js CI / CI (push) Successful in 36s
Security Scan and Upload / Security & DefectDojo Upload (push) Successful in 1m27s
## Summary

- **Name/title mention notifications**: Amari now notifies Naomi when a message contains her name, common nicknames (`nomi`, `nao`, `nae`, `naonao`), or honorifics (`goddess`, `queen`, `mistress`, `your/her majesty`, `your/her highness`). Uses the same cooldown logic as mention forwarding.
- **Simplified mentee onboarding**: Replaced the lengthy welcome message with a concise prompt asking the new mentee to ping Naomi with their GitHub username and name.
- **Removed offboard notification**: `logMenteeLeave` now only logs a metric silently — no more "user must be offboarded" messages in the channel.
- **Deduplicated welcome messages**: Welcomed mentee IDs are persisted to `data/welcomed.txt` so the onboarding message is only ever sent once, even if the role is re-assigned.

## Test plan

- [ ] Assign mentorship role to a user and confirm the new onboarding message appears
- [ ] Re-assign the role to the same user and confirm no duplicate message is sent
- [ ] Remove a mentee from the server and confirm no offboard message is posted
- [ ] Send a message containing a matched name/honorific and confirm Naomi receives a DM forwarding it

 This PR was created with help from Hikari~ 🌸

Co-authored-by: Naomi Carrigan <commits@nhcarrigan.com>
Reviewed-on: #14
Co-authored-by: Hikari <hikari@nhcarrigan.com>
Co-committed-by: Hikari <hikari@nhcarrigan.com>
2026-03-02 16:03:14 -08:00
naomi 0b19d91444 feat: add alpha and omega reminder
Node.js CI / CI (push) Successful in 27s
Security Scan and Upload / Security & DefectDojo Upload (push) Successful in 1m29s
2026-01-08 17:02:02 -08:00
naomi 74bccd903d chore: no more ts reminders
Node.js CI / CI (push) Successful in 28s
Security Scan and Upload / Security & DefectDojo Upload (push) Successful in 51s
2026-01-08 08:48:05 -08:00
naomi 402acffb5c fix: properly handle duplicated channels
Node.js CI / CI (push) Successful in 27s
Security Scan and Upload / Security & DefectDojo Upload (push) Successful in 1m31s
2025-12-30 11:59:57 -08:00
naomi e6112f57cb feat: add tags for new forum channels
Security Scan and Upload / Security & DefectDojo Upload (push) Failing after 24s
Node.js CI / Lint and Test (push) Successful in 26s
2025-12-17 17:18:17 -08:00
naomi 72b7571b92 fix: fcc sprint notifications 2025-12-17 16:27:27 -08:00
naomi 9c53c22130 feat: add reminders for fcc sprints
Node.js CI / Lint and Test (push) Successful in 25s
2025-12-16 18:04:07 -08:00
naomi 9d9d0809d7 feat: update form logic for new platform
Node.js CI / Lint and Test (push) Successful in 26s
2025-12-10 14:52:36 -08:00
naomi 53274ec38c feat: auto-tag the new community fora
Node.js CI / Lint and Test (push) Successful in 1m29s
2025-12-09 12:24:55 -08:00
naomi 9ada4b9cbe feat: prep for mentorship to be self-assignable
Node.js CI / Lint and Test (push) Successful in 28s
2025-12-03 15:27:41 -08:00
naomi 34d71c73aa feat: remove bullying because science did her resume
Node.js CI / Lint and Test (push) Successful in 50s
And I am very proud of her!
2025-11-12 10:05:50 -08:00
naomi 532461202a feat: bully science for failing to complete her resume
Node.js CI / Lint and Test (push) Successful in 50s
2025-11-11 09:32:54 -08:00
naomi 50e46368ed feat: prepare to resume mentorship programme
Node.js CI / Lint and Test (push) Successful in 52s
2025-10-30 17:50:03 -07:00
naomi a132018b9e chore: disable sprint and mentorship reminders
Node.js CI / Lint and Test (push) Successful in 53s
I am OOO so we do not need these.
2025-10-17 16:29:28 -07:00
naomi 5cadb9bbee feat: analytics
Node.js CI / Lint and Test (push) Successful in 49s
2025-10-08 08:41:37 -07:00
naomi 36ad30e4a2 feat: let amari handle my progress reminders
Node.js CI / Lint and Test (push) Successful in 50s
2025-10-06 16:53:41 -07:00
naomi 593855d967 feat: filter out RSS posts that violate our Code of Conduct.
Node.js CI / Lint and Test (push) Successful in 49s
2025-10-04 13:48:01 -07:00
naomi d6753ca36f feat: add new form ids for webhooks
Node.js CI / Lint and Test (push) Successful in 54s
2025-09-29 13:02:35 -07:00
naomi 76ec0f5566 chore: no more responding
Node.js CI / Lint and Test (push) Successful in 46s
2025-09-15 12:58:50 -07:00
naomi 996cde5e2f feat: notify when naomi earns achievements
Node.js CI / Lint and Test (push) Successful in 48s
2025-09-10 13:21:08 -07:00
naomi bfaf757d3e feat: track if mentees join or leave
Node.js CI / Lint and Test (push) Successful in 45s
2025-09-02 19:34:24 -07:00
naomi 9cc8f1fdbb feat: send onboarding message when mentorship role granted
Node.js CI / Lint and Test (push) Successful in 46s
2025-09-02 19:11:43 -07:00
naomi 7facefccd8 feat: track when naomi is recently active
Node.js CI / Lint and Test (push) Successful in 48s
2025-09-02 14:14:03 -07:00
naomi 994f50c174 feat: protect github route with secret too
Node.js CI / Lint and Test (push) Successful in 44s
2025-08-27 19:04:06 -07:00
naomi d5c0abe4d8 feat: webhook for forms
Node.js CI / Lint and Test (push) Successful in 45s
2025-08-27 18:55:22 -07:00
naomi b92fe0a730 fix: issue event type
Node.js CI / Lint and Test (push) Successful in 51s
2025-08-27 18:09:15 -07:00
naomi 8275b36287 chore: more logging
Node.js CI / Lint and Test (push) Successful in 47s
2025-08-27 18:07:37 -07:00
naomi 1b7f83f335 feat: auto-assign issues and prs to naomi
Node.js CI / Lint and Test (push) Successful in 42s
2025-08-27 17:58:28 -07:00
naomi c48242a141 feat: set up github endpoint
Node.js CI / Lint and Test (push) Successful in 38s
2025-08-27 17:13:29 -07:00
naomi d51b1bed89 chore: use full avatar
Node.js CI / Lint and Test (push) Successful in 51s
2025-08-25 17:00:31 -07:00
naomi 06eba7ea2f fix: actually cache the last news post ids
Node.js CI / Lint and Test (push) Successful in 40s
2025-08-22 12:18:31 -07:00
naomi 1d4f0af6f8 feat: support discussion forum
Node.js CI / Lint and Test (push) Successful in 43s
2025-08-21 12:17:28 -07:00
naomi 1346a29a1f fix: cache user data, do daily role sweep
Node.js CI / Lint and Test (push) Successful in 38s
2025-08-20 16:35:01 -07:00
naomi 4611b13465 feat: grant role when user applies our tag
Node.js CI / Lint and Test (push) Successful in 39s
2025-08-20 16:09:37 -07:00
naomi 186414e96a feat: pull from hackernews
Node.js CI / Lint and Test (push) Successful in 40s
2025-08-20 13:58:03 -07:00
naomi 19ae5eded8 feat: manage tags in resume channel
Node.js CI / Lint and Test (push) Successful in 38s
2025-08-20 12:51:44 -07:00
naomi b5c19abb52 feat: syndicate freeCodeCamp news posts 2025-08-20 12:23:53 -07:00
naomi 344548c5d2 feat: ability to mark dms as resolved
Node.js CI / Lint and Test (push) Successful in 37s
2025-08-19 18:19:20 -07:00
naomi 3e765b3144 fix: do not attempt to duplicate tags
Node.js CI / Lint and Test (push) Successful in 34s
2025-08-19 18:13:46 -07:00
naomi 8652ac95df fix: broke html
Node.js CI / Lint and Test (push) Successful in 36s
2025-08-19 17:23:47 -07:00
naomi 266cb5ecd0 fix: new port
Node.js CI / Lint and Test (push) Successful in 34s
2025-08-19 17:21:50 -07:00
naomi a05de6ba2a feat: initial prototype
Node.js CI / Lint and Test (push) Successful in 37s
2025-08-19 17:16:42 -07:00