Inspiration

PulseGuard was inspired by the way Reddit threads can go from normal discussion to full flame war in minutes. Moderators often discover the problem too late, after reports pile up and the comment section has already become hostile. At the same time, fast comment velocity does not always mean something is wrong. Some viral threads are healthy, funny, or genuinely useful.

The idea was to build a system that watches for both speed and toxicity, so communities can contain dangerous spikes without punishing healthy engagement.

What it does

PulseGuard is an autonomous viral thread containment engine. It monitors active posts, tracks comment velocity in real time, and analyzes recent comments when a thread crosses configurable thresholds.

If a thread is moving quickly and appears toxic, PulseGuard escalates through a DEFCON-style protocol. Lower levels alert moderators through modmail. The highest level can lock the thread, post a sticky explanation, and notify the mod team.

PulseGuard monitors subreddit posts in real time and tracks comment velocity using Redis sorted sets. When a post crosses configurable velocity thresholds, it evaluates recent comments with an optional BYOK AI provider such as Gemini or OpenAI. If the thread is moving quickly and appears toxic, PulseGuard escalates through a DEFCON-style protocol.

DEFCON 3 sends a modmail warning. DEFCON 2 sends an urgent modmail alert. DEFCON 1 locks the thread, posts a sticky moderator comment, and alerts the team. The included dashboard shows live monitored posts, incident history, thresholds, settings, and API-key configuration.

The dashboard shows live monitored threads, incident history, settings, thresholds, and API-key configuration.

How we built it

PulseGuard was built with Devvit, TypeScript, Hono, Redis Sorted Sets, Reddit event triggers, scheduled jobs, and a custom webview dashboard.

Redis Sorted Sets track comment timestamps for sliding-window velocity calculations. Devvit event handlers update monitoring data as comments arrive. When velocity crosses a threshold, PulseGuard can call an optional BYOK AI provider such as Google Gemini or OpenAI to classify recent comments for toxicity and escalation risk.

Challenges we ran into

The biggest challenge was avoiding false positives. A fast-moving thread is not automatically bad, so PulseGuard needed a two-step pipeline: velocity first, context second.

Another challenge was designing the escalation system so it felt useful but not reckless. The app has configurable thresholds and different DEFCON levels, so moderators can decide how aggressive containment should be for their community.

Accomplishments that we're proud of

I’m proud that PulseGuard turns a painful moderation problem into a real-time safety workflow. It does not just wait for reports; it watches the shape of a thread as it develops.

The SOC-style dashboard is also something I’m proud of. It gives moderators a clear view of active monitors, incidents, and settings directly inside Reddit.

What we learned

I learned how to build real-time moderation logic with Devvit events, Redis sliding windows, scheduled jobs, modmail alerts, and embedded dashboards. I also learned that moderation automation has to be careful: the best systems combine signals instead of acting on one metric alone.

What's next for PulseGuard

Next, I would add subreddit-specific toxicity calibration, moderator feedback loops, per-thread incident timelines, better analytics for repeated brigading patterns, and integration with subreddit rules so sticky comments can be more community-specific.

Built With

Share this project:

Updates

posted an update

Changes made:

  • Menu items already use forUserType: "moderator".
  • Added server-side moderator permission checks using Reddit moderator permissions.
  • Dashboard, monitor, incident, and incident-resolution data now require posts or all permission.
  • Settings, dashboard creation, API-key save/test/delete actions now require config or all permission.
  • Manual scans require posts or all permission.
  • Non-moderators opening the webview now receive an access-restricted view and are not shown moderator data.
  • Added a Delete Saved Key action for Gemini/OpenAI keys.
  • Updated the README and public Privacy/Terms wiki pages with data practices, external AI processing, retention, moderator permissions, and API-key deletion details.

The fixed version is published/submitted for review as 0.0.7 and installed on r/pulseguard_dev_dev.

Privacy: https://www.reddit.com/r/pulseguard_dev_dev/wiki/privacy/ Terms: https://www.reddit.com/r/pulseguard_dev_dev/wiki/terms/

Log in or sign up for Devpost to join the conversation.