diff --git a/docs/content/advanced/advanced-usage.md b/docs/content/advanced/advanced-usage.md index f7d9546cf040..10e3147200ce 100644 --- a/docs/content/advanced/advanced-usage.md +++ b/docs/content/advanced/advanced-usage.md @@ -93,6 +93,25 @@ curl --location 'http://localhost:8080/models/apply' \ ``` +### Reloading model configurations at runtime + +If you add or edit a model YAML file in the models directory while LocalAI is running, +the change is not picked up automatically. Ask LocalAI to re-read the models directory: + +```bash +curl -X POST http://localhost:8080/models/reload +# {"success":true,"message":"Model configurations reloaded successfully"} +``` + +Unlike `/models/apply` above, this does not download anything — it only re-reads +configuration that is already present on disk. + +{{% alert note %}} +Reloading is additive: it adds new configurations and replaces existing ones with the +same name, but it does **not** drop configurations whose file has been deleted. A model +whose YAML you removed stays listed in `/v1/models` until LocalAI is restarted. +{{% /alert %}} + ### Preloading models during startup In order to allow the API to start-up with all the needed model on the first-start, the model gallery files can be used during startup. diff --git a/docs/content/advanced/model-configuration.md b/docs/content/advanced/model-configuration.md index a162a6225319..0d0fa637ca67 100644 --- a/docs/content/advanced/model-configuration.md +++ b/docs/content/advanced/model-configuration.md @@ -70,6 +70,7 @@ When using `--models-config-file`, you can define multiple models as a list: | `backend` | string | Backend to use (e.g. `llama-cpp`, `vllm`, `diffusers`, `whisper`) | `llama-cpp` | | `description` | string | Human-readable description of the model | `A conversational AI model` | | `usage` | string | Usage instructions or notes | `Best for general conversation` | +| `alias` | string | Redirects this name to another model. See [Model Aliases]({{%relref "features/model-aliases" %}}). | `my-llama-3` | ### Model File and Downloads