Large Language Model Functions  
 
Function Description
LlmAskModel Sends a prompt to the specified service provider and model.
LlmAttachThread Attaches the specified client handle to another thread.
LlmCancelRequest Cancels the current blocking request.
LlmClearHeaders Clears the custom HTTP request headers for the client session.
LlmClearHistory Clears the current conversation history for a client.
LlmConnect Establishes a connection using the specified provider, URL, model, API key, and options.
LlmConnectEx Establishes a connection using an existing session structure.
LlmConvertTimestamp Converts a message or response timestamp value into a SYSTEMTIME structure.
LlmCreateSession Creates a session object using the specified provider settings.
LlmCreateSessionEx Creates a session object with extended configuration such as prompt, token limit, and sampling settings.
LlmDeleteSession Deletes a session object and releases its resources.
LlmDisableTrace Disables logging of network function calls.
LlmDisconnect Disconnects from the provider and releases the session handle.
LlmEnableTrace Enables logging of network function calls to a file.
LlmEnumModels Enumerates the models available for the connected provider.
LlmEnumProviders Enumerates the supported LLM providers.
LlmEstimateTokenCount Estimates the number of tokens in a text string for a specific provider.
LlmExportHistory Exports the current conversation history to a JSON-formatted file.
LlmFindMessage Searches the conversation history for a message matching the specified text or flags.
LlmFormatTimestamp Formats a message timestamp as an ISO 8601 date and time string.
LlmGetCacheTime Returns the current model or metadata cache lifetime for a client.
LlmGetClientOptions Returns the current client option flags.
LlmGetClientProvider Returns the provider associated with a client, and optionally its base URL.
LlmGetDefaultModelFlags Returns the default capability flags for the specified model.
LlmGetDefaultModelName Returns the default model name for the specified provider.
LlmGetErrorString Returns a text description for the specified error code.
LlmGetFirstMessage Retrieves the first message in the conversation history.
LlmGetIdleTime Returns the current idle timeout period for a client session.
LlmGetHistorySize Returns the maximum number of messages which can be stored in the conversation history.
LlmGetLastError Returns the last error code set for the current thread.
LlmGetMemoryUsage Returns the amount of memory currently used by a client session.
LlmGetMessage Retrieves a specific message prompt and response using the history index.
LlmGetMessageById Retrieves a specific message prompt and response using a message ID.
LlmGetMessageCount Returns the current number of messages in the conversation history.
LlmGetModelContextSize Returns the context window size for the specified model.
LlmGetModelFlags Returns the current model behavior flags for a client.
LlmGetModelInfo Returns detailed information about a specific model.
LlmGetModelName Returns the name of the current model used with a client session.
LlmGetNextMessage Retrieves the next message in the conversation history.
LlmGetProviderFlags Returns the capability flags associated with a provider.
LlmGetProviderId Returns a provider ID based on a provider name, endpoint URL or model name.
LlmGetProviderInfo Retrieves detailed information about a provider.
LlmGetProviderName Returns the display name of a provider.
LlmGetProviderUrl Returns the base endpoint URL for the specified provider.
LlmGetResponseHeader Returns the value of an HTTP header from the server response.
LLmGetStatusCode Returns the most recent HTTP status code for a client request.
LlmGetSystemPrompt Returns the current system prompt for a client session.
LlmGetTimeout Returns the number of seconds until a request times out.
LlmGetTokenUsage Returns token usage statistics for the client session.
LlmGetUserAgent Returns the current user-agent string used by the client.
LlmImportHistory Imports a conversation history from the specified JSON-formatted file.
LlmInitialize Initializes the library and validates the specified license key at runtime.
LlmIsBlocking Returns whether the client is currently processing a blocking operation.
LlmIsConnected Returns whether the client session is valid and connected to a server.
LlmNormalizeText Normalizes message text into a consistent format.
LlmResetSession Resets the current client session to its initial state.
LlmSendMessage Sends a prompt to the model and returns the response as a string.
LlmSendMessageEx Sends a structured message to the model and returns a structured response.
LlmSetCacheTime Sets the cache lifetime used by the client for model or provider data.
LlmSetClientOptions Sets the current client option flags.
LlmSetHistorySize Sets the maximum number of messages retained in the conversation history.
LlmSetIdleTime Sets the idle timeout period for a client session.
LlmSetLastError Sets the last error code for the current thread.
LlmSetModelFlags Sets model behavior flags for a client session.
LlmSetModelName Changes the current model for a client session.
LlmSetRequestHeader Sets the value of a custom HTTP header issued with subsequent requests.
LlmSetSystemPrompt Sets the system prompt for a client session.
LlmSetTimeout Sets the number of seconds until a blocking operation times out.
LlmSetUserAgent Sets the user-agent string used by the client.
LlmTrimHistory Removes messages from the conversation history, optionally constrained by token usage.
LlmUninitialize Terminates use of the library by the calling process.
LlmValidateModel Validates that a model name is recognized or supported by the current provider.
LlmValidateText Performs basic validation on message text before it is submitted to a model.