Skip to content

Build authoritative Realm Chat V1 - #183

Draft
ael-dev3 wants to merge 1 commit into
agent/realm-chat-legal-contractfrom
agent/realm-chat-spacetimedb-v1
Draft

Build authoritative Realm Chat V1#183
ael-dev3 wants to merge 1 commit into
agent/realm-chat-legal-contractfrom
agent/realm-chat-spacetimedb-v1

Conversation

@ael-dev3

@ael-dev3 ael-dev3 commented Aug 3, 2026

Copy link
Copy Markdown
Owner

Summary

Builds a modern, persistent Realm Chat V1 as a review-only implementation stacked on #178.

The design follows current game-chat patterns—compact gameplay-first UI, unread state, local mute, message-level reporting, and bounded history—while making SpacetimeDB the sole authority for sender identity, timestamps, global ordering, rate limits, idempotency, moderation state, and preserved report context.

What changed

  • adds seven additive protocol-V15 tables with public/private separation
  • adds caller-bound send, history, report, and admin moderation operations
  • enforces exact rolling rate limits, duplicate throttling, bounded Unicode/byte/line policy, and replay-safe send receipts
  • maintains a 128-message public live projection backed by a private authoritative archive
  • preserves original message evidence for moderators while public tombstones remove body content
  • adds a responsive desktop/compact Realm Chat dock with unread handling, load-older pagination, sender cards, locate, local mute, copy, report disclosure, keyboard/focus handling, and Mini App Back integration
  • keeps chat out of the 10,000-cell world snapshot through its own small subscription
  • updates generated/player bindings without exposing private chat tables
  • adds the frozen V15 migration fixture and real disposable upgrade/rollback proof
  • documents the architecture, abuse model, threat model, operational flow, research, and non-goals

Safety and rollout

This PR does not activate or deploy chat.

  • client entry gate remains false
  • server activation compile gate remains false
  • production module publication now fails closed while Realm Chat V1 is review-only
  • no production SpacetimeDB or website state was changed
  • retention/deletion, appeals, moderator staffing/escalation, jurisdiction/age/privacy review, and final launch approval remain explicit blockers

Verification

  • 2,989 application tests passed across 272 files
  • 331 SpacetimeDB authority/migration tests passed
  • protocol-V15 disposable migration proof passed on SpacetimeDB 2.6.1, including populated chat tables, prior-row preservation, rollback refusal, and post-upgrade worker/gameplay exercise
  • generated binding verifier passed
  • production build and asset/Farcaster/exclusion checks passed
  • TypeScript checks passed for client and module
  • committed-HEAD license/cutover guard passed
  • SpacetimeDB production dependencies report no known vulnerabilities
  • diff whitespace and secret-pattern scans passed

Stack

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