Instructions to use burkimbia/tengsoaba-1.7b with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use burkimbia/tengsoaba-1.7b with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="burkimbia/tengsoaba-1.7b") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("burkimbia/tengsoaba-1.7b") model = AutoModelForCausalLM.from_pretrained("burkimbia/tengsoaba-1.7b", 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]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use burkimbia/tengsoaba-1.7b with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "burkimbia/tengsoaba-1.7b" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "burkimbia/tengsoaba-1.7b", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/burkimbia/tengsoaba-1.7b
- SGLang
How to use burkimbia/tengsoaba-1.7b with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "burkimbia/tengsoaba-1.7b" \ --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": "burkimbia/tengsoaba-1.7b", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
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 "burkimbia/tengsoaba-1.7b" \ --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": "burkimbia/tengsoaba-1.7b", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use burkimbia/tengsoaba-1.7b with Docker Model Runner:
docker model run hf.co/burkimbia/tengsoaba-1.7b
Tengsoaba 1.7B
tengsoaba-1.7b is a compact instruction-tuned model for French ↔ Mooré
(mos), built by BurkimbIA. It is trained to
follow a small set of structured tasks on Mooré, a low-resource language of
Burkina Faso.
A 4B version of the same model, same seven tasks, is published at
burkimbia/tengsoaba-4b. It scores
+13.9 chrF on French → Mooré and is the better choice when the target is Mooré.
The name refers to the tẽng-soaba, the master of the land: the custodian of the earth among the Nyonyonsé, the autochthonous people of the region who kept ritual authority over the land.
Tasks
The model is multi-task. Each request uses a structured prompt with a <task>
tag, an <instruction>, and a typed <input>.
| Task | Input → Output |
|---|---|
translate_fr_to_moore |
French → Mooré translation |
translate_moore_to_fr |
Mooré → French translation |
correct_moore |
Noisy Mooré → corrected Mooré (spelling / OCR / ASR errors) |
quality_judgment |
A FR-Mooré pair → correct / incorrect / a verifier + short reason |
terminology |
French term → Mooré term (domain-adapted) |
standardize_moore |
Mooré → standard orthography |
Prompt format
The model expects the same structured prompts it was trained on. Example for French → Mooré:
<task>translate_fr_to_moore</task>
<instruction>Traduis le contenu en moore naturel et correct. Produis uniquement la traduction.</instruction>
<alphabet lang="mos">a, ã, b, d, e, ẽ, ɛ, f, g, h, i, ĩ, ɩ, k, l, m, n, o, õ, p, r, s, t, u, ũ, ʋ, v, w, y, z</alphabet>
<input lang="fr">Bonjour, comment allez-vous ?</input>
Usage
import torch
from transformers import AutoModelForCausalLM, AutoTokenizer
repo = "burkimbia/tengsoaba-1.7b"
tok = AutoTokenizer.from_pretrained(repo)
model = AutoModelForCausalLM.from_pretrained(repo, dtype=torch.float16, device_map="cuda")
prompt = (
"<task>translate_fr_to_moore</task>\n"
"<instruction>Traduis le contenu en moore naturel et correct. "
"Produis uniquement la traduction.</instruction>\n"
"<alphabet lang=\"mos\">a, ã, b, d, e, ẽ, ɛ, f, g, h, i, ĩ, ɩ, k, l, m, n, o, õ, "
"p, r, s, t, u, ũ, ʋ, v, w, y, z</alphabet>\n"
"<input lang=\"fr\">Bonjour, comment allez-vous ?</input>"
)
# apply_chat_template returns a dict on transformers >= 5, so tokenize separately.
text = tok.apply_chat_template(
[{"role": "user", "content": prompt}],
tokenize=False, add_generation_prompt=True, enable_thinking=False,
)
ids = tok(text, return_tensors="pt").to(model.device)
out = model.generate(**ids, max_new_tokens=192, num_beams=2, do_sample=False)
print(tok.decode(out[0][ids["input_ids"].shape[1]:], skip_special_tokens=True).strip())
Recommended decoding: num_beams=2, no repetition penalty.
Measured 2026-08-24 on 30 held-out pairs from the test split of
burkimbia/fr_mos_annotated_split_v2, chrF:
| Decoding | fr→mos | mos→fr | seconds |
|---|---|---|---|
num_beams=4, repetition_penalty=1.05 |
29.2 | 34.1 | 84 |
num_beams=4 |
28.0 | 34.1 | 84 |
num_beams=2 |
27.4 | 32.8 | 34 |
greedy, repetition_penalty=1.05 |
25.6 | 31.2 | 17 |
| greedy | 24.5 | 31.4 | 25 |
greedy, repetition_penalty=1.15 |
22.2 | 32.4 | 19 |
num_beams=4 scores highest but costs 5x greedy. num_beams=2 takes two thirds of the
gain for a third of the extra cost and is the better default; use 4 when quality matters
more than latency.
Do not raise repetition_penalty above 1.05. At 1.15, fr→mos drops to 22.2 chrF, the
worst of eight configs. The small gain at 1.05 does not transfer to the 4B sibling model,
where any repetition penalty is harmful; measure per checkpoint rather than inheriting a
default.
Limitations
- Low-resource. Mooré has little digital text; the model can produce disfluent or wrong output, especially on long or out-of-domain sentences.
- It invents word forms. Checked against the 129k-pair training corpus on
2026-08-24: several outputs contain words with zero occurrences in it
(
yonbẽ,wulga,marke,ne-yẽe). The output looks like Mooré and uses only alphabet-valid characters, which makes invented forms hard to spot without a speaker. - It translates, it does not converse. A question asked in Mooré that is not
a translation request comes back as a restatement of the question, not an
answer. Use it through the
<task>prompts above. - Tone is not written in the Mooré orthography, so homographs exist; the model can pick the wrong sense.
quality_judgmentis a heuristic aid, not a definitive verdict.- Outputs should be reviewed by a Mooré speaker before any downstream use.
- Downloads last month
- 35