Skip to content

Add Discord post-scheduler bot; wire the three bots into the runner - #6

Open
mithileshgau wants to merge 6 commits into
mainfrom
feat/scheduler-and-bot-updates
Open

Add Discord post-scheduler bot; wire the three bots into the runner#6
mithileshgau wants to merge 6 commits into
mainfrom
feat/scheduler-and-bot-updates

Conversation

@mithileshgau

Copy link
Copy Markdown
Collaborator

Summary

Adds a standalone Discord post-scheduler bot and wires it in as the third managed bot alongside the showcase moderator and the Rocket Ralph support bot. Also brings bot.ts up to the current support-bot implementation and tidies .gitignore.

What's included

  • scheduler.ts — new bot: /schedule, /scheduled, /cancel, /timezone, /access, /ping, /help.
    • Redis-backed durable timer (sorted set) — scheduled posts survive restarts.
    • Role-gated: operational commands are use-gated by an in-app allow-list managed via /access (server managers only; default_member_permissions=ManageGuild).
    • Works in any channel; downloads images at schedule time; never pings @everyone.
    • Deps: ioredis + luxon (added to package.json).
  • start-bots.sh / stop-bots.sh / status-bots.sh — manage the scheduler as a third bot; start-bots.sh also ensures the sched-redis container is up.
  • bot.ts — current Rocket Ralph support bot (thread replies, escalation pause with persistence, engine reconnect/recovery).
  • .gitignore — ignore .DS_Store; tidy entries.

Runtime requirements

  • Scheduler: Redis (the sched-redis docker container).
  • Config via .env (gitignored): SCHEDULER_BOT_TOKEN, optional SCHEDULER_GUILD_ID, TIMEZONE, REDIS_URL.

Notes

  • No secrets included — .env is gitignored and the diff was secret-scanned.

🤖 Generated with Claude Code

Discord Bot and others added 6 commits July 8, 2026 00:46
- scheduler.ts: standalone post scheduler (/schedule, /scheduled, /cancel,
  /timezone, /access, /ping, /help); Redis-backed durable timer; role-gated
  via an in-app /access allow-list; usable in any channel.
- start/stop/status-bots.sh: manage the scheduler as a third bot next to
  showcase + support; start-bots.sh also ensures the sched-redis container.
- package.json / package-lock.json: add ioredis + luxon.
- bot.ts: current Rocket Ralph support bot (thread replies, escalation pause
  with persistence, engine reconnect/recovery).
- .gitignore: ignore .DS_Store and tidy entries.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…p prompt

- Gate command visibility to the RocketRide team via ModerateMembers; gate use
  strictly to the team role (server managers still pass).
- Rename /help to /scheduler-help.
- Replace the /scheduler-help AI-assistant prompt with a detailed link/formatting
  spec, sent as a separate message to stay under Discord's 2000-char limit.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The merged pipe used Anthropic (claude-sonnet-4-6), which crashed the bot on
startup here — no Anthropic key is configured in this deployment. Switch back to
the OpenAI (gpt-4-1) pipeline the bot actually runs, keyed by ROCKETRIDE_OPENAI_KEY.
Credentials are referenced by env var name only; no secrets in the file.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…env.example

social.ts: standalone announcer that posts RocketRide's latest YouTube (Data API v3), X (API v2), and Ghost newsletter items to a channel on a Pacific schedule. Per-platform watermark (logs/social-seen.json) so only new items post; X replies and retweets excluded. Redacts API keys from error logs; strict watermark boundary; serialized runs. Manual pass via 'tsx social.ts --social-once [--dry] [--backfill]'.

Rename bot.ts -> support.ts and index.js -> showcase.js for consistent naming; update package.json (main/start) and the runner scripts, which now also manage the new 'social' process.

Add README.md and .env.example (mirrors .env, which stays gitignored).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…1/12 morning

- social.ts: add Instagram fetching (Meta Graph API), registered in SOCIAL_SOURCES.

- Shorten embed cards to brand-icon + linked title + image (drop caption/footer/timestamp).

- Labels now read 'New RocketRide post on X/Instagram', 'New RocketRide video on YouTube', etc.

- Morning schedule 9/10/11 -> 10/11/12 (afternoon 4/5/6 unchanged).

- Add --only <platform> to --social-once for targeted testing; document INSTAGRAM_* in .env.example.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…unner cleanup

- support.ts: main channel → webhook + multi-modal on the LOCAL engine (per-modality
  send → summariser merge), keeping escalation-pause + engine-error suppression
- support-test.ts: new cloud-webhook test bot (ralph + summariser webhooks), multi-modal
- pipelines/rocket-ralph.pipe + summariser.pipe: new webhook RAG + multi-part merge pipes
- social.ts: LinkedIn source (originals only, video thumbnails), X/newsletter descriptions
- start/stop/status-bots.sh: parameterized per-bot start/stop/status (no broad pkill)
- remove unused pipelines (rag, rocket-ralph 1, support.pipe) + migrate.js; refresh .env.example

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.

1 participant