You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/ai-foundry/foundry-local/reference/reference-cli.md
+22-7Lines changed: 22 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -35,16 +35,28 @@ The CLI organizes commands into three main categories:
35
35
36
36
The following table summarizes the commands related to managing and running models:
37
37
38
+
> [!NOTE]
39
+
> You can specify the `model` argument by its **alias** or **model ID**. Using an alias will:
40
+
> - Select the *best model* for your available hardware. For example, if you have a Nvidia CUDA GPU available, Foundry Local selects the CUDA model. If you have a supported NPU available, Foundry Local selects the NPU model.
41
+
> - Allow you to use a shorter name without needing to remember the model ID.
42
+
>
43
+
> If you want to run a specific model, you can use the model ID. For example, to run the `qwen2.5-0.5b` on CPU - irrespective of your available hardware - use: `foundry model run qwen2.5-0.5b-instruct-generic-cpu`.
|`foundry model --help`| Displays all available model-related commands and their usage. |
41
-
|`foundry model run <aliasOrModelId>`| Runs a specified model, downloading it if not cached, and starts an interaction. |
49
+
|`foundry model run <model>`| Runs a specified model, downloading it if not cached, and starts an interaction. |
42
50
|`foundry model list`| Lists all available models for local use. |
43
-
|`foundry model info <aliasOrModelId>`| Displays detailed information about a specific model. |
44
-
|`foundry model info <aliasOrModelId> --license`| Displays the license information for a specific model. |
45
-
|`foundry model download <aliasOrModelId>`| Downloads a model to the local cache without running it. |
46
-
|`foundry model load <aliasOrModelId>`| Loads a model into the service. |
47
-
|`foundry model unload <aliasOrModelId>`| Unloads a model from the service. |
51
+
|`foundry model info <model>`| Displays detailed information about a specific model. |
52
+
|`foundry model info <model> --license`| Displays the license information for a specific model. |
53
+
|`foundry model download <model>`| Downloads a model to the local cache without running it. |
54
+
|`foundry model load <model>`| Loads a model into the service. |
55
+
|`foundry model unload <model>`| Unloads a model from the service. **You must provide a valid model ID (not an alias).**. |
56
+
57
+
> [!IMPORTANT]
58
+
> **For the `foundry model unload` command, you must provide a valid model ID (not an alias)** because you could have multiple models loaded with the same alias. For example, if you have `qwen2.5-0.5b-instruct-generic-cpu`*and*`qwen2.5-0.5b-instruct-cuda-gpu` loaded with both CPU and CUDA, you need to specify which one to unload.
59
+
48
60
49
61
## Service commands
50
62
@@ -70,5 +82,8 @@ The following table summarizes the commands related to managing the local cache
70
82
|`foundry cache --help`| Displays all available cache-related commands and their usage. |
71
83
|`foundry cache location`| Displays the current cache directory. |
72
84
|`foundry cache list`| Lists all models stored in the local cache. |
73
-
|`foundry cache remove <aliasOrModelId>`| Deletes a model from the local cache. |
74
85
|`foundry cache cd <path>`| Changes the cache directory. |
86
+
|`foundry cache remove <model>`| Deletes a model from the local cache. **You must provide a valid model ID (not an alias).**|
87
+
88
+
> [!IMPORTANT]
89
+
> **For the `foundry cache remove` command, you must provide a valid model ID (not an alias)** because you could have multiple models on disk with the same alias. For example, if you downloaded both `qwen2.5-0.5b-instruct-generic-cpu`*and*`qwen2.5-0.5b-instruct-cuda-gpu`, you need to specify which one to remove.
0 commit comments