How to use from
llama.cpp
Install from brew
brew install llama.cpp
# Start a local OpenAI-compatible server with a web UI:
llama-server -hf duyntnet/ALMA-13B-R-imatrix-GGUF:
# Run inference directly in the terminal:
llama-cli -hf duyntnet/ALMA-13B-R-imatrix-GGUF:
Install from WinGet (Windows)
winget install llama.cpp
# Start a local OpenAI-compatible server with a web UI:
llama-server -hf duyntnet/ALMA-13B-R-imatrix-GGUF:
# Run inference directly in the terminal:
llama-cli -hf duyntnet/ALMA-13B-R-imatrix-GGUF:
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 duyntnet/ALMA-13B-R-imatrix-GGUF:
# Run inference directly in the terminal:
./llama-cli -hf duyntnet/ALMA-13B-R-imatrix-GGUF:
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 duyntnet/ALMA-13B-R-imatrix-GGUF:
# Run inference directly in the terminal:
./build/bin/llama-cli -hf duyntnet/ALMA-13B-R-imatrix-GGUF:
Use Docker
docker model run hf.co/duyntnet/ALMA-13B-R-imatrix-GGUF:
Quick Links

Quantizations of https://huggingface.co/haoranxu/ALMA-13B-R

From original readme

A quick start to use our best system (ALMA-13B-R) for translation. An example of translating "我爱机器翻译。" into English:

import torch
from transformers import AutoModelForCausalLM
from transformers import AutoTokenizer

# Load base model and LoRA weights
model = AutoModelForCausalLM.from_pretrained("haoranxu/ALMA-13B-R", torch_dtype=torch.float16, device_map="auto")
tokenizer = AutoTokenizer.from_pretrained("haoranxu/ALMA-13B-R", padding_side='left')

# Add the source sentence into the prompt template
prompt="Translate this from Chinese to English:\nChinese: 我爱机器翻译。\nEnglish:"
input_ids = tokenizer(prompt, return_tensors="pt", padding=True, max_length=40, truncation=True).input_ids.cuda()

# Translation
with torch.no_grad():
    generated_ids = model.generate(input_ids=input_ids, num_beams=5, max_new_tokens=20, do_sample=True, temperature=0.6, top_p=0.9)
outputs = tokenizer.batch_decode(generated_ids, skip_special_tokens=True)
print(outputs)
Downloads last month
39
GGUF
Model size
13B params
Architecture
llama
Hardware compatibility
Log In to add your hardware

1-bit

2-bit

3-bit

4-bit

5-bit

6-bit

8-bit

Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support