Module language_models

Source
Expand description

Language model abstractions for FerricLink Core

This module provides the core abstractions for language models, including base traits for LLMs and chat models.

Structs§

Generation
A generation result from a language model
GenerationConfig
Configuration for language model generation
LLMResult
A result containing multiple generations
MockChatModel
A simple mock chat model for testing
MockLLM
A simple mock LLM for testing

Traits§

BaseChatModel
Trait for language models that work with chat messages
BaseLLM
Trait for language models that generate text from text input
BaseLanguageModel
Base trait for all language models

Functions§

mock_chat_model
Helper function to create a mock chat model
mock_llm
Helper function to create a mock LLM