Text Generation
Transformers
Safetensors
English
qwen3
petroleum-engineering
oil-and-gas
nigeria
unsloth
lora
fine-tuned
conversational
text-generation-inference
Instructions to use Shinzmann/naija-petro-8b with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Shinzmann/naija-petro-8b with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Shinzmann/naija-petro-8b") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Shinzmann/naija-petro-8b") model = AutoModelForCausalLM.from_pretrained("Shinzmann/naija-petro-8b", 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 Shinzmann/naija-petro-8b with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Shinzmann/naija-petro-8b" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Shinzmann/naija-petro-8b", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/Shinzmann/naija-petro-8b
- SGLang
How to use Shinzmann/naija-petro-8b 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 "Shinzmann/naija-petro-8b" \ --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": "Shinzmann/naija-petro-8b", "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 "Shinzmann/naija-petro-8b" \ --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": "Shinzmann/naija-petro-8b", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Unsloth Studio
How to use Shinzmann/naija-petro-8b 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 Shinzmann/naija-petro-8b 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 Shinzmann/naija-petro-8b to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for Shinzmann/naija-petro-8b to start chatting
Load model with FastModel
pip install unsloth from unsloth import FastModel model, tokenizer = FastModel.from_pretrained( model_name="Shinzmann/naija-petro-8b", max_seq_length=2048, ) - Docker Model Runner
How to use Shinzmann/naija-petro-8b with Docker Model Runner:
docker model run hf.co/Shinzmann/naija-petro-8b
Update model card (standardized)
Browse files
README.md
CHANGED
|
@@ -17,7 +17,7 @@ tags:
|
|
| 17 |
|
| 18 |
# Naija-Petro 8B
|
| 19 |
|
| 20 |
-
**Naija-Petro 8B** is a [Qwen3-8B](https://huggingface.co/Qwen/Qwen3-8B) model fine-tuned (QLoRA, [Unsloth](https://github.com/unslothai/unsloth)) on ~20,000 synthetic petroleum-engineering instruction
|
| 21 |
|
| 22 |
> ⚠️ The base training data is **general/global** petroleum knowledge. For Nigeria-specific facts (regulation, the PIA 2021, NUPRC/NMDPRA/NNPC), pair this model with the [Naija-Petro RAG system](https://github.com/Mystique1337/naija-petro), which grounds answers in verifiable Nigerian sources.
|
| 23 |
|
|
@@ -28,7 +28,7 @@ tags:
|
|
| 28 |
- **Language:** English
|
| 29 |
- **License:** Apache-2.0 (inherited from Qwen3-8B)
|
| 30 |
- **Finetuned from:** [`Qwen/Qwen3-8B`](https://huggingface.co/Qwen/Qwen3-8B)
|
| 31 |
-
- **Domain:** Petroleum engineering
|
| 32 |
|
| 33 |
### Model sources
|
| 34 |
- **Repository:** https://github.com/Mystique1337/naija-petro
|
|
@@ -38,7 +38,7 @@ tags:
|
|
| 38 |
## Uses
|
| 39 |
|
| 40 |
### Direct use
|
| 41 |
-
Technical question answering and explanation across petroleum-engineering subdomains: concepts, equations and derivations, workflow guidance, and terminology
|
| 42 |
|
| 43 |
### Downstream use
|
| 44 |
Backbone for retrieval-augmented assistants (see the project repo), further domain fine-tuning, or distillation.
|
|
@@ -85,7 +85,7 @@ ollama run hf.co/Shinzmann/naija-petro-8b-GGUF:Q4_K_M
|
|
| 85 |
## Training details
|
| 86 |
|
| 87 |
### Data
|
| 88 |
-
~20,000 instruction
|
| 89 |
|
| 90 |
### Procedure
|
| 91 |
QLoRA (4-bit NF4) with Unsloth on a single A100 80GB.
|
|
|
|
| 17 |
|
| 18 |
# Naija-Petro 8B
|
| 19 |
|
| 20 |
+
**Naija-Petro 8B** is a [Qwen3-8B](https://huggingface.co/Qwen/Qwen3-8B) model fine-tuned (QLoRA, [Unsloth](https://github.com/unslothai/unsloth)) on ~20,000 synthetic petroleum-engineering instruction-response pairs. It is the lightweight, fast-inference variant of the Naija-Petro family and the model served behind the project's retrieval-augmented assistant.
|
| 21 |
|
| 22 |
> ⚠️ The base training data is **general/global** petroleum knowledge. For Nigeria-specific facts (regulation, the PIA 2021, NUPRC/NMDPRA/NNPC), pair this model with the [Naija-Petro RAG system](https://github.com/Mystique1337/naija-petro), which grounds answers in verifiable Nigerian sources.
|
| 23 |
|
|
|
|
| 28 |
- **Language:** English
|
| 29 |
- **License:** Apache-2.0 (inherited from Qwen3-8B)
|
| 30 |
- **Finetuned from:** [`Qwen/Qwen3-8B`](https://huggingface.co/Qwen/Qwen3-8B)
|
| 31 |
+
- **Domain:** Petroleum engineering covering drilling, reservoir, production, completions, EOR, well testing, petroleum geoscience
|
| 32 |
|
| 33 |
### Model sources
|
| 34 |
- **Repository:** https://github.com/Mystique1337/naija-petro
|
|
|
|
| 38 |
## Uses
|
| 39 |
|
| 40 |
### Direct use
|
| 41 |
+
Technical question answering and explanation across petroleum-engineering subdomains: concepts, equations and derivations, workflow guidance, and terminology, as a study aid and engineering decision-support tool.
|
| 42 |
|
| 43 |
### Downstream use
|
| 44 |
Backbone for retrieval-augmented assistants (see the project repo), further domain fine-tuning, or distillation.
|
|
|
|
| 85 |
## Training details
|
| 86 |
|
| 87 |
### Data
|
| 88 |
+
~20,000 instruction-response pairs generated with **NVIDIA NeMo Data Designer** from a scraped, de-duplicated petroleum corpus (arXiv, Semantic Scholar, OpenAlex, Crossref, DOE/OSTI, PetroWiki, the SLB glossary, EIA, and more), with an LLM-as-judge quality-scoring pass. Pipeline and EDA are in the [project notebooks](https://github.com/Mystique1337/naija-petro/tree/main/notebooks).
|
| 89 |
|
| 90 |
### Procedure
|
| 91 |
QLoRA (4-bit NF4) with Unsloth on a single A100 80GB.
|