import type { Logger, LoggerBindings } from "./logging.js"; export type { Logger, LoggerBindings } from "./logging.js"; /** * Log entry structure for in-memory storage and streaming */ export interface LogEntry { time: number; level?: number; msg: string; agentName?: string; agentId?: string; [key: string]: string | number | boolean | null | undefined; } /** * Log listener callback type for real-time log streaming */ export type LogListener = (entry: LogEntry) => void; /** * Add a listener for real-time log entries (used for WebSocket streaming) * @param listener - Callback function to receive log entries * @returns Function to remove the listener */ export declare function addLogListener(listener: LogListener): () => void; /** * Remove a log listener * @param listener - The listener to remove */ export declare function removeLogListener(listener: LogListener): void; /** Lets hot paths omit debug-only diagnostics under the resolved logger level. */ export declare const RUNTIME_DEBUG_LOG_ENABLED: boolean; export interface PromptLogMetadata { agentName?: string; agentId?: string; runId?: string; provider?: string; caller?: string; [key: string]: unknown; } export interface ResponseLogMetadata { agentName?: string; agentId?: string; runId?: string; provider?: string; duration?: number; promptSlug?: string; [key: string]: unknown; } /** * Log a prompt to prompts.log. Returns the slug callers can pass as * `metadata.promptSlug` when logging the matching response. */ export declare function logPrompt(modelType: string, prompt: string, metadata?: PromptLogMetadata): string; /** * Log a response to prompts.log. Returns the correlated prompt slug, or an * empty string when no prompt slug is available. */ export declare function logResponse(modelType: string, response: string, metadata?: ResponseLogMetadata): string; export interface ChatInLogParams { agentName: string; agentId: string; roomId: string; messageId: string; text: string; source?: string; } export interface ChatOutLogParams { agentName: string; agentId: string; roomId: string; action: string; text?: string; emoji?: string; providers?: string[]; reasoning?: string; actions?: string[]; } /** Log an incoming message to chat.log. */ export declare function logChatIn(params: ChatInLogParams): string; /** Log an outgoing response to chat.log. */ export declare function logChatOut(params: ChatOutLogParams): string; /** * Creates a logger instance using Adze * @param bindings - Logger configuration or boolean flag * @returns Logger instance with elizaOS API */ declare function createLogger(bindings?: LoggerBindings | boolean): Logger; declare const logger: Logger; export declare const elizaLogger: Logger; export declare const recentLogs: () => string; export { createLogger, logger }; export default logger;