{"id":43297875,"url":"https://github.com/tatolab/streamlib","last_synced_at":"2026-04-19T18:02:27.916Z","repository":{"id":320041458,"uuid":"1078456783","full_name":"tatolab/streamlib","owner":"tatolab","description":"Real-time streaming library for Rust. Zero FFmpeg/GStreamer dependencies. GPU-accelerated, headless-capable, cross-platform.","archived":false,"fork":false,"pushed_at":"2026-03-25T00:43:30.000Z","size":66743,"stargazers_count":5,"open_issues_count":48,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-03-25T15:55:51.635Z","etag":null,"topics":["audio","cross-platform","gpu","headless","livestreaming","low-latency","media","metal","real-time","rust","streaming","video","video-processing","webrtc","wgpu","whep","whip"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tatolab.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-10-17T19:05:15.000Z","updated_at":"2026-03-25T00:04:04.000Z","dependencies_parsed_at":"2026-01-01T05:09:03.526Z","dependency_job_id":"2a06e04c-c03c-4471-9355-ea47da2c3b27","html_url":"https://github.com/tatolab/streamlib","commit_stats":null,"previous_names":["tato123/streamlib","tatolab/streamlib"],"tags_count":25,"template":false,"template_full_name":null,"purl":"pkg:github/tatolab/streamlib","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tatolab%2Fstreamlib","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tatolab%2Fstreamlib/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tatolab%2Fstreamlib/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tatolab%2Fstreamlib/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tatolab","download_url":"https://codeload.github.com/tatolab/streamlib/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tatolab%2Fstreamlib/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31292639,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-01T21:15:39.731Z","status":"ssl_error","status_checked_at":"2026-04-01T21:15:34.046Z","response_time":53,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["audio","cross-platform","gpu","headless","livestreaming","low-latency","media","metal","real-time","rust","streaming","video","video-processing","webrtc","wgpu","whep","whip"],"created_at":"2026-02-01T19:13:26.475Z","updated_at":"2026-04-01T22:20:37.200Z","avatar_url":"https://github.com/tatolab.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# StreamLib\n\nA real-time processing framework for building applications where audio, video, and data flow together continuously.\n\n**What does \"streaming\" mean here?** Not broadcasting to Twitch. Not just playing video files. StreamLib treats streaming as *continuous real-time data flow*—like electricity through a circuit. Audio, video, sensor data, AI model outputs, or any combination flowing through your application simultaneously.\n\n**Zero external dependencies on GStreamer, FFmpeg, or similar frameworks.** Unlike traditional media libraries that focus on encoding and decoding files, StreamLib is a processing framework. Connect inputs to processors to outputs. Data flows through in real-time. Build anything from video conferencing to robot vision to multi-modal AI agents.\n\n## Vision\n\nStreamLib is building a truly headless processing framework that requires no display server or window system. Run the same code on headless servers, embedded devices, edge compute, or full GUI applications.\n\nThis is an alternative to solutions like NVIDIA DeepStream that require CUDA and lock you into specific hardware. StreamLib uses platform-native APIs (Metal, Vulkan, DirectX) to deliver GPU acceleration without vendor lock-in.\n\n**Inspired by game engine architecture.** Like Unreal Engine enables cross-platform game development, StreamLib applies the same principles to real-time processing. A unified framework that abstracts platform differences, letting you write once and deploy anywhere.\n\n**Target environments:**\n- Headless cloud servers (no X11/Wayland required)\n- Embedded devices and edge compute\n- Desktop applications with full GUI\n- Mobile devices (iOS, Android planned)\n\n**Language support (roadmap):**\n- Rust (native, available now)\n- Python (planned, separate repository)\n- TypeScript (planned)\n\nAll platforms supported out of the box—Linux, macOS, Windows—without convoluted setup. Every processor is designed to be cross-platform from the start.\n\n## Features\n\n- **Multi-modal by design** - Audio, video, and arbitrary data flow through the same graph. Build applications that see, hear, and process data simultaneously\n- **Graph-based processing** - Connect processors into pipelines. Data flows from inputs through processors to outputs, like nodes in a visual programming environment\n- **Zero legacy dependencies** - No GStreamer, FFmpeg, or libav. Pure Rust with platform-native APIs\n- **GPU-accelerated** - Hardware-accelerated video encoding/decoding via Metal (macOS/iOS) and VideoToolbox\n- **Real-time audio** - Low-latency audio processing with CLAP plugin support\n- **Built for AI agents** - Designed for applications where AI models need to perceive and act on live data\n- **Cross-platform** - See platform support table below\n\n## Platform Support\n\n| Platform | Status | Notes |\n|----------|--------|-------|\n| macOS | ✅ Supported | Primary development platform |\n| iOS | 🚧 Partial | Core functionality works |\n| Linux | 📋 Planned | Up next |\n| Windows | 📋 Planned | Up next |\n\n## Quick Start\n\nSee [examples/camera-display](examples/camera-display) for a minimal working example that captures video from a camera and displays it in a window.\n\n## Telemetry \u0026 Observability\n\nStreamLib has built-in OpenTelemetry observability. All runtimes send structured logs and traces to the broker, which stores them in SQLite and optionally forwards to any OTLP-compatible backend.\n\n```bash\n# Query logs from the CLI\nstreamlib telemetry logs --since 1h\nstreamlib telemetry spans --service streamlib-runtime\n\n# Connect to Grafana, Jaeger, Datadog, or any OTLP backend\nSTREAMLIB_OTLP_ENDPOINT=http://localhost:4317 ./.streamlib/bin/streamlib-broker\n\n# Backfill historical data to your dashboard\nstreamlib telemetry export --endpoint http://localhost:4317 --since 7d\n```\n\nSee [docs/telemetry.md](docs/telemetry.md) for setup details, environment variables, and direct SQL access.\n\n## Documentation\n\n- [Architecture Overview](docs/) - How StreamLib works\n- [Telemetry Guide](docs/telemetry.md) - Observability setup and usage\n- [API Documentation](https://docs.rs/streamlib) - Rust API reference\n- [Examples](examples/) - Working example applications\n\n## Examples\n\n| Example | Description |\n|---------|-------------|\n| [camera-display](examples/camera-display) | Camera capture and display |\n| [microphone-reverb-speaker](examples/microphone-reverb-speaker) | Audio processing with CLAP plugins |\n| [camera-audio-recorder](examples/camera-audio-recorder) | Record camera + audio to MP4 |\n| [webrtc-cloudflare-stream](examples/webrtc-cloudflare-stream) | WebRTC streaming to Cloudflare |\n| [whep-player](examples/whep-player) | WHEP (WebRTC egress) player |\n\nRun an example:\n```bash\ncargo run -p camera-display\n```\n\n## License \u0026 Business Model\n\nStreamLib uses an **open-core model** inspired by game engines like Unity and Unreal.\n\n### The Simple Version\n\n| What you want to do | Cost |\n|---------------------|------|\n| Build Processors | **Free** |\n| Sell Processors | **Free** (you keep 100%) |\n| Keep source private | **Free** (no obligation to share) |\n| Run the Runtime in production | Commercial license required* |\n\n*Unless you fall under permitted uses (see below)\n\n### Build Anything, Own Everything\n\n**We don't own your Processors.** Just like Epic doesn't own games built with Unreal Engine, we don't own what you build with StreamLib.\n\n```mermaid\nflowchart TB\n    YOURS[\"\u003cb\u003eYour Processors\u003c/b\u003e\u003cbr/\u003eCustom • Community • Commercial\u003cbr/\u003e\u003ci\u003eYours 100% — sell, keep private, open source\u003c/i\u003e\"]\n    API[\"\u003cb\u003eProcessor API\u003c/b\u003e\u003cbr/\u003eReactiveProcessor • LinkInput/Output • VideoFrame • AudioFrame\"]\n    RUNTIME[\"\u003cb\u003eStreamLib Runtime\u003c/b\u003e\u003cbr/\u003eGraph Compiler • Scheduler • GPU Context\u003cbr/\u003e\u003ci\u003eBUSL-1.1 — Restricted uses require license\u003c/i\u003e\"]\n\n    YOURS --\u003e API --\u003e RUNTIME\n\n    style YOURS fill:#d4edda,stroke:#28a745\n    style RUNTIME fill:#fff3cd,stroke:#ffc107\n```\n\n### What You Can Do (No License Required)\n\n| Activity | Allowed? | Notes |\n|----------|:--------:|-------|\n| Build custom Processors | ✅ | For yourself, clients, or to sell |\n| Sell Processors commercially | ✅ | Keep 100% of revenue |\n| Keep Processor source private | ✅ | No obligation to open source |\n| Build Processors for clients | ✅ | Contractors/consultants welcome |\n| Personal/hobby projects | ✅ | No restrictions |\n| Educational/research use | ✅ | Universities, students, researchers |\n| Open source projects | ✅ | OSI-approved licenses |\n| Commercial apps (StreamLib as component) | ✅ | Video conferencing, security cameras, robotics, etc. |\n\n### What Requires a Commercial License (Restricted Uses)\n\n| Activity | License Required |\n|----------|:----------------:|\n| Selling/licensing the Runtime as a product | ✅ Commercial |\n| Offering the Runtime as a managed service or SaaS | ✅ Commercial |\n| White-labeling or rebranding the Runtime for resale | ✅ Commercial |\n| Creating a competing runtime derived from StreamLib | ✅ Commercial |\n| Embedding the Runtime and sublicensing it to end users | ✅ Commercial |\n\n**\"Runtime\"** = graph compiler, scheduler, processor execution, GPU context, link/port infrastructure.\n**Not the Runtime** = Processors you build using the Processor API.\n\n### Why This Model?\n\n**For the community:** We want a thriving ecosystem of Processors. Whether you're building an AI video analyzer, a custom encoder, or a specialized filter—build it, sell it, keep it private. Your choice.\n\n**For sustainability:** The runtime engine requires significant investment to build and maintain. Commercial licenses from companies building competing platforms fund continued development.\n\n**For trust:** On **January 1, 2029**, StreamLib automatically converts to [Apache License 2.0](LICENSES/Apache-2.0.txt). The code will be fully open source with no restrictions, guaranteed.\n\n### The Game Engine Analogy\n\n| Game Engine | StreamLib |\n|-------------|-----------|\n| Engine (Unity/Unreal) | Runtime Engine |\n| Games you build | Processors you build |\n| Asset Store | Processor marketplace (coming soon) |\n| You own your games | You own your Processors |\n| Engine is licensed | Runtime is BUSL-1.1 |\n\n### Commercial Licensing\n\nNeed a commercial license? Two options:\n\n**[Commercial License](docs/license/COMMERCIAL-LICENSING.md)** — For companies building streaming platforms or competing products.\n\n**[Partner License](docs/license/PARTNER-LICENSING.md)** — For consultants, agencies, and integrators. Includes co-marketing, roadmap input, and early access.\n\n**Contact:** fontanezj1@gmail.com\n\n### Full License\n\nStreamLib is licensed under the [Business Source License 1.1](LICENSE). See the LICENSE file for complete terms including the Additional Use Grant that explicitly permits Processor development.\n\n## Contributing\n\nContributions are welcome! By submitting a pull request, you agree to license your\ncontribution under the same BUSL-1.1 terms.\n\nSee [CLA.md](docs/license/CLA.md) for the Contributor License Agreement.\n\n## Project Structure\n\n```\nstreamlib/\n├── libs/\n│   ├── streamlib/           # Core library\n│   ├── streamlib-broker/    # Broker service (runtime coordination + telemetry collection)\n│   ├── streamlib-cli/       # CLI (streamlib command)\n│   ├── streamlib-runtime/   # Standalone runtime binary\n│   ├── streamlib-telemetry/ # OpenTelemetry observability (SQLite + OTLP)\n│   └── streamlib-macros/    # Procedural macros\n├── examples/                # Example applications\n└── docs/                    # Documentation\n```\n\n## Requirements\n\n- Rust 1.75+\n- macOS 13+ (for Apple framework features)\n- Metal-capable GPU (for video processing)\n\n## Development Setup\n\nStreamLib uses [direnv](https://direnv.net/) to manage environment variables for development.\n\n**1. Install direnv:**\n```bash\nbrew install direnv\n```\n\n**2. Add the hook to your shell** (add to `~/.zshrc` or `~/.bashrc`):\n```bash\neval \"$(direnv hook zsh)\"  # or bash\n```\n\n**3. Run the dev setup script:**\n```bash\n./scripts/dev-setup.sh\n```\n\n**4. Allow direnv to load the environment:**\n```bash\ndirenv allow\n```\n\nThis sets up:\n- StreamLib broker service (runs in background via launchd)\n- Development environment variables\n\nSee `.envrc.example` for the environment variables used.\n\n## Building\n\n```bash\n# Build the library\ncargo build -p streamlib\n\n# Run tests\ncargo test -p streamlib\n\n# Build all examples\ncargo build --workspace\n```\n\n## Status\n\nStreamLib is under active development. APIs may change between versions.\n\n## Contact\n\n- **Author:** Jonathan Fontanez\n- **Email:** fontanezj1@gmail.com\n- **Repository:** https://github.com/tato123/streamlib\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftatolab%2Fstreamlib","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftatolab%2Fstreamlib","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftatolab%2Fstreamlib/lists"}