LLM • TypeScript AI Agent SDK
* LLM – Configuration surface and an OpenAI-compatible base client.
llm
TypeScript AI Agent
- LLM – Configuration surface and an OpenAI-compatible base client.
- Python parity with praisonaiagents/llm/llm.py
LLM.__init__. Every
constructor parameter of the Python class is accepted here and honoured:
- – Request-shaped options reach the Chat Completions body built by
{
- Transport-shaped options reach the client built by
{
maxIterbounds the tool-calling loop in {eventsare listeners invoked on request start/end, tool calls, errors
and retries (Python: litellm callbacks + display callbacks).
failoverManagerrotates credentials on retryable failures.promptCaching,webFetchandclaudeMemoryemit the Anthropic-specific
request shapes Python emits, and are rejected on models that cannot carry them rather than silently ignored.
authresolves credentials from an object, a function or a registered
named provider.
Import
import { llm } from 'praisonai';Classes
TypeScript LLMEvent class
LLMEventHooksTypeScript LLMEventHooks class
LLMFailoverProfileTypeScript LLMFailoverProfile class
LLMFailoverManagerTypeScript LLMFailoverManager class
LLMFailoverDecisionTypeScript LLMFailoverDecision class
ClaudeMemoryBackendTypeScript ClaudeMemoryBackend class
LLMConfigTypeScript LLMConfig class
LLMResponseTypeScript LLMResponse class
LLMTypeScript LLM class
LLMGenerateOptionsTypeScript LLMGenerateOptions class
LLMToolLoopOptionsTypeScript LLMToolLoopOptions class
LLMToolCallRecordTypeScript LLMToolCallRecord class
LLMToolLoopResultTypeScript LLMToolLoopResult class
LLMRequestOptionsTypeScript LLMRequestOptions class
BaseLLMTypeScript BaseLLM class