acon96/Home-Assistant-Requests
Viewer β’ Updated β’ 35.8k β’ 306 β’ 47
How to use premrajreddy/tinyllama-1.1b-home-llm with llama.cpp:
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf premrajreddy/tinyllama-1.1b-home-llm:F16 # Run inference directly in the terminal: llama cli -hf premrajreddy/tinyllama-1.1b-home-llm:F16
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf premrajreddy/tinyllama-1.1b-home-llm:F16 # Run inference directly in the terminal: llama cli -hf premrajreddy/tinyllama-1.1b-home-llm:F16
# 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 premrajreddy/tinyllama-1.1b-home-llm:F16 # Run inference directly in the terminal: ./llama-cli -hf premrajreddy/tinyllama-1.1b-home-llm:F16
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 premrajreddy/tinyllama-1.1b-home-llm:F16 # Run inference directly in the terminal: ./build/bin/llama-cli -hf premrajreddy/tinyllama-1.1b-home-llm:F16
docker model run hf.co/premrajreddy/tinyllama-1.1b-home-llm:F16
How to use premrajreddy/tinyllama-1.1b-home-llm with vLLM:
# Install vLLM from pip:
pip install vllm
# Start the vLLM server:
vllm serve "premrajreddy/tinyllama-1.1b-home-llm"
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:8000/v1/chat/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "premrajreddy/tinyllama-1.1b-home-llm",
"messages": [
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'docker model run hf.co/premrajreddy/tinyllama-1.1b-home-llm:F16
How to use premrajreddy/tinyllama-1.1b-home-llm with Ollama:
ollama run hf.co/premrajreddy/tinyllama-1.1b-home-llm:F16
How to use premrajreddy/tinyllama-1.1b-home-llm with Docker Model Runner:
docker model run hf.co/premrajreddy/tinyllama-1.1b-home-llm:F16
How to use premrajreddy/tinyllama-1.1b-home-llm with Lemonade:
# Download Lemonade from https://lemonade-server.ai/ lemonade pull premrajreddy/tinyllama-1.1b-home-llm:F16
lemonade run user.tinyllama-1.1b-home-llm-F16
lemonade list
This model is a fine-tuned version of TinyLlama/TinyLlama-1.1B-Chat-v1.0, trained with acon96/Home-Assistant-Requests.
It is designed to act as a voice-controlled smart home assistant that takes natural language instructions and outputs Home Assistant commands.
from transformers import AutoModelForCausalLM, AutoTokenizer
tokenizer = AutoTokenizer.from_pretrained("premrajreddy/tinyllama-1.1b-home-llm")
model = AutoModelForCausalLM.from_pretrained("premrajreddy/tinyllama-1.1b-home-llm")
query = "turn on the kitchen lights"
inputs = tokenizer(query, return_tensors="pt")
outputs = model.generate(**inputs, max_new_tokens=80)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
Base model
TinyLlama/TinyLlama-1.1B-Chat-v1.0