mt_llmkit library
Classes
- AIChatProvider
- Abstract interface for AI chat providers.
- AIChatProviderFactory
- Factory for creating AIChatProvider instances.
- BaseAIChatProvider
- Abstract base class that provides shared state management and utilities for all AIChatProvider implementations.
- ChatMessage
- A single message in a chat conversation.
- ChatRequest
- Request payload for a chat completion call.
- ChatResponse
- Response from a chat completion call.
- ClaudeChatProvider
- AIChatProvider implementation for the Anthropic Claude Messages API.
- Document
- Represents an indexed document in the RAG knowledge base.
- DocumentChunk
- A document fragment (chunk) with an optional embedding vector.
- EmbeddingProvider
- Abstract interface for text embedding providers.
- GeminiChatProvider
- AIChatProvider implementation for the Google Gemini API.
- GenerationGrammarTrigger
- Parameters controlling the token sampling and generation process.
- InMemoryVectorStore
- Implementation of VectorStore that stores chunks in RAM with automatic persistence to a JSON file.
- LlamaContentPart
- Base class for all content types in a message.
- LlamaImageContent
- A part of a message containing image data for vision models.
- LlamaTextContent
- A part of a message containing plain text.
- LlmConfig
- LlmInterface
- LocalModel
- Plugin for running local GGUF models.
- LoraAdapterConfig
- Configuration for a LoRA (Low-Rank Adaptation) adapter.
- MistralChatProvider
- AIChatProvider implementation for the Mistral AI API.
- OpenAIChatProvider
- AIChatProvider implementation for the OpenAI Chat Completions API.
- PerformanceMetrics
- Performance metrics for LLM text generation
- RagEngine
-
Facade over
LlamaRagCoordinator+ InMemoryVectorStore + RagPipeline. - RagIngestionProgress
- Progress of document ingestion (chunking + embedding).
- RagPipeline
- Orchestrator for the RAG (Retrieval-Augmented Generation) pipeline.
- StreamingChunk
- Streaming chunk with optional performance metrics
- TextChunker
- Splits document text into overlapping fragments (chunks).
- VectorSearchResult
- Vector search result — a chunk with a similarity score.
- VectorSimilarity
- Utility: vector similarity computations.
- VectorStore
- Abstract interface for a vector store.
Enums
- AIChatProviderType
- Supported AI chat provider backends.
- ChatRole
- Role of a participant in a chat conversation.
- GpuBackend
- GPU backend selection for runtime device preference.
- ModelBackend
- Backend used by LocalModel.
Exceptions / Errors
- AIChatException
- Base exception for all AI chat provider errors.
- APIKeyException
- Thrown when the API key is missing, invalid, or unauthorised.
- NetworkException
- Thrown for transport-level failures such as timeouts, DNS errors, or connection resets.
- RateLimitException
- Thrown when the provider rate-limit is exceeded (HTTP 429).