Instructions to use QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF 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 QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF 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 QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF:Q4_K_M # Run inference directly in the terminal: llama cli -hf QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF:Q4_K_M # Run inference directly in the terminal: llama cli -hf QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF: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 QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF:Q4_K_M # Run inference directly in the terminal: ./llama-cli -hf QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF: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 QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama-cli -hf QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF:Q4_K_M
Use Docker
docker model run hf.co/QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF:Q4_K_M
- LM Studio
- Jan
- vLLM
How to use QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF:Q4_K_M
- Ollama
How to use QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF with Ollama:
ollama run hf.co/QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF:Q4_K_M
- Unsloth Desktop
- Docker Model Runner
How to use QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF with Docker Model Runner:
docker model run hf.co/QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF:Q4_K_M
- Lemonade
How to use QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF:Q4_K_M
Run and chat with the model
lemonade run user.AI-Sweden-Llama-3-8B-Instruct-GGUF-Q4_K_M
List all available models
lemonade list
- Atomic Chat
|
Download README.md from QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF: direct link, hf CLI and curl.
- Browser
- Download file 2.49 kB
-
https://huggingface.co/QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF/resolve/main/README.md
- Command line
-
hf download hf://QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF/README.md
-
curl -L -o README.md https://huggingface.co/QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF/resolve/main/README.md
2.49 kB
metadata
license: apache-2.0
datasets: teknium/OpenHermes-2.5
base_model: AI-Sweden-Models/Llama-3-8B-instruct
pipeline_tag: text-generation
QuantFactory/AI-Sweden-Llama-3-8B-Instruct-GGUF
This is quantized version of AI-Sweden-Models/Llama-3-8B-instruct created suing llama.cpp
Model Description
Checkpoint 1
Training setup
The training was perfomed on the LUMI supercomputer within the DeployAI EU project. Based of the base model AI-Sweden-Models/Llama-3-8B.
Dataset
A data recipe by: 42 Labs

How to use
import transformers
import torch
model_id = "AI-Sweden-Models/Llama-3-8B-instruct"
pipeline = transformers.pipeline(
"text-generation",
model=model_id,
model_kwargs={"torch_dtype": torch.bfloat16},
device_map="auto",
)
messages = [
{"role": "system", "content": "Du är en hjälpsam assistant som svarar klokt och vänligt."},
{"role": "user", "content": "Hur gör man pannkakor? Och vad behöver man handla? Undrar också vad 5+6 är.."},
]
terminators = [
pipeline.tokenizer.eos_token_id,
pipeline.tokenizer.convert_tokens_to_ids("<|eot_id|>")
]
outputs = pipeline(
messages,
max_new_tokens=256,
eos_token_id=terminators,
do_sample=True,
temperature=0.6,
top_p=0.9,
)
print(outputs[0]["generated_text"][-1])
>>> "För att göra pannkakor behöver du följande ingredienser:
- 1 kopp vetemjöl
- 1 tesked bakpulver
- 1/4 tesked salt
- 1 kopp mjölk
- 1 stort ägg
- 2 matskedar smält smör eller olja
För att börja, blanda vetemjölet, bakpulvret och saltet i en bunke. I en annan skål, vispa ihop mjölken, ägget och smöret eller oljan.
Tillsätt de våta ingredienserna till de torra ingredienserna och blanda tills det är väl blandat.
Låt smeten vila i cirka 10 minuter.
För att göra pannkakorna, värm en non-stick-panna eller stekpanna över medelvärme.
När den är varm, häll smeten på pannan och grädda tills kanterna börjar torka ut och toppen är fast.
Vänd pannkakan med en stekspade och grädda den andra sidan tills den är gyllenbrun.
Upprepa med resten av smeten.
När det gäller 5+6 är svaret 11."