UNPKG

llmforge

Version:

One API, every AI model, instant switching. Change from GPT-4 to Gemini to local models with a single config update. LLMForge is the lightweight, TypeScript-first solution for multi-provider AI applications with zero vendor lock-in.

17 lines (16 loc) 661 B
import { Config } from '../types'; import { RetryHandler } from '../strategies/retry/expo'; import { Readable } from 'stream'; export declare class HttpClient { private config; private retryHandler; constructor(config: Config, baseUrl: string, retryHandler?: RetryHandler); request<T>(endpoint: string, options?: RequestInit, isStream?: boolean): Promise<T>; streamRequest(endpoint: string, options?: RequestInit): Promise<Readable>; private handleErrorResponse; private isRetryableStatusCode; private getStatusText; private createTimeoutSignal; updateConfig(newConfig: Partial<Config>): void; getConfig(): Config; }