Skip to main content
The Deno 2 Release Candidate is here
Learn more
Module

x/openai/streaming.ts>Stream#toReadableStream

Deno build of the official Typescript library for the OpenAI API.
Extremely Popular
Latest
method Stream.prototype.toReadableStream
import { Stream } from "https://deno.land/x/openai@v4.64.0/streaming.ts";

Converts this stream to a newline-separated ReadableStream of JSON stringified values in the stream which can be turned back into a Stream with Stream.fromReadableStream().