Skip to main content

Parameters

ParameterTypeDefaultDescription
default_modelAnyRequiredDefault model to use when no specific model is requested
requested_modelOptional[str]NoneSpecific model requested for this execution

Functions

get_model

Get the currently selected model. Returns:
  • Any: The selected model instance

manage_llm

Asynchronous context manager for LLM selection and management. Returns:
  • AsyncContextManager: Context manager that handles LLM selection logic
Usage:
async with llm_manager.manage_llm() as manager:
    model = manager.get_model()
    # Use the selected model
I