Instructions to use RichardErkhov/meetkai_-_functionary-small-v2.5-gguf with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use RichardErkhov/meetkai_-_functionary-small-v2.5-gguf with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf RichardErkhov/meetkai_-_functionary-small-v2.5-gguf:Q4_K_M # Run inference directly in the terminal: llama cli -hf RichardErkhov/meetkai_-_functionary-small-v2.5-gguf:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf RichardErkhov/meetkai_-_functionary-small-v2.5-gguf:Q4_K_M # Run inference directly in the terminal: llama cli -hf RichardErkhov/meetkai_-_functionary-small-v2.5-gguf:Q4_K_M
Build from source code
git clone https://github.com/ggml-org/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-app # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama serve -hf RichardErkhov/meetkai_-_functionary-small-v2.5-gguf:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama cli -hf RichardErkhov/meetkai_-_functionary-small-v2.5-gguf:Q4_K_M
Use Docker
docker model run hf.co/RichardErkhov/meetkai_-_functionary-small-v2.5-gguf:Q4_K_M
- Llama new
- LM Studio
- Jan
- Ollama
How to use RichardErkhov/meetkai_-_functionary-small-v2.5-gguf with Ollama:
ollama run hf.co/RichardErkhov/meetkai_-_functionary-small-v2.5-gguf:Q4_K_M
- Unsloth Desktop
- Pi
How to use RichardErkhov/meetkai_-_functionary-small-v2.5-gguf with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf RichardErkhov/meetkai_-_functionary-small-v2.5-gguf:Q4_K_M
Configure the model in Pi
# Install Pi: npm install -g @earendil-works/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "RichardErkhov/meetkai_-_functionary-small-v2.5-gguf:Q4_K_M" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Docker Model Runner
How to use RichardErkhov/meetkai_-_functionary-small-v2.5-gguf with Docker Model Runner:
docker model run hf.co/RichardErkhov/meetkai_-_functionary-small-v2.5-gguf:Q4_K_M
- Lemonade
How to use RichardErkhov/meetkai_-_functionary-small-v2.5-gguf with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull RichardErkhov/meetkai_-_functionary-small-v2.5-gguf:Q4_K_M
Run and chat with the model
lemonade run user.meetkai_-_functionary-small-v2.5-gguf-Q4_K_M
List all available models
lemonade list
- Hermes Agent
How to use RichardErkhov/meetkai_-_functionary-small-v2.5-gguf with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf RichardErkhov/meetkai_-_functionary-small-v2.5-gguf:Q4_K_M
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default RichardErkhov/meetkai_-_functionary-small-v2.5-gguf:Q4_K_M
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use RichardErkhov/meetkai_-_functionary-small-v2.5-gguf with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf RichardErkhov/meetkai_-_functionary-small-v2.5-gguf:Q4_K_M
Configure OpenClaw
# Install OpenClaw: npm install -g openclaw@latest # Register the local server and set it as the default model: openclaw onboard --non-interactive --mode local \ --auth-choice custom-api-key \ --custom-base-url http://127.0.0.1:8080/v1 \ --custom-model-id "RichardErkhov/meetkai_-_functionary-small-v2.5-gguf:Q4_K_M" \ --custom-provider-id llama-cpp \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
YAML Metadata Warning:empty or missing yaml metadata in repo card
Check out the documentation for more information.
Quantization made by Richard Erkhov.
functionary-small-v2.5 - GGUF
- Model creator: https://huggingface.co/meetkai/
- Original model: https://huggingface.co/meetkai/functionary-small-v2.5/
Original model description:
license: mit
Model Card for functionary-small-v2.5
https://github.com/MeetKai/functionary
Functionary is a language model that can interpret and execute functions/plugins.
The model determines when to execute functions, whether in parallel or serially, and can understand their outputs. It only triggers functions as needed. Function definitions are given as JSON Schema Objects, similar to OpenAI GPT function calls.
Key Features
- Intelligent parallel tool use
- Able to analyze functions/tools outputs and provide relevant responses grounded in the outputs
- Able to decide when to not use tools/call functions and provide normal chat response
- Truly one of the best open-source alternative to GPT-4
- Support code interpreter
How to Get Started
We provide custom code for parsing raw model responses into a JSON object containing role, content and tool_calls fields. This enables the users to read the function-calling output of the model easily.
from transformers import AutoModelForCausalLM, AutoTokenizer
tokenizer = AutoTokenizer.from_pretrained("meetkai/functionary-small-v2.5")
model = AutoModelForCausalLM.from_pretrained("meetkai/functionary-small-v2.5", device_map="auto", trust_remote_code=True)
tools = [
{
"type": "function",
"function": {
"name": "get_current_weather",
"description": "Get the current weather",
"parameters": {
"type": "object",
"properties": {
"location": {
"type": "string",
"description": "The city and state, e.g. San Francisco, CA"
}
},
"required": ["location"]
}
}
}
]
messages = [{"role": "user", "content": "What is the weather in Istanbul and Singapore respectively?"}]
final_prompt = tokenizer.apply_chat_template(messages, tools, add_generation_prompt=True, tokenize=False)
inputs = tokenizer(final_prompt, return_tensors="pt").to("cuda")
pred = model.generate_tool_use(**inputs, max_new_tokens=128, tokenizer=tokenizer)
print(tokenizer.decode(pred.cpu()[0]))
Prompt Template
We convert function definitions to a similar text to TypeScript definitions. Then we inject these definitions as system prompts. After that, we inject the default system prompt. Then we start the conversation messages.
This formatting is also available via our vLLM server which we process the functions into Typescript definitions encapsulated in a system message using a pre-defined Transformers Jinja chat template. This means that the lists of messages can be formatted for you with the apply_chat_template() method within our server:
from openai import OpenAI
client = OpenAI(base_url="http://localhost:8000/v1", api_key="functionary")
client.chat.completions.create(
model="path/to/functionary/model/",
messages=[{"role": "user",
"content": "What is the weather for Istanbul?"}
],
tools=[{
"type": "function",
"function": {
"name": "get_current_weather",
"description": "Get the current weather",
"parameters": {
"type": "object",
"properties": {
"location": {
"type": "string",
"description": "The city and state, e.g. San Francisco, CA"
}
},
"required": ["location"]
}
}
}],
tool_choice="auto"
)
will yield:
<|start_header_id|>system<|end_header_id|>
// Supported function definitions that should be called when necessary.
namespace functions {
// Get the current weather
type get_current_weather = (_: {
// The city and state, e.g. San Francisco, CA
location: string,
}) => any;
} // namespace functions<|eot_id|><|start_header_id|>user<|end_header_id|>
What is the weather for Istanbul?
A more detailed example is provided here.
Run the model
We encourage users to run our models using our OpenAI-compatible vLLM server here.
The MeetKai Team
- Downloads last month
- 81
2-bit
3-bit
4-bit
5-bit
6-bit
8-bit
