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: skills/mlx-swift-lm/references/model-container.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,7 +2,7 @@
2
2
3
3
## Overview
4
4
5
-
`ModelContainer` is the thread-safe wrapper for language models, providing exclusive access to model resources during inference. `ModelConfiguration` describes model identity and settings. Factory classes handle model instantiation from HuggingFace or local directories.
5
+
`ModelContainer` is the thread-safe wrapper for language models, providing exclusive access to model resources during inference. `ModelConfiguration` describes model identity and settings. Factory classes handle model instantiation from Hugging Face or local directories.
6
6
7
7
## Quick Reference
8
8
@@ -124,7 +124,7 @@ for await event in stream {
124
124
### Creating Configurations
125
125
126
126
```swift
127
-
// From HuggingFace model ID
127
+
// From Hugging Face model ID
128
128
let config =ModelConfiguration(
129
129
id: "mlx-community/Llama-3.2-3B-Instruct-4bit",
130
130
defaultPrompt: "Hello",
@@ -227,7 +227,7 @@ Map `model_type` from config.json to model initializers:
227
227
228
228
## Loading Flow
229
229
230
-
1.**Download**: Model weights fetched from HuggingFace (cached locally)
230
+
1.**Download**: Model weights fetched from Hugging Face (cached locally)
231
231
2.**Parse config.json**: Determine `model_type` and configuration
232
232
3.**Create model**: TypeRegistry maps type to initializer
233
233
4.**Load weights**: `.safetensors` files loaded into model
0 commit comments