From 43cbe66dccfb938ddb179981578f371c9b1a9e28 Mon Sep 17 00:00:00 2001 From: Ettore Di Giacinto Date: Sun, 12 Jan 2025 11:21:57 +0100 Subject: [PATCH] chore(model gallery): add LocalAI-functioncall-phi-4-v0.1 Signed-off-by: Ettore Di Giacinto --- gallery/index.yaml | 16 ++++++++++++++++ gallery/phi-4-chat-fcall.yaml | 27 +++++++++++++++++++++++++++ 2 files changed, 43 insertions(+) create mode 100644 gallery/phi-4-chat-fcall.yaml diff --git a/gallery/index.yaml b/gallery/index.yaml index 7d60167bca85..2b546c0b3b3c 100644 --- a/gallery/index.yaml +++ b/gallery/index.yaml @@ -23,6 +23,22 @@ - filename: phi-4-Q4_K_M.gguf uri: huggingface://bartowski/phi-4-GGUF/phi-4-Q4_K_M.gguf sha256: 009aba717c09d4a35890c7d35eb59d54e1dba884c7c526e7197d9c13ab5911d9 +- !!merge <<: *phi4 + url: "github:mudler/LocalAI/gallery/phi-4-fcall.yaml@master" + name: "LocalAI-functioncall-phi-4-v0.1" + icon: https://cdn-uploads.huggingface.co/production/uploads/647374aa7ff32a81ac6d35d4/Dzbdzn27KEc3K6zNNi070.png + description: | + A model tailored to be conversational and execute function calls with LocalAI. This model is based on phi-4. + urls: + - https://huggingface.co/mudler/LocalAI-functioncall-phi-4-v0.1 + - https://huggingface.co/mudler/LocalAI-functioncall-phi-4-v0.1-Q4_K_M-GGUF + overrides: + parameters: + model: localai-functioncall-phi-4-v0.1-q4_k_m.gguf + files: + - filename: localai-functioncall-phi-4-v0.1-q4_k_m.gguf + uri: huggingface://mudler/LocalAI-functioncall-phi-4-v0.1-Q4_K_M-GGUF/localai-functioncall-phi-4-v0.1-q4_k_m.gguf + sha256: 0ae4e5e4ba89c16c1e810285c5c8b84416fa67f8ed7c175aa0b6fc0a103017aa - &falcon3 name: "falcon3-1b-instruct" url: "github:mudler/LocalAI/gallery/falcon3.yaml@master" diff --git a/gallery/phi-4-chat-fcall.yaml b/gallery/phi-4-chat-fcall.yaml new file mode 100644 index 000000000000..a6fa261e1ce2 --- /dev/null +++ b/gallery/phi-4-chat-fcall.yaml @@ -0,0 +1,27 @@ +--- +name: "phi-4-chat" + +config_file: | + mmap: true + template: + chat_message: | + <|im_start|>{{ .RoleName }}<|im_sep|> + {{.Content}}<|im_end|> + chat: | + {{.Input}} + <|im_start|>assistant<|im_sep|> + completion: | + {{.Input}} + function: | + <|im_start|>system<|im_sep|> + You are an AI assistant that executes function calls, and these are the tools at your disposal: + {{range .Functions}} + {'type': 'function', 'function': {'name': '{{.Name}}', 'description': '{{.Description}}', 'parameters': {{toJson .Parameters}} }} + {{end}} + {{.Input}}<|im_end|> + context_size: 4096 + f16: true + stopwords: + - <|end|> + - <|endoftext|> + - <|im_end|>