Skip to main content

resolve_effective_strategy

Function resolve_effective_strategy 

Source
pub fn resolve_effective_strategy(
    strategy: &ContextStrategy,
    effective_context_tokens: Option<u32>,
) -> ContextStrategy
Expand description

Resolve ContextStrategy::Auto into a concrete strategy using the caller’s model-specific effective context window (CH-05). Any other strategy passes through unchanged — this is the seam a caller with real model information (e.g. RunManager) should use before reaching trim_count/apply_strategy/trim_with_summarization, which only see DEFAULT_AUTO_CONTEXT_TOKENS if Auto reaches them unresolved.