Instructions to use your-model-man/qwen3.5-4b-home-assistant with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- llama-cpp-python
How to use your-model-man/qwen3.5-4b-home-assistant with llama-cpp-python:
# !pip install llama-cpp-python from llama_cpp import Llama llm = Llama.from_pretrained( repo_id="your-model-man/qwen3.5-4b-home-assistant", filename="Qwen3.5-4B.Q4_K_M.gguf", )
llm.create_chat_completion( messages = [ { "role": "user", "content": "What is the capital of France?" } ] ) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use your-model-man/qwen3.5-4b-home-assistant with llama.cpp:
Install from brew
brew install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf your-model-man/qwen3.5-4b-home-assistant:Q4_K_M # Run inference directly in the terminal: llama-cli -hf your-model-man/qwen3.5-4b-home-assistant:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf your-model-man/qwen3.5-4b-home-assistant:Q4_K_M # Run inference directly in the terminal: llama-cli -hf your-model-man/qwen3.5-4b-home-assistant:Q4_K_M
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf your-model-man/qwen3.5-4b-home-assistant:Q4_K_M # Run inference directly in the terminal: ./llama-cli -hf your-model-man/qwen3.5-4b-home-assistant:Q4_K_M
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf your-model-man/qwen3.5-4b-home-assistant:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama-cli -hf your-model-man/qwen3.5-4b-home-assistant:Q4_K_M
Use Docker
docker model run hf.co/your-model-man/qwen3.5-4b-home-assistant:Q4_K_M
- LM Studio
- Jan
- vLLM
How to use your-model-man/qwen3.5-4b-home-assistant with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "your-model-man/qwen3.5-4b-home-assistant" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "your-model-man/qwen3.5-4b-home-assistant", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/your-model-man/qwen3.5-4b-home-assistant:Q4_K_M
- Ollama
How to use your-model-man/qwen3.5-4b-home-assistant with Ollama:
ollama run hf.co/your-model-man/qwen3.5-4b-home-assistant:Q4_K_M
- Unsloth Studio
How to use your-model-man/qwen3.5-4b-home-assistant with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for your-model-man/qwen3.5-4b-home-assistant to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for your-model-man/qwen3.5-4b-home-assistant to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for your-model-man/qwen3.5-4b-home-assistant to start chatting
- Pi
How to use your-model-man/qwen3.5-4b-home-assistant with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama-server -hf your-model-man/qwen3.5-4b-home-assistant:Q4_K_M
Configure the model in Pi
# Install Pi: npm install -g @mariozechner/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "your-model-man/qwen3.5-4b-home-assistant:Q4_K_M" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Hermes Agent new
How to use your-model-man/qwen3.5-4b-home-assistant with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama-server -hf your-model-man/qwen3.5-4b-home-assistant: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 your-model-man/qwen3.5-4b-home-assistant:Q4_K_M
Run Hermes
hermes
- Atomic Chat new
- Docker Model Runner
How to use your-model-man/qwen3.5-4b-home-assistant with Docker Model Runner:
docker model run hf.co/your-model-man/qwen3.5-4b-home-assistant:Q4_K_M
- Lemonade
How to use your-model-man/qwen3.5-4b-home-assistant with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull your-model-man/qwen3.5-4b-home-assistant:Q4_K_M
Run and chat with the model
lemonade run user.qwen3.5-4b-home-assistant-Q4_K_M
List all available models
lemonade list
Qwen3.5-4B Home Assistant
A fine-tuned version of Qwen3.5-4B trained to control Home Assistant via natural language. Given a user command, the model outputs a structured JSON tool call that Home Assistant can execute directly through its OpenAI-compatible conversation API.
Fine-tuned using Unsloth for 2x faster training with LoRA adapters, then exported to GGUF Q4_K_M for efficient local inference.
Model Details
| Property | Value |
|---|---|
| Base model | Qwen3.5-4B |
| Fine-tuning method | LoRA (r=8, alpha=8) |
| Training framework | Unsloth |
| Training examples | 810 |
| Epochs | 3 |
| Final training loss | ~0.023 |
| Quantization | Q4_K_M GGUF |
| Context length | 1024 tokens |
Intended Use
Designed to be served locally via llama.cpp and connected to Home Assistant as a local conversation agent — no cloud, no API keys, full privacy.
Supported device domains:
- Lights (on/off, brightness, colour, colour temperature)
- Climate / thermostat (get/set temperature)
- Covers & blinds (open/close/position)
- Fans (on/off, speed)
- Locks (lock/unlock, state query)
- Media players (play/pause/next/previous/volume/mute)
- Vacuum cleaners (start/dock/clean area)
- Shopping & todo lists
- Scenes & scripts
- Timers
- Weather queries
- Date & time queries
Output Format
For device control commands the model outputs a JSON tool call:
{"tool": "HassTurnOn", "parameters": {"name": "kitchen light", "domain": "light"}}
{"tool": "HassLightSet", "parameters": {"area": "bedroom", "brightness": 50}}
{"tool": "HassClimateSetTemperature", "parameters": {"temperature": 72}}
For conversational messages it responds in plain text.
How to Use
With llama.cpp server
llama-server \
--model Qwen3.5-4B.Q4_K_M.gguf \
--port 8080 \
--host 0.0.0.0 \
--ctx-size 1024 \
--chat-template chatml
Connect to Home Assistant
- Go to Settings → Devices & Services → Add Integration → OpenAI Conversation
- Set Base URL to
http://your-local-ip:8080/v1 - Set API key to any value (e.g.
sk-local) - Assign it as your conversation or voice agent
In Python
from llama_cpp import Llama
llm = Llama.from_pretrained(
repo_id="luc-h/qwen3.5-4b-home-assistant",
filename="Qwen3.5-4B.Q4_K_M.gguf",
)
response = llm.create_chat_completion(messages=[
{"role": "system", "content": "You are a Home Assistant AI. Respond with JSON tool calls for device control."},
{"role": "user", "content": "turn off the kitchen lights"},
])
print(response["choices"][0]["message"]["content"])
# {"tool": "HassTurnOff", "parameters": {"area": "kitchen", "domain": "light"}}
Training Data
Generated from the official Home Assistant intents repository — the same sentence templates used by Home Assistant's built-in Assist voice assistant. Examples cover all major device domains with varied natural language phrasings, entity names, and area references.
Limitations
- Entity and area names in responses are placeholders — Home Assistant's conversation pipeline matches these to your actual devices
- Fine-tuned on English only
- Not designed for complex multi-step automations or scripting
Training Hardware
Trained on Google Colab free tier (NVIDIA T4, 15GB VRAM) in approximately 1 hour.
License
Apache 2.0 — same as the base Qwen3.5 model.
- Downloads last month
- 39
4-bit