Files
SwahiliInstruct-v0.2/README.md
ModelHub XC 17a8188cd3 初始化项目,由ModelHub XC社区提供模型
Model: mwitiderrick/SwahiliInstruct-v0.2
Source: Original Platform
2026-06-21 11:20:32 +08:00

4.8 KiB

language, license, library_name, tags, datasets, base_model, inference, model_type, created_by, pipeline_tag, model-index
language license library_name tags datasets base_model inference model_type created_by pipeline_tag model-index
en
apache-2.0 transformers
transformers
mwitiderrick/SwahiliAlpaca
mistralai/Mistral-7B-Instruct-v0.2 true mistral mwitiderrick text-generation
name results
SwahiliInstruct-v0.2
task dataset metrics source
type name
text-generation Text Generation
name type config split args
AI2 Reasoning Challenge (25-Shot) ai2_arc ARC-Challenge test
num_few_shot
25
type value name
acc_norm 55.2 normalized accuracy
url name
https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=mwitiderrick/SwahiliInstruct-v0.2 Open LLM Leaderboard
task dataset metrics source
type name
text-generation Text Generation
name type split args
HellaSwag (10-Shot) hellaswag validation
num_few_shot
10
type value name
acc_norm 78.22 normalized accuracy
url name
https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=mwitiderrick/SwahiliInstruct-v0.2 Open LLM Leaderboard
task dataset metrics source
type name
text-generation Text Generation
name type config split args
MMLU (5-Shot) cais/mmlu all test
num_few_shot
5
type value name
acc 50.3 accuracy
url name
https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=mwitiderrick/SwahiliInstruct-v0.2 Open LLM Leaderboard
task dataset metrics source
type name
text-generation Text Generation
name type config split args
TruthfulQA (0-shot) truthful_qa multiple_choice validation
num_few_shot
0
type value
mc2 57.08
url name
https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=mwitiderrick/SwahiliInstruct-v0.2 Open LLM Leaderboard
task dataset metrics source
type name
text-generation Text Generation
name type config split args
Winogrande (5-shot) winogrande winogrande_xl validation
num_few_shot
5
type value name
acc 73.24 accuracy
url name
https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=mwitiderrick/SwahiliInstruct-v0.2 Open LLM Leaderboard
task dataset metrics source
type name
text-generation Text Generation
name type config split args
GSM8k (5-shot) gsm8k main test
num_few_shot
5
type value name
acc 11.45 accuracy
url name
https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=mwitiderrick/SwahiliInstruct-v0.2 Open LLM Leaderboard

SwahiliInstruct-v0.2

This is a Mistral model that has been fine-tuned on the Swahili Alpaca dataset for 3 epochs.

Prompt Template

### Maelekezo:

{query}

### Jibu:
<Leave new line for model to respond> 

Usage

# Load model directly
from transformers import AutoTokenizer, AutoModelForCausalLM

tokenizer = AutoTokenizer.from_pretrained("mwitiderrick/SwahiliInstruct-v0.2")
model = AutoModelForCausalLM.from_pretrained("mwitiderrick/SwahiliInstruct-v0.2", device_map="auto")
query = "Nipe maagizo ya kutengeneza mkate wa mandizi"
text_gen = pipeline(task="text-generation", model=model, tokenizer=tokenizer, max_length=200, do_sample=True, repetition_penalty=1.1)
output = text_gen(f"### Maelekezo:\n{query}\n### Jibu:\n")
print(output[0]['generated_text'])


"""
 Maagizo ya kutengeneza mkate wa mandazi:
1. Preheat tanuri hadi 375°F (190°C).
2. Paka sufuria ya uso na siagi au jotoa sufuria.
3. Katika bakuli la chumvi, ongeza viungo vifuatavyo: unga, sukari ya kahawa, chumvi, mdalasini, na unga wa kakao.
Koroga mchanganyiko pamoja na mbegu za kikombe 1 1/2 za mtindi wenye jamii na hatua ya maji nyepesi.
4. Kando ya uwanja, changanya zaini ya yai 2
"""

Open LLM Leaderboard Evaluation Results

Detailed results can be found here

Metric Value
Avg. 54.25
AI2 Reasoning Challenge (25-Shot) 55.20
HellaSwag (10-Shot) 78.22
MMLU (5-Shot) 50.30
TruthfulQA (0-shot) 57.08
Winogrande (5-shot) 73.24
GSM8k (5-shot) 11.45