Skip to content

Commit 92fb2b9

Browse files
authored
Merge pull request #7 from managedcode/codex/remove-obs-go-live-streaming-modules
[codex] Refactor Go Live streaming modules
2 parents 3369d8b + 23dad32 commit 92fb2b9

File tree

81 files changed

+4106
-2256
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

81 files changed

+4106
-2256
lines changed

docs/ADR/ADR-0002-go-live-operational-studio-surface.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ flowchart LR
153153
| --- | --- | --- | --- |
154154
| TST-001 | Open `Go Live` with persisted destinations | Component | Ready summaries render from persisted settings without inline provider forms |
155155
| TST-002 | Select the secondary camera and take it live | UI | Program monitor switches first, live preview switches only after take-to-air |
156-
| TST-003 | Arm LiveKit, YouTube, OBS, and recording from the studio surface | UI | Quick toggles persist and reload into the operational studio |
156+
| TST-003 | Arm LiveKit, VDO.Ninja, YouTube, and recording from the studio surface | UI | Quick toggles persist and reload into the operational studio |
157157

158158
## References
159159

docs/ADR/ADR-0003-go-live-broadcast-spine-and-relay-architecture.md

Lines changed: 105 additions & 251 deletions
Large diffs are not rendered by default.

docs/Architecture.md

Lines changed: 41 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -95,15 +95,15 @@ flowchart LR
9595
| `Editor` | TPS authoring surface | Creates and reshapes scripts with structure-aware tooling | `src/PrompterOne.Shared/Editor`, `src/PrompterOne.Core/Editor`, `src/PrompterOne.Core/Tps` | source editing UI, toolbar actions, front matter, TPS transforms | shell navigation policy, teleprompter playback, live runtime wiring |
9696
| `Learn` | RSVP rehearsal mode | Trains delivery with timing and context | `src/PrompterOne.Shared/Learn`, `src/PrompterOne.Core/Rsvp` | ORP playback, rehearsal pacing, next-phrase context | document storage, scene routing, destination configuration |
9797
| `Teleprompter` | Read-mode playback surface | Presents the script for live reading with camera-backed composition | `src/PrompterOne.Shared/Teleprompter` | reading layout, background camera composition, runtime reading flow | script persistence rules, destination setup screens |
98-
| `GoLive` | Operational browser studio surface | Operates the composed program feed and exposes honest live/runtime state | `src/PrompterOne.Shared/GoLive`, `src/PrompterOne.Core/Streaming` | studio layout, left-rail source control, selected vs on-air source state, local recording control, standalone upstream-spine operation, right-rail telemetry and downstream health summaries | provider credential editing, source inventory, per-device sync definitions, PrompterOne-managed server media processing, unrelated editor or library concerns |
99-
| `Settings` | Device, scene, and provider setup surface | Configures the inputs, sync, quality, and persisted destinations that `Go Live` operates | `src/PrompterOne.Shared/Settings`, `src/PrompterOne.Core/Media` | device selection UI, source inventory, scene transforms, microphone gain/delay/sync, quality profiles, active spine choice, provider credentials/endpoints, scene persistence flows | live output orchestration policy, document editing |
98+
| `GoLive` | Operational browser studio surface | Operates the composed program feed and exposes honest live/runtime state | `src/PrompterOne.Shared/GoLive`, `src/PrompterOne.Core/Streaming` | studio layout, left-rail source control, selected vs on-air source state, browser-owned program capture, local recording control, concurrent transport publish state, right-rail telemetry and downstream health summaries | provider credential editing, source inventory, per-device sync definitions, PrompterOne-managed server media processing, unrelated editor or library concerns |
99+
| `Settings` | Device, scene, and transport setup surface | Configures the inputs, sync, capture profile, transport connections, and downstream targets that `Go Live` operates | `src/PrompterOne.Shared/Settings`, `src/PrompterOne.Core/Media`, `src/PrompterOne.Core/Streaming` | device selection UI, source inventory, scene transforms, microphone gain/delay/sync, program-capture profiles, recording defaults, transport connection profiles, downstream target profiles, scene persistence flows | live output orchestration policy, document editing |
100100
| `Storage` | Browser persistence and cloud transfer orchestration | Keeps scripts and settings local-first while exposing provider-backed import/export | `src/PrompterOne.Shared/Storage`, `src/PrompterOne.Shared/Library/Services/Storage` | browser `IStorage` and VFS registration, authoritative browser repositories for scripts/folders, provider credential persistence, scripts/settings snapshot transfer | routed page layout, teleprompter rendering, video-stream upload workflows |
101101
| `Cross-Tab Messaging` | Same-origin browser runtime coordination | Lets separate WASM tabs coordinate browser-owned state without a backend | `src/PrompterOne.Shared/AppShell/Services`, `src/PrompterOne.Shared/Settings/Services`, `src/PrompterOne.Shared/wwwroot/app` | `BroadcastChannel` bridge, typed envelopes, settings fan-out, same-origin tab sync | server state, cross-origin transport, collaborative editor conflict resolution |
102102
| `Diagnostics` | Error and operation feedback layer | Makes recoverable and fatal issues visible in the shell | `src/PrompterOne.Shared/Diagnostics` | banners, error boundary reporting, operation status wiring | owning business logic of the failing feature |
103103
| `Localization` | Culture and UI text contract | Keeps supported runtime languages consistent and browser-driven | `src/PrompterOne.Shared/Localization`, `src/PrompterOne.Core/Localization` | text catalogs, culture bootstrap, supported culture rules | feature behavior or screen-specific layout ownership |
104104
| `Workspace` | Active script/session state model | Gives editor, learn, read, and go-live one shared script context | `src/PrompterOne.Core/Workspace` | loaded script state, previews, estimated duration, active session metadata | feature-specific rendering details |
105105
| `Media` | Browser media and scene domain | Models cameras, microphones, transforms, and audio bus state | `src/PrompterOne.Core/Media`, `src/PrompterOne.Shared/Media` | media device models, scene state, browser media interop | routed screen layout ownership |
106-
| `Streaming` | Output and target routing domain | Defines how one composed program feed is published from the browser and which external targets are genuinely reachable without a PrompterOne backend | `src/PrompterOne.Core/Streaming` | broadcast-spine selection models, standalone transport constraints, target descriptors, routing normalization | Razor UI or page layout concerns |
106+
| `Streaming` | Program capture, transport, and target routing domain | Defines how one composed program feed is described, which source/output modules can attach to it, and which external targets are genuinely reachable without a PrompterOne backend | `src/PrompterOne.Core/Streaming` | program-capture profiles, source/output module contracts, transport connection profiles, downstream target descriptors, routing normalization, standalone transport constraints | Razor UI or page layout concerns |
107107
| `tests` | Verification layers | Protects behavior with browser, component, and core assertions | `tests/*` | acceptance flows, component contracts, domain verification | production logic ownership |
108108

109109
## Build Governance
@@ -142,6 +142,43 @@ flowchart TD
142142

143143
- Same-origin tab coordination is a browser-runtime concern owned in `PrompterOne.Shared`; it uses `BroadcastChannel` as a best-effort browser transport and does not change the browser-only runtime shape.
144144

145+
## Go Live Streaming Boundaries
146+
147+
```mermaid
148+
flowchart LR
149+
Settings["Settings<br/>program capture, recording, transport profiles, targets"]
150+
Sources["Source modules<br/>local scene, LiveKit intake, VDO.Ninja intake"]
151+
Program["Program capture<br/>one browser-owned MediaStream"]
152+
Recording["Recording sink<br/>MediaRecorder"]
153+
LiveKit["LiveKit output module"]
154+
Vdo["VDO.Ninja output module"]
155+
Targets["Distribution targets<br/>YouTube / Twitch / Custom RTMP"]
156+
GoLive["Go Live<br/>operate and observe"]
157+
158+
Settings --> Sources
159+
Settings --> Program
160+
Settings --> LiveKit
161+
Settings --> Vdo
162+
Settings --> Targets
163+
Sources --> Program
164+
Program --> Recording
165+
Program --> LiveKit
166+
Program --> Vdo
167+
LiveKit --> Targets
168+
Vdo --> Targets
169+
GoLive --> Sources
170+
GoLive --> Program
171+
GoLive --> Recording
172+
GoLive --> LiveKit
173+
GoLive --> Vdo
174+
GoLive --> Targets
175+
```
176+
177+
- `Go Live` now works through `sources + program + sinks`.
178+
- The browser compositor owns one canonical program feed, and all active sinks reuse that feed instead of building separate capture graphs.
179+
- `LiveKit` and `VDO.Ninja` may publish concurrently when both transport connections are armed.
180+
- Downstream targets are capability-gated by the bound transport connections; the browser UI must block unsupported paths instead of pretending generic RTMP fan-out exists.
181+
145182
## Cross-Tab Runtime Contracts
146183

147184
```mermaid
@@ -508,7 +545,7 @@ flowchart LR
508545
## Constraints
509546

510547
- The runtime must remain backend-free.
511-
- `Go Live` may operate only one upstream browser broadcast spine per session; direct parallel browser fan-out to multiple platform transports is outside the allowed boundary.
548+
- `Go Live` may operate multiple concurrent browser publish transports when the operator explicitly arms them, but every active transport must still consume the same canonical browser-owned program feed.
512549
- `Go Live` must not require any PrompterOne-owned backend, relay, ingest layer, or media server; only third-party browser-facing transport infrastructure is allowed.
513550
- Browser-language localization must default to English and support `en`, `uk`, `fr`, `es`, `pt`, and `it`.
514551
- Russian is intentionally unsupported and must fall back to English.

0 commit comments

Comments
 (0)