{
  "version": "twitch-study-protocol-v1",
  "preparedOn": "2026-11-15",
  "status": "registered_before_formal_collection",
  "studyKind": "first_party_two_part_study",
  "phaseA": {
    "mode": "passive_production_browser_observation",
    "source": "Twitch-A (identity not in published evidence)",
    "syntheticSends": 0,
    "forcedReconnects": 0,
    "method": "salted NFC lowercased rendered author plus NFC whitespace-normalized plain-text signature groups; full rendered content and inline-image alt labels checked separately",
    "nativeProviderIdsAvailable": false,
    "unit": "distinct author-plus-plain-text signature groups, NOT distinct messages",
    "baseline": "exclude every native signature already in pre-start buffers, even if it appears again later; operator baseline can establish prior presence",
    "emptyPlainText": "exclude emote-only and missing-author/body rows; report observation counts",
    "repetition": "same-author same-plain-text repeats collapse; never call these unique comments; co-occurring duplicates and changed content mark ambiguous groups; exclude ambiguous groups from paired-content categories",
    "timing": "sampled first observation, not transport latency",
    "send": "not measured, report null",
    "receipt": "not independently measured without a scoped read-only backend probe; report null, never infer receipt from DOM",
    "render": "presence in rendered TikChat DOM, not proof every row was on screen",
    "order": "retain buffer order transiently and report zero-overlap sampling warnings; no message identity inferred from order alone"
  },
  "phaseB": {
    "mode": "controlled_real_Twitch_on_owner_authorized_channel",
    "status": "waiting_for_own_channel",
    "plannedMessages": 120,
    "sender": "normal browser UI on authorized account, minimum 6 seconds between attempts, slower if actual room settings require",
    "phases": [
      "steady",
      "pre_late_join_negative_control",
      "post_late_join",
      "reconnect_cycle_1",
      "reconnect_cycle_2",
      "reconnect_cycle_3",
      "repeated_payload_distinct_markers"
    ],
    "faults": "outside production; isolated test connection only, defined mechanism and exact runtime hashes frozen before start; local synthetic-provider fixtures reported separately, never as real Twitch tests",
    "stages": [
      "UI send attempt and any separately evidenced acceptance",
      "visible in an independent native Twitch chat tab",
      "backend persisted normalized event with receivedAt (not raw ingress)",
      "rendered in operator DOM"
    ],
    "backend": "scope by own tenant and session, indexed bounded read only, no unrelated comments/identifiers exported; no credentials read; freeze approved probe before the run",
    "reconnect": "closing/reloading the operator tab is only a browser recovery test, not a provider reconnect",
    "lateJoin": "pre-join messages negative control; count post-confirmed-join messages separately; do not promise backfill"
  },
  "common": {
    "targetReadIntervalSeconds": 5,
    "progressMinutes": 5,
    "unresolvedThresholdSeconds": 60,
    "finalGraceSeconds": 90,
    "until": "user stop or confirmed broadcast end; maximum 4 hours or 500000 in-memory groups",
    "noDeployments": true,
    "noServiceRestarts": true,
    "noProductionFaultInjection": true,
    "extraProductionCollectors": 0,
    "extraProductionApiPolling": false,
    "publish": "aggregate records, relative times, exact product release and hashes, protocol/instrument SHA256, error taxonomy and limitations; no channel URL, viewer identity, raw comments or message hashes",
    "protocolChanges": "freeze revisions before first formal sample; after-start deviations appended with reason and affected interval, never rewritten as pre-registered",
    "abort": [
      "scope cannot be established",
      "DOM contract changed",
      "active search/filter cannot be excluded",
      "browser unavailable",
      "user stop",
      "local memory limit reached",
      "production version changes: close segment and report separately"
    ]
  },
  "officialReferences": [
    {
      "url": "https://dev.twitch.tv/docs/chat/",
      "checkedOn": "2026-11-15",
      "scope": "chat rate limits; current ordinary-account cap 20 per 30 seconds and 1 per second per channel; proposed pace is slower"
    },
    {
      "url": "https://dev.twitch.tv/docs/chat/irc/",
      "checkedOn": "2026-11-15",
      "scope": "message IDs, emotes, ACTION, RECONNECT and ROOMSTATE concepts"
    }
  ]
}
