Downloads · 30 days
44
10% of all-time downloads
Sharjeelbaig/ShaziLLM-1B
ShaziLLM-1B is a text generation model from Sharjeelbaig. Use it when you need the model to write or continue text. It is set up for transformers. The card lists the license as apache-2.0.
ShaziLLM-1B is a compact 1.08B-parameter instruction and reasoning language model designed for coding, structured instruction following, tool use, and local deployment. This repository contains the normal BF16 Transfo…
Downloads · 30 days
44
10% of all-time downloads
All-time downloads
422
Public
Parameters
1.1B
2.2 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors2.2 GB · 100%
From the Hugging Face model README
ShaziLLM-1B is a compact 1.08B-parameter instruction and reasoning language model designed for coding, structured instruction following, tool use, and local deployment. This repository contains the normal BF16 Transformers checkpoint.
For lower-memory CPU and browser inference, use ShaziLLM-1B-ONNX.
pip install -U transformers torch accelerate
import torch
from transformers import AutoModelForCausalLM, AutoTokenizer
model_id = "Sharjeelbaig/ShaziLLM-1B"
tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(
model_id,
dtype=torch.bfloat16,
device_map="auto",
)
messages = [{"role": "user", "content": "Write a Python function to merge two sorted lists."}]
text = tokenizer.apply_chat_template(
messages,
tokenize=False,
add_generation_prompt=True,
)
inputs = tokenizer(text, return_tensors="pt").to(model.device)
with torch.inference_mode():
output = model.generate(
**inputs,
max_new_tokens=256,
do_sample=False,
)
new_tokens = output[0, inputs.input_ids.shape[1]:]
print(tokenizer.decode(new_tokens, skip_special_tokens=True))
| Item | Value |
|---|---|
| Parameters | 1.08B |
| Layers | 24 |
| Hidden size | 1536 |
| Attention heads / KV heads | 16 / 2 |
| Vocabulary | 130,560 |
| Maximum configured context | 131,072 tokens |
| Weight format | BF16 Safetensors |
| Architecture | Llama-compatible causal language model |
The configured context limit is not a practical memory recommendation. Start with a much shorter context on low-memory hardware and increase it only after measuring KV-cache usage.
The release received a focused identity-alignment and capability-retention pass before export. A rank-8 LoRA adapter targeting the query and value projections was trained for four epochs at a 1e-4 learning rate on 48 short examples, with 1,032,192 trainable parameters. The adapter was merged into the BF16 checkpoint. Validation probes covered model identity, arithmetic, coding, and factual recall.
The BF16 checkpoint requires roughly 2.1 GB for weights alone, plus runtime and KV-cache memory. The separate ONNX INT8 release reduces weight storage and CPU inference memory substantially. Limit context and generated-token counts on constrained devices.
ShaziLLM-1B can hallucinate, produce incorrect code, and expose reasoning-like text. Do not treat its output as professional, security, legal, medical, or financial advice. Validate generated code before execution and isolate tool access behind deterministic authorization checks.
Released under Apache License 2.0; see LICENSE. ShaziLLM-1B is a fine-tuned derivative of OpenBMB/MiniCPM5-1B. The ShaziLLM name identifies this release and does not imply authorship of the upstream base architecture.