FuseChat: Knowledge Fusion of Chat Models
Paper • 2408.07990 • Published • 15
How to use bruhzair/prototype-0.4x125-Q6_K with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("text-generation", model="bruhzair/prototype-0.4x125-Q6_K")
messages = [
{"role": "user", "content": "Who are you?"},
]
pipe(messages) # Load model directly
from transformers import AutoTokenizer, AutoModelForCausalLM
tokenizer = AutoTokenizer.from_pretrained("bruhzair/prototype-0.4x125-Q6_K")
model = AutoModelForCausalLM.from_pretrained("bruhzair/prototype-0.4x125-Q6_K", device_map="auto")
messages = [
{"role": "user", "content": "Who are you?"},
]
inputs = tokenizer.apply_chat_template(
messages,
add_generation_prompt=True,
tokenize=True,
return_dict=True,
return_tensors="pt",
).to(model.device)
outputs = model.generate(**inputs, max_new_tokens=40)
print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:]))How to use bruhzair/prototype-0.4x125-Q6_K with llama.cpp:
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf bruhzair/prototype-0.4x125-Q6_K:Q6_K # Run inference directly in the terminal: llama cli -hf bruhzair/prototype-0.4x125-Q6_K:Q6_K
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf bruhzair/prototype-0.4x125-Q6_K:Q6_K # Run inference directly in the terminal: llama cli -hf bruhzair/prototype-0.4x125-Q6_K:Q6_K
# 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 bruhzair/prototype-0.4x125-Q6_K:Q6_K # Run inference directly in the terminal: ./llama-cli -hf bruhzair/prototype-0.4x125-Q6_K:Q6_K
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 bruhzair/prototype-0.4x125-Q6_K:Q6_K # Run inference directly in the terminal: ./build/bin/llama-cli -hf bruhzair/prototype-0.4x125-Q6_K:Q6_K
docker model run hf.co/bruhzair/prototype-0.4x125-Q6_K:Q6_K
How to use bruhzair/prototype-0.4x125-Q6_K with vLLM:
# Install vLLM from pip:
pip install vllm
# Start the vLLM server:
vllm serve "bruhzair/prototype-0.4x125-Q6_K"
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:8000/v1/chat/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "bruhzair/prototype-0.4x125-Q6_K",
"messages": [
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'docker model run hf.co/bruhzair/prototype-0.4x125-Q6_K:Q6_K
How to use bruhzair/prototype-0.4x125-Q6_K with SGLang:
# Install SGLang from pip:
pip install sglang
# Start the SGLang server:
python3 -m sglang.launch_server \
--model-path "bruhzair/prototype-0.4x125-Q6_K" \
--host 0.0.0.0 \
--port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/chat/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "bruhzair/prototype-0.4x125-Q6_K",
"messages": [
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'docker run --gpus all \
--shm-size 32g \
-p 30000:30000 \
-v ~/.cache/huggingface:/root/.cache/huggingface \
--env "HF_TOKEN=<secret>" \
--ipc=host \
lmsysorg/sglang:latest \
python3 -m sglang.launch_server \
--model-path "bruhzair/prototype-0.4x125-Q6_K" \
--host 0.0.0.0 \
--port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/chat/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "bruhzair/prototype-0.4x125-Q6_K",
"messages": [
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'How to use bruhzair/prototype-0.4x125-Q6_K with Ollama:
ollama run hf.co/bruhzair/prototype-0.4x125-Q6_K:Q6_K
How to use bruhzair/prototype-0.4x125-Q6_K with Unsloth Studio:
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 bruhzair/prototype-0.4x125-Q6_K to start chatting
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 bruhzair/prototype-0.4x125-Q6_K to start chatting
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for bruhzair/prototype-0.4x125-Q6_K to start chatting
How to use bruhzair/prototype-0.4x125-Q6_K with Docker Model Runner:
docker model run hf.co/bruhzair/prototype-0.4x125-Q6_K:Q6_K
How to use bruhzair/prototype-0.4x125-Q6_K with Lemonade:
# Download Lemonade from https://lemonade-server.ai/ lemonade pull bruhzair/prototype-0.4x125-Q6_K:Q6_K
lemonade run user.prototype-0.4x125-Q6_K-Q6_K
lemonade list
This is a merge of pre-trained language models created using mergekit.
This model was merged using the SCE merge method using /workspace/prototype-0.4x122 as a base.
The following models were included in the merge:
The following YAML configuration was used to produce this model:
models:
- model: /workspace/cache/models--Envoid--Llama-3-TenyxChat-DaybreakStorywriter-70B/snapshots/2416e680265cfe7818defa218fb8e9fdac04a8c1
parameters:
select_topk: 0.1
- model: /workspace/cache/models--Sao10K--L3.1-70B-Hanami-x1/snapshots/f054d970fe9119d0237ce97029e6f5b9fce630eb
parameters:
select_topk: 0.3
- model: /workspace/cache/models--tdrussell--Llama-3-70B-Instruct-Storywriter/snapshots/19be2a7c6382a9150e126cf144e2b2964e700d3c
parameters:
select_topk: 0.2
- model: /workspace/cache/models--EVA-UNIT-01--EVA-LLaMA-3.33-70B-v0.1/snapshots/7cd63fd3a5519383bfa57bf1f9f2cb008f366f90
parameters:
select_topk: 0.4
- model: /workspace/prototype-0.4x122
parameters:
select_topk: 0.65
base_model: /workspace/prototype-0.4x122
merge_method: sce
tokenizer:
source: base
chat_template: llama3
int8_mask: true
dtype: bfloat16