The /setup command: an interactive configuration flow
The primary admin entry point to Ophraxx AI is the /setup slash command, restricted to server administrators and owners. Rather than requiring admins to type configuration values, setup uses a fully interactive Discord UI — three dropdown menus and a save button, all scoped to the admin running the command so other users cannot interfere with their session.
The first dropdown selects the AI channel. Admins can choose any existing text channel in the server, or they can select 'Create a new AI channel for me' — which causes the bot to automatically create a #ophraxx-ai channel with the correct permissions already set (view, send, read history, attach files, and embed links for everyone). The second dropdown enables or disables AI responses globally for the server. The third dropdown toggles whether users can invoke the bot by mentioning it outside the AI channel, or whether AI is restricted to the dedicated channel only.
The setup session is scoped to the guild and admin, times out after 120 seconds of inactivity, and is cleaned up automatically regardless of whether it is saved. Saved configuration is written to our backend and read on every incoming message — so changes take effect the moment the admin clicks save.
Usage tracking and per-guild limits
Every AI interaction is recorded in our usage tracking system. Two separate counters run in parallel: one tracks individual user request counts within a calendar day, the other tracks total guild-wide request counts across the calendar month and accumulates the set of distinct active users.
The current limits are 25 requests per user per day and 3,000 requests per guild per month. These are checked atomically — the count is incremented first, and if the increment pushes it over the limit, it is rolled back and the request is blocked. This prevents race conditions where two simultaneous requests both slip through just under the limit. When a limit is hit, the user receives a clear message explaining which limit was reached and when it resets.
Server admins can check live usage at any time with /ophraxx usage. The command returns an embed showing today's total AI requests across the guild, this month's message count against the 3,000 cap, the number of distinct active users this month, and the remaining monthly allocation — giving admins full visibility into how their server is consuming the platform.
Spam protection and automatic moderation
The bot includes its own spam detection layer that operates independently of any other moderation bots in the server. A sliding window tracks each user's message rate within the AI channel. If the rate exceeds the hard spam threshold — multiple messages fired within an 8-second window — the system declares a hard spam event.
Hard spam triggers a four-step response: the violation is recorded in the user's safety profile, the bot attempts to apply a 60-second Discord timeout to the member using Discord's built-in timeout feature (if it has the necessary permissions), the user is soft-blocked from AI responses for 5 minutes, and a detailed embed is sent to the guild's configured mod log channel. The mod log embed includes the user's tag and ID, the exact message count in the window, whether a Discord timeout was successfully applied, the action taken, the channel where it occurred, and a preview of the message content.
The soft-block system also applies to lower-severity violations. Users who repeatedly trigger content moderation can be soft-blocked without hitting the hard spam threshold. When a soft-blocked user sends a message, the bot replies with exactly how many seconds remain on their block rather than silently ignoring them.
The blacklist system and the first-user experience
The blocklist is a server-side record of user and guild IDs that are permanently removed from AI access. It is checked at every entry point — both the message handler and the slash command handler — meaning blocked accounts cannot reach the AI through any path. The blocklist operates silently — blocked users receive no response and no indication that the block exists.
On the other end of the spectrum, first-time users who interact with the bot receive a welcome DM automatically. The welcome embed introduces Ophraxx AI, links to the website and the community Discord server, and includes a note about AI accuracy limitations. It is sent exactly once per user and never repeated.
Every AI response includes a thumbs-up, thumbs-down, and AI Support button row. Feedback signals from these buttons are tracked per-message and inform ongoing evaluation of response quality across different query types and guild configurations.