diff --git a/Libraries/LLM/Models.swift b/Libraries/LLM/Models.swift index db44a91..4ec9354 100644 --- a/Libraries/LLM/Models.swift +++ b/Libraries/LLM/Models.swift @@ -229,6 +229,22 @@ extension ModelConfiguration { "<|begin_of_text|><|start_header_id|>system<|end_header_id|>\nYou are a helpful assistant<|eot_id|>\n<|start_header_id|>user<|end_header_id|>\n\(prompt)<|eot_id|>\n<|start_header_id|>assistant<|end_header_id|>" } + public static let llama3_2_1B_4bit = ModelConfiguration( + id: "mlx-community/Llama-3.2-1B-Instruct-4bit", + defaultPrompt: "What is the difference between a fruit and a vegetable?" + ) { + prompt in + "<|begin_of_text|><|start_header_id|>system<|end_header_id|>\nYou are a helpful assistant<|eot_id|>\n<|start_header_id|>user<|end_header_id|>\n\(prompt)<|eot_id|>\n<|start_header_id|>assistant<|end_header_id|>" + } + + public static let llama3_2_3B_4bit = ModelConfiguration( + id: "mlx-community/Llama-3.2-3B-Instruct-4bit", + defaultPrompt: "What is the difference between a fruit and a vegetable?" + ) { + prompt in + "<|begin_of_text|><|start_header_id|>system<|end_header_id|>\nYou are a helpful assistant<|eot_id|>\n<|start_header_id|>user<|end_header_id|>\n\(prompt)<|eot_id|>\n<|start_header_id|>assistant<|end_header_id|>" + } + private enum BootstrapState: Sendable { case idle case bootstrapping @@ -245,6 +261,8 @@ extension ModelConfiguration { bootstrapState = .bootstrapping register(configurations: [ llama3_1_8B_4bit, + llama3_2_1B_4bit, + llama3_2_3B_4bit, mistralNeMo4bit, smolLM_135M_4bit, mistral7B4bit, diff --git a/mlx-swift-examples.xcodeproj/project.pbxproj b/mlx-swift-examples.xcodeproj/project.pbxproj index 52c03ba..9546d99 100644 --- a/mlx-swift-examples.xcodeproj/project.pbxproj +++ b/mlx-swift-examples.xcodeproj/project.pbxproj @@ -3543,7 +3543,7 @@ repositoryURL = "https://github.com/huggingface/swift-transformers"; requirement = { kind = upToNextMajorVersion; - minimumVersion = 0.1.9; + minimumVersion = 0.1.12; }; }; C392736E2B60699100368D5D /* XCRemoteSwiftPackageReference "swift-argument-parser" */ = {