Instructions to use AxionLab-official/MiniBot-0.9M-Instruct with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use AxionLab-official/MiniBot-0.9M-Instruct with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="AxionLab-official/MiniBot-0.9M-Instruct")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("AxionLab-official/MiniBot-0.9M-Instruct") model = AutoModelForCausalLM.from_pretrained("AxionLab-official/MiniBot-0.9M-Instruct") - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use AxionLab-official/MiniBot-0.9M-Instruct with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "AxionLab-official/MiniBot-0.9M-Instruct" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "AxionLab-official/MiniBot-0.9M-Instruct", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/AxionLab-official/MiniBot-0.9M-Instruct
- SGLang
How to use AxionLab-official/MiniBot-0.9M-Instruct 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 "AxionLab-official/MiniBot-0.9M-Instruct" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "AxionLab-official/MiniBot-0.9M-Instruct", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'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 "AxionLab-official/MiniBot-0.9M-Instruct" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "AxionLab-official/MiniBot-0.9M-Instruct", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use AxionLab-official/MiniBot-0.9M-Instruct with Docker Model Runner:
docker model run hf.co/AxionLab-official/MiniBot-0.9M-Instruct
Update README.md
Browse files
README.md
CHANGED
|
@@ -1,3 +1,147 @@
|
|
| 1 |
-
---
|
| 2 |
-
license: mit
|
| 3 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: mit
|
| 3 |
+
language:
|
| 4 |
+
- pt
|
| 5 |
+
pipeline_tag: text-generation
|
| 6 |
+
---
|
| 7 |
+
|
| 8 |
+
## 🧠 MiniBot-0.9M-Instruct
|
| 9 |
+
|
| 10 |
+
Instruction-tuned GPT-2 style language model (~900K parameters) optimized for Portuguese conversational tasks.
|
| 11 |
+
|
| 12 |
+
## 📌 Model Overview
|
| 13 |
+
|
| 14 |
+
MiniBot-0.9M-Instruct is an instruction-tuned version of MiniBot-0.9M-Base, designed to better follow prompts, respond to user inputs, and generate more coherent conversational outputs in Portuguese.
|
| 15 |
+
|
| 16 |
+
Built on a GPT-2 architecture (~0.9M parameters), this model was fine-tuned on conversational and instruction-style data to improve usability in real-world interactions.
|
| 17 |
+
|
| 18 |
+
🎯 Key Characteristics
|
| 19 |
+
🇧🇷 Language: Portuguese (primary)
|
| 20 |
+
🧠 Architecture: GPT-2 style (decoder-only Transformer)
|
| 21 |
+
🔤 Embeddings: GPT-2 compatible
|
| 22 |
+
📉 Parameters: ~900K
|
| 23 |
+
⚙️ Base Model: MiniBot-0.9M-Base
|
| 24 |
+
🎯 Fine-tuning: Instruction tuning (supervised)
|
| 25 |
+
✅ Alignment: Basic prompt-following behavior
|
| 26 |
+
🧠 What Changed from Base?
|
| 27 |
+
|
| 28 |
+
Compared to the base model:
|
| 29 |
+
|
| 30 |
+
Feature Base Instruct
|
| 31 |
+
Prompt understanding ❌ ✅
|
| 32 |
+
Conversational flow ⚠️ ✅
|
| 33 |
+
Instruction following ❌ ✅
|
| 34 |
+
Coherence Baixa Melhorada
|
| 35 |
+
Usability Experimental Practical
|
| 36 |
+
|
| 37 |
+
👉 The model is now significantly more usable in chat scenarios.
|
| 38 |
+
|
| 39 |
+
🏗️ Architecture
|
| 40 |
+
|
| 41 |
+
Same core as base:
|
| 42 |
+
|
| 43 |
+
Decoder-only Transformer (GPT-2 style)
|
| 44 |
+
Token + positional embeddings
|
| 45 |
+
Self-attention + MLP blocks
|
| 46 |
+
Autoregressive generation
|
| 47 |
+
|
| 48 |
+
No architectural changes — only behavioral improvement via fine-tuning.
|
| 49 |
+
|
| 50 |
+
📚 Fine-Tuning
|
| 51 |
+
Dataset
|
| 52 |
+
|
| 53 |
+
The model was fine-tuned on a Portuguese instruction-style conversational dataset, including:
|
| 54 |
+
|
| 55 |
+
Perguntas e respostas
|
| 56 |
+
Instruções simples
|
| 57 |
+
Chat estilo assistente
|
| 58 |
+
Roleplay básico
|
| 59 |
+
Conversas naturais
|
| 60 |
+
Format
|
| 61 |
+
User: Me explique o que é gravidade
|
| 62 |
+
Bot: A gravidade é a força que atrai objetos com massa...
|
| 63 |
+
Strategy
|
| 64 |
+
Supervised fine-tuning (SFT)
|
| 65 |
+
Pattern learning for instruction-following
|
| 66 |
+
No RLHF or preference optimization
|
| 67 |
+
💡 Capabilities
|
| 68 |
+
|
| 69 |
+
✅ Strengths:
|
| 70 |
+
|
| 71 |
+
Seguir instruções simples
|
| 72 |
+
Responder perguntas básicas
|
| 73 |
+
Conversar de forma mais natural
|
| 74 |
+
Melhor coerência em respostas curtas
|
| 75 |
+
Estrutura de diálogo mais consistente
|
| 76 |
+
|
| 77 |
+
❌ Limitations:
|
| 78 |
+
|
| 79 |
+
Raciocínio ainda limitado
|
| 80 |
+
Pode errar fatos
|
| 81 |
+
Não mantém contexto longo
|
| 82 |
+
Sensível a prompts mal estruturados
|
| 83 |
+
|
| 84 |
+
👉 Mesmo com instruct tuning, ainda é um modelo extremamente pequeno.
|
| 85 |
+
|
| 86 |
+
🚀 Usage
|
| 87 |
+
Hugging Face Transformers
|
| 88 |
+
```Python
|
| 89 |
+
from transformers import AutoTokenizer, AutoModelForCausalLM
|
| 90 |
+
|
| 91 |
+
model_name = "AxionLab-official/MiniBot-0.9M-Instruct"
|
| 92 |
+
|
| 93 |
+
tokenizer = AutoTokenizer.from_pretrained(model_name)
|
| 94 |
+
model = AutoModelForCausalLM.from_pretrained(model_name)
|
| 95 |
+
|
| 96 |
+
prompt = "User: Me diga uma curiosidade sobre o espaço\nBot:"
|
| 97 |
+
inputs = tokenizer(prompt, return_tensors="pt")
|
| 98 |
+
|
| 99 |
+
outputs = model.generate(
|
| 100 |
+
**inputs,
|
| 101 |
+
max_new_tokens=80,
|
| 102 |
+
temperature=0.7,
|
| 103 |
+
top_p=0.9,
|
| 104 |
+
do_sample=True
|
| 105 |
+
)
|
| 106 |
+
|
| 107 |
+
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
|
| 108 |
+
```
|
| 109 |
+
|
| 110 |
+
⚙️ Recommended Settings
|
| 111 |
+
|
| 112 |
+
Para melhor qualidade:
|
| 113 |
+
|
| 114 |
+
temperature: 0.6 – 0.8
|
| 115 |
+
top_p: 0.85 – 0.95
|
| 116 |
+
do_sample: True
|
| 117 |
+
max_new_tokens: 40 – 100
|
| 118 |
+
|
| 119 |
+
👉 Instruct models tendem a performar melhor com menos aleatoriedade.
|
| 120 |
+
|
| 121 |
+
🧪 Intended Use
|
| 122 |
+
💬 Chatbots leves em português
|
| 123 |
+
🎮 NPCs e jogos
|
| 124 |
+
🧠 Testes de fine-tuning
|
| 125 |
+
📚 Educação em NLP
|
| 126 |
+
⚡ Aplicações locais (CPU-only)
|
| 127 |
+
⚠️ Limitations
|
| 128 |
+
|
| 129 |
+
Modelo extremamente pequeno
|
| 130 |
+
Sem alinhamento robusto
|
| 131 |
+
Pode gerar respostas incorretas
|
| 132 |
+
Não adequado para produção crítica
|
| 133 |
+
|
| 134 |
+
🔮 Future Work
|
| 135 |
+
🧠 Reasoning-tuned version (MiniBot-Reason)
|
| 136 |
+
📈 Scaling para 1M–10M parâmetros
|
| 137 |
+
📚 Dataset mais diverso
|
| 138 |
+
🤖 Melhor alinhamento de respostas
|
| 139 |
+
🧩 Tool-use experiments
|
| 140 |
+
|
| 141 |
+
📜 License
|
| 142 |
+
|
| 143 |
+
MIT
|
| 144 |
+
|
| 145 |
+
👤 Author
|
| 146 |
+
|
| 147 |
+
Developed by AxionLab
|