Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/openai/lib/AbstractChatCompletionRunner.ts>AbstractChatCompletionRunner#off

Deno build of the official Typescript library for the OpenAI API.
Extremely Popular
Go to Latest
method AbstractChatCompletionRunner.prototype.off
import { AbstractChatCompletionRunner } from "https://deno.land/x/openai@v4.52.0/lib/AbstractChatCompletionRunner.ts";

Removes the specified listener from the listener array for the event. off() will remove, at most, one instance of a listener from the listener array. If any single listener has been added multiple times to the listener array for the specified event, then off() must be called multiple times to remove each instance.

Type Parameters

Event extends keyof Events

Parameters

event: Event
listener: ListenerForEvent<Events, Event>

Returns

this

this ChatCompletionStream, so that calls can be chained