Federative livestreaming

Mix cameras and guests into an interactive live stream.

Cameras and guests connect in a shared WebRTC lobby, where their video feeds are mixed into a single live stream. Shig is open-source software for interactive live streaming, built for the Fediverse.

Shig live production lobby with guests and multiple camera perspectives of a handball event, alongside the audience view.
Multiple perspectives. One live stream.

Background photo by Alina Grubnyak on Unsplash

For communitiesOpen sourceOwn infrastructureFediverse

Interactive Live Streaming

Shig combines WebRTC and Media over QUIC for real-time, interactive live streams. This enables use cases such as webinars and live event broadcasts with minimal setup.

Federation through ActivityPub

ActivityPub connects Shig with other platforms in the Fediverse, allowing communities to discover and share live events across independently operated instances.

Scale for your community, not the entire Fediverse.

Both Shig’s lobby and its media relay servers work with other instances, sharing the load across the network so each instance only needs to support its own community. Your instance serves its own users using its own resources.

Technology

Media over QUIC as a WebRTC stream fan-out

Shig’s core consists of two parts. The lobby receives streams via WebRTC and works like a video conference, allowing different sources to be mixed and participants to interact in real time. The mixed stream is then distributed from the lobby to a large audience via Media over QUIC, in near real time. Viewers can join the lobby and become part of the live stream, moving from watching to participating.

WebRTC stream fan-out via Media over QUIC Cameras and guests connect through a Rust-based SFU in a shared WebRTC lobby. Their streams are mixed into a regular WebRTC stream. The SFU converts the mixed stream to Media over QUIC and forwards it to relay servers for distribution to the audience. Simplified architecture. Connect Interact Distribute Watch SFU Rust-based WebRTC lobby Cameras, guests & live mixing MoQ relays Live stream distribution Live audience WebRTC stream fan-out via Media over QUIC Cameras and guests connect through a Rust-based SFU in a shared WebRTC lobby. Their streams are mixed into a regular WebRTC stream. The SFU converts the mixed stream to Media over QUIC and forwards it to relay servers for distribution to the audience. Simplified architecture. WebRTC lobby Cameras, guests & live mixing SFU Rust-based MoQ relays Live audience

WebRTC lobby · Media over QUIC · Relay servers · Live audience

Decentralized cascading

The SFU is designed for decentralized cascading from the ground up. Its signaling relies entirely on HTTP rather than stateful signaling connections such as the WebSockets commonly used in centralized conferencing systems. The lobby state is decentralized and distributed by design, allowing users from different instances to join the same lobby through their respective SFUs.

Roadmap

  1. Foundation

    The basic setup for live streaming and running a community server.

    • A WebRTC lobby, live mixing and stream distribution through Media over QUIC.✓ Done
    • An admin dashboard for managing the community server.✓ Done
    • A channel dashboard where users can manage their channels and view their live streams.✓ Done
    • Admin controls for allowing or disabling user logins.✓ Done
    • Two-factor authentication.Planned
    • Admin-controlled registration.Planned
    • Current live viewer count.In progress
  2. Federation

    In progress

    Connect Shig with the Fediverse through ActivityPub so live events can be discovered and shared across platforms.

    • Integration of Lemmy’s ActivityPub library.In progress
    • Monitoring of federated servers.In progress
    • Search for and manage federated servers in the admin dashboard.In progress
    • Persistent storage of live stream recordings in PeerTube.Planned
  3. Distributed streaming

    Connect lobbies and media relays across instances through cascading, with each instance serving its own community.

    • Cascading WebRTC lobbies across instances.Planned
    • Distributed streaming catalog.Planned
    • Distributed stream delivery through cascading media relays.Planned
    • Media watermarking for live streams.Planned
    • End-to-end encryption.Planned
  4. Bot-resistant community

    Planned

    Develop ontology-based bot detection to help identify automated accounts and protect the community from bots.

Shig: distribute and clone live streams among Fediverse instances

Talk at FOSDEM 2024

In the talk at FOSDEM’24, we demonstrated how interactive live streaming is possible within the Fediverse. Towards the end, it became evident how crucial bandwidth estimation is, and this will be the next major feature in Shig.

Watch the talk