% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/llama.R
\name{llama_lora_apply}
\alias{llama_lora_apply}
\title{Apply a LoRA adapter to context}
\usage{
llama_lora_apply(ctx, lora, scale = 1)
}
\arguments{
\item{ctx}{Context handle returned by [llama_new_context]}

\item{lora}{LoRA adapter handle from [llama_lora_load]}

\item{scale}{Scaling factor for the adapter (1.0 = full effect, 0.5 = half effect)}
}
\value{
No return value, called for side effects. Activates the LoRA adapter
  for the given context.
}
\description{
Activates a loaded LoRA adapter for the given context.
Multiple LoRA adapters can be applied simultaneously.
}
\examples{
\dontrun{
model <- llama_load_model("base-model.gguf")
lora <- llama_lora_load(model, "adapter.gguf")
ctx <- llama_new_context(model)

# Apply with full strength
llama_lora_apply(ctx, lora, scale = 1.0)

# Or apply with reduced effect
llama_lora_apply(ctx, lora, scale = 0.5)
}
}
