ai-utils.js
Version:
Build AI applications, chatbots, and agents with JavaScript and TypeScript.
8 lines (7 loc) • 340 B
TypeScript
import { RetryFunction } from "./RetryFunction.js";
import { ThrottleFunction } from "./ThrottleFunction.js";
export declare const callWithRetryAndThrottle: <OUTPUT>({ retry, throttle, call, }: {
retry?: RetryFunction | undefined;
throttle?: ThrottleFunction | undefined;
call: () => PromiseLike<OUTPUT>;
}) => Promise<OUTPUT>;