klyn.genai.llm.inference.LocalLLMProvider.primePrefix
method
public primePrefix(request as LLMRequest, observer as LocalGenerationObserver) as Long
Description

Precomputes the initial system/schema frame without generating text. No user turn or tool action is executed or retained in the checkpoint. Its exact tokens must match subsequent requests to be reused. Observer progress counts actual processed tokens; partial state is never committed.

Throws
  • ValueException unless caching and an open tokenizer are available.
Example

provider.primePrefix(request,observer) before showing a login.