Instructions to use issai/Qwen3.5-9B-Base-Kazakh with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use issai/Qwen3.5-9B-Base-Kazakh with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="issai/Qwen3.5-9B-Base-Kazakh") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("issai/Qwen3.5-9B-Base-Kazakh") model = AutoModelForCausalLM.from_pretrained("issai/Qwen3.5-9B-Base-Kazakh", 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 issai/Qwen3.5-9B-Base-Kazakh with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "issai/Qwen3.5-9B-Base-Kazakh" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "issai/Qwen3.5-9B-Base-Kazakh", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/issai/Qwen3.5-9B-Base-Kazakh
- SGLang
How to use issai/Qwen3.5-9B-Base-Kazakh 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 "issai/Qwen3.5-9B-Base-Kazakh" \ --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": "issai/Qwen3.5-9B-Base-Kazakh", "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 "issai/Qwen3.5-9B-Base-Kazakh" \ --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": "issai/Qwen3.5-9B-Base-Kazakh", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use issai/Qwen3.5-9B-Base-Kazakh with Docker Model Runner:
docker model run hf.co/issai/Qwen3.5-9B-Base-Kazakh
Qwen3.5-9B-Base-Kazakh
Kazakh-adapted continued-pretraining (CPT) of Qwen/Qwen3.5-9B-Base.
It extends the original Qwen3.5 base with 16K new Kazakh tokens and continues pretraining on a large Kazakh + English corpus, to improve Kazakh fluency and knowledge while retaining the original English capabilities.
Training details
- Tokenizer extension (+16K). The Qwen3.5 tokenizer (248,320) was extended with 16,000
new, predominantly Cyrillic-Kazakh tokens → 264,192 total. New embedding rows were
initialized with FVT (Fast Vocabulary Transfer): each new row is the unweighted mean
of its constituent original sub-token embeddings, giving the model a warm start on the new
vocabulary. Applied under untied embeddings (FVT applied to both the input embeddings and the separate
lm_head). - Continued pretraining. Full-parameter CPT for one epoch at sequence length 32,768, learning rate 1e-5 (cosine → 1e-6, 2% warmup), weight decay 0.1, gradient clip 1.0, on 2× 8×H100.
Data
~15.9B new tokenizer tokens total with a 50/50 Kazakh:English mix. The Kazakh half is a cross-source deduplicated corpus (FineWeb-2, CulturaX, FinePDFs, FineWiki). The English half is a replay mix for retention (FineWeb-Edu web, Nemotron-CC math + wiki-rewrite, Stack-Edu code). Additional curated Kazakh sets (cultural/QA/encyclopedic) were folded in and upsampled 3×.
Usage
from transformers import AutoModelForCausalLM, AutoTokenizer
name = "issai/Qwen3.5-9B-Base-Kazakh"
tokenizer = AutoTokenizer.from_pretrained(name)
model = AutoModelForCausalLM.from_pretrained(name, torch_dtype="bfloat16", device_map="auto")
prompt = "Сұрақ: Үстірт қорығы қай облыста орналасқан?\nЖауап:"
ids = tokenizer(prompt, return_tensors="pt").to(model.device)
print(tokenizer.decode(model.generate(**ids, max_new_tokens=100)[0][ids.input_ids.shape[1]:]))
Requires a recent transformers with Qwen3.5 support (>=5.9).
License & attribution
Continued-pretrained from Qwen/Qwen3.5-9B-Base; the original Qwen3.5 weights and their Apache-2.0
license apply.
- Downloads last month
- 232