effect-uai-mid-stream-abort

Official

Cancel an in-flight model turn safely.

Authorbetalyra
Version1.0.0
Installs0

System Documentation

What problem does it solve?

Use this Skill when you need to cancel an in-flight model turn cleanly — e.g. user clicks "stop", a new prompt arrives mid-generation, or a deadline elapses. The upstream HTTP connection drops via Effect's structured concurrency; partial deltas already emitted stay with the consumer.

Core Features & Use Cases

  • Mid-turn abort with Stream.interruptWhen and Deferred signaling to stop a running turn gracefully.
  • Safe teardown: finalizers run end-to-end, including aborting the underlying fetch.
  • Use cases include interactive chat interfaces, long-running generations, and deadline-driven prompts.

Quick Start

Integrate the mid-stream abort pattern in your turn processing to allow users to stop in-flight generations.

Dependency Matrix

Required Modules

None required

Components

Standard package

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: effect-uai-mid-stream-abort
Download link: https://github.com/betalyra/effect-uai/archive/main.zip#effect-uai-mid-stream-abort

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.