CoolFace
Modelpublic

Congo-digital-service/Llama-3.1-8B-Instruct-Lingala-QLoRA-merged-v2

sourceHugging Facellama3.1updated 20d agoView on Hugging Face
0likes756downloads
Model Card

๐Ÿ‡จ๐Ÿ‡ฌ Llama-3.1-8B-Instruct-Lingala-QLoRA-merged-v2

A Meta-Llama-3.1-8B-Instruct model adapted to Lingala through supervised fine-tuning (QLoRA/LoRA), developed by Congo Digital Services (CDS). This model is intended for conversation, text generation, summarization, translation, and classification in Lingala.

๐Ÿ”— Sister model: QLoRA adapters only are available at `Congo-digital-service/Llama-3.1-8B-Instruct-Lingala-QLoRA-adapters`

Model Details

Model Description

  • โ€”Developed by: Congo Digital Services (CDS SARL) โ€” congo-digital.com
  • โ€”Base model: meta-llama/Meta-Llama-3.1-8B-Instruct
  • โ€”Adaptation method: Supervised fine-tuning via QLoRA/LoRA
  • โ€”Language: Lingala (ln)
  • โ€”Model type: Causal language model, 8B parameters, merged
  • โ€”License: Llama 3.1 Community License
  • โ€”Functional objectives: Conversation, text generation, summarization, translation, classification, and conversational responses tailored to Lingala

Model Sources

Uses

Direct Use

This model can be used directly for conversational text generation in Lingala via the standard transformers API, or deployed behind a compatible inference server (see Deployment Infrastructure below).

Out-of-Scope Use

This model is not intended for use cases requiring critical factual accuracy (medical, legal domains) without human oversight, nor for certified professional translation tasks.

How to Get Started with the Model

python
from transformers import AutoModelForCausalLM, AutoTokenizer

model_id = "Congo-digital-service/Llama-3.1-8B-Instruct-Lingala-QLoRA-merged-v2"

tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(model_id, device_map="auto")

messages = [
    {"role": "user", "content": "Loba na ngai na lingala : ndenge nini okoki kosala mombongo na Kinshasa ?"}
]

inputs = tokenizer.apply_chat_template(messages, return_tensors="pt").to(model.device)
outputs = model.generate(inputs, max_new_tokens=256, temperature=0.7)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))

Training Details

Training Data

A unified corpus of 4,818 examples across five stylistic categories:

CategoryExamples
Urban1,425
Educational1,063
Summarization1,041
Formal889
Translation400

Split: stratified 80/20 split โ†’ 3,854 initial training examples / 964 test examples (unaugmented, held out for independent evaluation).

Augmentation: applied only to the training set to balance categories at 1,140 examples each, resulting in a final training set of 5,700 examples.

Training Procedure

  • โ€”Environment: Google Colab, with checkpoints and run logs saved to Google Drive
Training Hyperparameters
ParameterValue
Epochs3
Batch size2
Gradient accumulation steps8 (effective batch = 16)
Initial learning rate2 ร— 10โปโต
SchedulerCosine
Intermediate evaluationsEvery 200 steps
Training Convergence
StepTraining LossValidation LossEntropyMean Token Accuracy
2001.56381.57471.614167.15%
4001.30081.35141.342569.81%
6001.27141.29011.314670.83%
8001.20721.27411.266971.14%
10001.22111.27201.269071.15%
10711.19561.27201.268971.19%

Validation loss decreases steadily throughout training with no sign of overfitting.

Evaluation

Evaluation performed on the independent test set (964 examples), held out during training.

Final Results

MetricBase ModelFine-tuned ModelImprovement
ROUGE-L F1 (primary metric)0.15210.2379+56.4%
Mean Token Accuracyโ€”71.20%โ€”
Token F1 (lexical)0.1721โ€”โ€”
Perplexityโ€”17.7211โ€”
ROUGE-1โ€”0.2939โ€”
ROUGE-2โ€”0.0789โ€”
BLEU (SacreBLEU for base)2.32800.0459not representative*
Exact match0.00%not computedโ€”

\ BLEU proves unrepresentative for open-ended generation tasks; progress is primarily measured via ROUGE-L.*

Summary

The QLoRA adaptation delivers a robust, measurable performance gain: the fine-tuned model handles Lingala's linguistic structures significantly better than the base model, with a +56.4% relative gain in ROUGE-L F1.

Human Evaluation

  • โ€”Operational target: โ‰ฅ 85% of responses rated acceptable (per the project's Terms of Reference)
  • โ€”Dimensions evaluated: Lingala correctness, coherence and meaning, instruction adherence, business relevance

Target Deployment Infrastructure

ComponentDetail
Inference servervLLM deployed on GPU pods
Gateway / authLiteLLM v1.87.0 + PostgreSQL 16
EndpointPOST ${VLLM_BASE_URL}/v1/chat/completions
FormatOpenAI Chat Completions compatible (choices[0].message.content)
Access interfaceLoBAI (LibreChat-based) with Keycloak / OpenID Connect

Traceability

Bias, Risks, and Limitations

This model was trained on a moderately sized corpus (5,700 augmented examples) covering five stylistic registers. Performance may vary outside these registers, particularly on regional Lingala dialects not represented in the corpus, or on specialized technical domains absent from the training set. Users should validate model outputs before any high-stakes use.

Environmental Impact

Training was performed on Google Colab infrastructure. Carbon emissions can be estimated using the ML Impact calculator (Lacoste et al., 2019).

Citation

BibTeX:

bibtex
@misc{cds2026lingala,
  title={Llama-3.1-8B-Instruct-Lingala-QLoRA},
  author={Congo Digital Services},
  year={2026},
  howpublished={\url{https://huggingface.co/Congo-digital-service/Llama-3.1-8B-Instruct-Lingala-QLoRA-merged-v2}}
}

Contact