Text Generation
Safetensors
GGUF
English
embeddings-are-overpriced
frozen-embedding
binary-codes
ternary
bitnet
gemma-3
small-language-model
cpu-inference
research
Instructions to use QLNI/embeddings-are-overpriced 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 QLNI/embeddings-are-overpriced 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 QLNI/embeddings-are-overpriced:Q4_K_M # Run inference directly in the terminal: llama cli -hf QLNI/embeddings-are-overpriced:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf QLNI/embeddings-are-overpriced:Q4_K_M # Run inference directly in the terminal: llama cli -hf QLNI/embeddings-are-overpriced: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 QLNI/embeddings-are-overpriced:Q4_K_M # Run inference directly in the terminal: ./llama-cli -hf QLNI/embeddings-are-overpriced: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 QLNI/embeddings-are-overpriced:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama-cli -hf QLNI/embeddings-are-overpriced:Q4_K_M
Use Docker
docker model run hf.co/QLNI/embeddings-are-overpriced:Q4_K_M
- LM Studio
- Jan
- vLLM
How to use QLNI/embeddings-are-overpriced with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "QLNI/embeddings-are-overpriced" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "QLNI/embeddings-are-overpriced", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/QLNI/embeddings-are-overpriced:Q4_K_M
- Ollama
How to use QLNI/embeddings-are-overpriced with Ollama:
ollama run hf.co/QLNI/embeddings-are-overpriced:Q4_K_M
- Unsloth Desktop
- Docker Model Runner
How to use QLNI/embeddings-are-overpriced with Docker Model Runner:
docker model run hf.co/QLNI/embeddings-are-overpriced:Q4_K_M
- Lemonade
How to use QLNI/embeddings-are-overpriced with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull QLNI/embeddings-are-overpriced:Q4_K_M
Run and chat with the model
lemonade run user.embeddings-are-overpriced-Q4_K_M
List all available models
lemonade list
- Atomic Chat
Download code/fastc.py from QLNI/embeddings-are-overpriced: direct link, hf CLI and curl.
- Browser
- Download file 1.46 kB
-
https://huggingface.co/QLNI/embeddings-are-overpriced/resolve/main/code/fastc.py
- Command line
-
hf download hf://QLNI/embeddings-are-overpriced/code/fastc.py
-
curl -L -o fastc.py https://huggingface.co/QLNI/embeddings-are-overpriced/resolve/main/code/fastc.py
1.46 kB
| """Load a paper checkpoint for evaluation; for arm C, round the ternary weights ONCE so inference runs at float speed. | |
| (train.TLinear re-rounds weights on every forward pass, which is right for training and 2x slower for evaluation.)""" | |
| import numpy as np, torch, torch.nn.functional as F | |
| import train | |
| class FrozenTernary(torch.nn.Module): | |
| def __init__(self, lin): | |
| super().__init__() | |
| w = lin.weight.detach() | |
| sw = 1.0 / w.abs().mean().clamp_min(1e-5) | |
| self.register_buffer("wq", ((w * sw).round().clamp(-1, 1) / sw)) | |
| self.bias = lin.bias | |
| def forward(self, x): | |
| xf = x.float() | |
| xn = xf * torch.rsqrt(xf.pow(2).mean(-1, keepdim=True) + 1e-6) | |
| sx = 127.0 / xn.abs().amax(-1, keepdim=True).clamp_min(1e-5) | |
| xq = (xn * sx).round().clamp(-128, 127) / sx | |
| return F.linear(xq.to(x.dtype), self.wq.to(x.dtype), self.bias) | |
| def load(arm, ckpt, counts, learned_bias=None): | |
| if learned_bias is None: | |
| learned_bias = arm == "C" | |
| m = train.Model(arm, counts, learned_bias=learned_bias).cuda().eval() | |
| st = torch.load(ckpt, map_location="cuda", weights_only=False) | |
| m.load_state_dict(st["model"]) | |
| if arm == "C": | |
| for mod in list(m.body.layers.modules()): | |
| for name, child in list(mod.named_children()): | |
| if isinstance(child, train.TLinear): | |
| setattr(mod, name, FrozenTernary(child)) | |
| return m, st.get("tag", arm) | |