Instructions to use Cmr237/Camfranglais 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 Cmr237/Camfranglais 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 Cmr237/Camfranglais:Q4_K_M # Run inference directly in the terminal: llama cli -hf Cmr237/Camfranglais:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf Cmr237/Camfranglais:Q4_K_M # Run inference directly in the terminal: llama cli -hf Cmr237/Camfranglais:Q4_K_M
Build from source code
git clone https://github.com/ggml-org/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-app # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama serve -hf Cmr237/Camfranglais:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama cli -hf Cmr237/Camfranglais:Q4_K_M
Use Docker
docker model run hf.co/Cmr237/Camfranglais:Q4_K_M
- Llama new
- LM Studio
- Jan
- Ollama
How to use Cmr237/Camfranglais with Ollama:
ollama run hf.co/Cmr237/Camfranglais:Q4_K_M
- Unsloth Desktop
- Docker Model Runner
How to use Cmr237/Camfranglais with Docker Model Runner:
docker model run hf.co/Cmr237/Camfranglais:Q4_K_M
- Lemonade
How to use Cmr237/Camfranglais with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull Cmr237/Camfranglais:Q4_K_M
Run and chat with the model
lemonade run user.Camfranglais-Q4_K_M
List all available models
lemonade list
- Atomic Chat
Camfranglais LLM (Mistral-Nemo 12B โ CPT & SFT)
Ce dรฉpรดt contient les poids fine-tunรฉs (adaptateurs LoRA et quantifications GGUF) du modรจle Mistral-Nemo-Instruct-2407 (12B) adaptรฉ au Camfranglais, l'argot urbain camerounais mรชlant franรงais, anglais et pidgin.
L'ensemble du code source, du pipeline de collecte et de filtrage linguistique ainsi que les scripts d'รฉvaluation sont disponibles sur GitHub : darylbdr/CameroonianLLM.
Auteurs et Collaborateurs
Projet rรฉalisรฉ par :
Mรฉthodologie d'Entraรฎnement
Le modรจle a รฉtรฉ entraรฎnรฉ avec Unsloth sur GPU NVIDIA L4 en bfloat16 via QLoRA (r = 32, lora_alpha = 32, use_rslora = True, soit 114M de paramรจtres entraรฎnables) selon une approche hybride en deux phases :
- Phase 1 โ Continued Pre-Training (CPT) : prรฉ-entraรฎnement continu sur les 23 224 textes en Camfranglais du corpus
Cmr237/camfranglais-corpus-cpt(packing = True,lr = 1e-4) afin d'assimiler le vocabulaire et les tournures idiomatiques. - Phase 2 โ Supervised Fine-Tuning (SFT) : alignement conversationnel sur 2 671 dialogues du corpus
Cmr237/camfranglais-corpus-sft(2 404 train / 267 test) avec le template Mistral ([INST] ... [/INST]) et le calcul de la loss uniquement sur les rรฉponses de l'assistant (lr = 5e-5).
Rรฉsultats sur le jeu de test (267 dialogues)
| Mรฉtrique | Valeur |
|---|---|
| Eval Loss | 3.7362 |
| Perplexitรฉ | 41.94 |
| Score d'adhรฉrence Camfranglais moyen (Modรจle / Humain) | 0.1789 / 0.1551 |
| Taux de rรฉponses contenant des marqueurs Camfranglais | 81.27 % |
| Similaritรฉ Cosinus moyenne (Modรจle / Question) | 0.3891 |
Fichiers GGUF Disponibles
Quatre niveaux de quantification GGUF sont fournis dans ce dรฉpรดt selon votre configuration matรฉrielle :
| Fichier | Quantification | Taille approx. | Recommandation |
|---|---|---|---|
Camfranglais-Q8_0.gguf |
8-bit | ~13.0 Go | Qualitรฉ maximale, fidรฉlitรฉ quasi identique au 16-bit |
Camfranglais-Q6_K.gguf |
6-bit | ~10.0 Go | Trรจs haute prรฉcision, adaptรฉ aux configurations 16 Go RAM |
Camfranglais-Q5_K_M.gguf |
5-bit | ~8.7 Go | Bon compromis entre prรฉcision des poids LoRA et vitesse |
Camfranglais-Q4_K_M.gguf |
4-bit | ~7.5 Go | Lรฉger et rapide pour les configurations limitรฉes en mรฉmoire |
Utilisation
1. Avec Ollama
Un fichier Modelfile prรฉconfigurรฉ avec le prompt systรจme et le template Mistral est inclus dans le dรฉpรดt. Vous pouvez lancer directement la version souhaitรฉe :
ollama run hf.co/Cmr237/Camfranglais:Q5_K_M
Ou avec les autres quantifications :
ollama run hf.co/Cmr237/Camfranglais:Q8_0
ollama run hf.co/Cmr237/Camfranglais:Q6_K
ollama run hf.co/Cmr237/Camfranglais:Q4_K_M
2. Avec llama.cpp
llama-cli -hf Cmr237/Camfranglais:Q5_K_M --jinja -sys "Tu parles comme un camerounais"
3. Avec Python (Unsloth / Transformers)
Pour charger directement les adaptateurs LoRA sur GPU :
from unsloth import FastLanguageModel
model, tokenizer = FastLanguageModel.from_pretrained(
model_name="Cmr237/Camfranglais",
max_seq_length=2048,
load_in_4bit=True,
)
FastLanguageModel.for_inference(model)
messages = [
{"role": "system", "content": "Tu parles comme un camerounais"},
{"role": "user", "content": "Yo bro, on dit quoi depuis ?"},
]
inputs = tokenizer.apply_chat_template(
messages,
tokenize=True,
add_generation_prompt=True,
return_tensors="pt",
).to("cuda")
outputs = model.generate(input_ids=inputs, max_new_tokens=128, temperature=0.7)
print(tokenizer.decode(outputs[0][inputs.shape[1]:], skip_special_tokens=True))
- Downloads last month
- 1,357
4-bit
5-bit
6-bit
8-bit
Model tree for Cmr237/Camfranglais
Base model
mistralai/Mistral-Nemo-Base-2407