effect-uai-modify-output-stream

Format a Stream<TurnEvent> for transport via SSE or JSONL.

30|4|Updated Apr 26, 2026
One-click install
npx skills add https://github.com/betalyra/effect-uai --skill effect-uai-modify-output-stream
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: effect-uai-modify-output-stream
Source: https://github.com/betalyra/effect-uai/tree/main/skills/effect-uai-modify-output-stream
Command: npx skills add https://github.com/betalyra/effect-uai --skill effect-uai-modify-output-stream

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Formats the loop output for transport over common wire formats (SSE for browsers and JSONL for CLI pipelines). It provides a lightweight surface to convert a Stream<TurnEvent> into a transport-ready form without altering the core loop.

Core Features & Use Cases

  • Seamless transport formatting: apply a single mapping to convert a Stream of TurnEvent into SSE or JSONL.
  • Lightweight integration: sits on top of the existing stream, requiring no runtime changes to the loop.
  • Use cases: ship real-time TurnEvent output to a web UI via SSE or pipe logs in JSONL for processing.

Quick Start

Map the agent's Stream<TurnEvent> to SSE or JSONL using Turn.toSSE or Turn.toJSONL for transport.

Frequently Asked Questions about effect-uai-modify-output-stream

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I format a TurnEvent stream for SSE transport?

To format a TurnEvent stream for SSE transport, map the existing Stream<TurnEvent> using the Turn.toSSE helper. This applies a lightweight mapping to make the stream transport-ready for web dashboards without altering the core loop.

What is the best way to pipe TurnEvent logs in JSONL?

The best way to pipe TurnEvent logs in JSONL is to map the stream using the Turn.toJSONL helper. This adapts the existing stream for CLI pipelines, allowing downstream processing tools to consume structured logs seamlessly.

Do I need to change my business logic to output server-sent events?

No, you do not need to change your business logic to output server-sent events. This approach sits on top of the existing stream, requiring no runtime changes to the loop while providing transport-ready wire formatting.

When do I need server-sent events versus JSONL for stream output?

You need server-sent events for shipping real-time output to a web UI, whereas JSONL is used when piping structured logs to CLI pipelines for processing. Both formats adapt the TurnEvent stream for their respective transport layers.

Can I use this wire format conversion for CLI pipelines?

Yes, you can use this wire format conversion for CLI pipelines by applying the Turn.toJSONL mapping. It seamlessly converts the Stream<TurnEvent> into structured JSONL output for command-line processing.

How does stream formatting for wire transport work?

Stream formatting for wire transport works by applying a single mapping function to convert a Stream<TurnEvent> into a transport-ready form. It uses small helpers to adapt the stream for SSE or JSONL without changing business logic.