UNPKG

@unified-llm/core

Version:

Unified LLM interface (in-memory).

13 lines 611 B
import type { Logger } from "../types/index.js"; import type { Clock } from "./timing.js"; export declare function toModelSafeError(err: unknown): { name: string; message: string; }; export declare const NOOP_LOGGER: Logger; /** * Runs an async task while measuring duration and logging success or failure. * Logs include duration_ms and, on failure, a normalized error object. */ export declare function logTimed<T>(logger: Logger, clock: Clock, event: string, meta: Record<string, unknown>, fn: () => Promise<T>, level?: "debug" | "info" | "warn"): Promise<T>; //# sourceMappingURL=logging.d.ts.map