Instructions to use Cabbache/Fredu-1.7B-Instruct 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 Cabbache/Fredu-1.7B-Instruct 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 Cabbache/Fredu-1.7B-Instruct:Q4_K_M # Run inference directly in the terminal: llama cli -hf Cabbache/Fredu-1.7B-Instruct:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf Cabbache/Fredu-1.7B-Instruct:Q4_K_M # Run inference directly in the terminal: llama cli -hf Cabbache/Fredu-1.7B-Instruct: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 Cabbache/Fredu-1.7B-Instruct:Q4_K_M # Run inference directly in the terminal: ./llama-cli -hf Cabbache/Fredu-1.7B-Instruct: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 Cabbache/Fredu-1.7B-Instruct:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama-cli -hf Cabbache/Fredu-1.7B-Instruct:Q4_K_M
Use Docker
docker model run hf.co/Cabbache/Fredu-1.7B-Instruct:Q4_K_M
- LM Studio
- Jan
- vLLM
How to use Cabbache/Fredu-1.7B-Instruct with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Cabbache/Fredu-1.7B-Instruct" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Cabbache/Fredu-1.7B-Instruct", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/Cabbache/Fredu-1.7B-Instruct:Q4_K_M
- Ollama
How to use Cabbache/Fredu-1.7B-Instruct with Ollama:
ollama run hf.co/Cabbache/Fredu-1.7B-Instruct:Q4_K_M
- Unsloth Studio
How to use Cabbache/Fredu-1.7B-Instruct with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
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 Cabbache/Fredu-1.7B-Instruct to start chatting
Install Unsloth Studio (Windows)
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 Cabbache/Fredu-1.7B-Instruct to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for Cabbache/Fredu-1.7B-Instruct to start chatting
- Docker Model Runner
How to use Cabbache/Fredu-1.7B-Instruct with Docker Model Runner:
docker model run hf.co/Cabbache/Fredu-1.7B-Instruct:Q4_K_M
- Lemonade
How to use Cabbache/Fredu-1.7B-Instruct with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull Cabbache/Fredu-1.7B-Instruct:Q4_K_M
Run and chat with the model
lemonade run user.Fredu-1.7B-Instruct-Q4_K_M
List all available models
lemonade list
- Atomic Chat
Fredu 1.7B Instruct
A Maltese-specialised model built from utter-project/EuroLLM-1.7B in two stages
on a single consumer GPU (RTX 5060 Ti, 16 GB).
It is fluent in Maltese but hallucinates and does not always reply with anything related to the prompt. It's able to translate english sentences into a related sentence in Maltese. It's quite bad at it but the Maltese translation is related somehow.
How to run
Ollama
ollama run hf.co/Cabbache/Fredu-1.7B-Instruct
The prompt template and sampling parameters are stored in the repo, so nothing else is needed. Pick a build with a tag:
| tag | size | notes |
|---|---|---|
(none) / :Q4_K_M |
1.0 GB | 4-bit, the default. |
:Q8_0 |
1.8 GB | 8-bit, close to full quality |
:F16 |
3.3 GB | no quantization |
transformers
from transformers import AutoModelForCausalLM, AutoTokenizer
tok = AutoTokenizer.from_pretrained("Cabbache/Fredu-1.7B-Instruct")
model = AutoModelForCausalLM.from_pretrained("Cabbache/Fredu-1.7B-Instruct",
dtype="bfloat16", device_map="auto")
q = "X'inhu l-Kunsill Lokali f'Malta?"
ids = tok(f"Mistoqsija: {q}\nTweġiba:", return_tensors="pt").to(model.device)
out = model.generate(**ids, max_new_tokens=200, temperature=0.3, do_sample=True)
print(tok.decode(out[0], skip_special_tokens=True))
There is no chat template. Use the Mistoqsija:/Tweġiba: framing above, which
is what the model was trained on. A low temperature helps: what factual
knowledge it has is held with very little margin and does not survive sampling
at 0.7.
What was done
| stage | data | result |
|---|---|---|
| Continued pretraining | 336M tokens, 125,900 documents from Korpus Malti | perplexity 8.29 → 5.98 |
| Supervised fine-tuning | 43,988 Maltese question/answer pairs | answer-loss 1.70 → 1.40 |
Both stages were full fine-tunes (all 1.657B parameters), bf16 weights and gradients with 8-bit AdamW and gradient checkpointing, ~14 GB VRAM.
Prompt format
The model was trained on this exact framing, with loss computed only on the answer:
Mistoqsija: {question}
Tweġiba: {answer}
It reads informal Maltese and replies in correct Maltese
35% of training questions had their diacritics stripped (ħ→h, ġ→g, ċ→c, ż→z,
so għ→gh) while every answer was left correct. Because loss lands only on the
answer, the model is shown informal spelling and never rewarded for producing it.
Q: X'inhu n-numru medju ta' sighat ta' rqad li persuna ghandha tiehu?
A: In-numru medju ta' sigħat ta' rqad li persuna għandha tieħu huwa madwar
7.5 sigħat kuljum.
Note sighat → sigħat, ghandha → għandha, tiehu → tieħu.
Evaluation
Perplexity on held-out documents, by register, against the untrained base:
| source | base | this model | change |
|---|---|---|---|
| government gazette | 7.84 | 2.97 | −62.1% |
| parliament | 6.89 | 3.19 | −53.6% |
| press | 7.72 | 6.01 | −22.1% |
| academic | 12.61 | 10.38 | −17.7% |
| blogs | 10.43 | 8.93 | −14.4% |
| wikipedia | 6.51 | 6.06 | −6.9% |
A 57-item Malta factual eval (greedy decoding, an upper bound on knowledge):
| this model | base | |
|---|---|---|
| overall | 27/57 | 22/57 |
| history | 12/13 | 8/13 |
| geography | 4/17 | 6/17 |
Licence
Do whatever you want with it
- Downloads last month
- -