Text Generation
Transformers
Safetensors
English
qwen3
continued-pretraining
merged
bfloat16
conversational
text-generation-inference
Instructions to use CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16_olddata with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16_olddata with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16_olddata") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16_olddata") model = AutoModelForCausalLM.from_pretrained("CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16_olddata", 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=256) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16_olddata with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16_olddata" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16_olddata", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16_olddata
- SGLang
How to use CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16_olddata 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 "CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16_olddata" \ --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": "CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16_olddata", "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 "CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16_olddata" \ --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": "CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16_olddata", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16_olddata with Docker Model Runner:
docker model run hf.co/CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16_olddata
|
Download README.md from CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16_olddata: direct link, hf CLI and curl.
- Browser
- Download file 3.07 kB
-
https://huggingface.co/CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16_olddata/resolve/main/README.md
- Command line
-
hf download hf://CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16_olddata/README.md
-
curl -L -o README.md https://huggingface.co/CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16_olddata/resolve/main/README.md
3.07 kB
| license: apache-2.0 | |
| library_name: transformers | |
| pipeline_tag: text-generation | |
| language: en | |
| base_model: Qwen/Qwen3-8B-Base | |
| tags: | |
| - continued-pretraining | |
| - merged | |
| - bfloat16 | |
| # Qwen3-8B-Base-CPT-BF16 | |
| Standalone **BF16 (16-bit)** continued-pretraining model. This revision contains | |
| the complete model from **epoch 2, step 750**, in exactly **eight | |
| safetensors weight shards**. Load directly with Transformers. | |
| ## Epochs | |
| `main` contains epoch 2, the best training-time validation checkpoint. Each | |
| completed epoch is independently loadable using its `epoch-N` revision. Both | |
| training runs stopped after four epochs; there is no epoch-five export. | |
| | Revision | Training step | Training-time validation loss | | |
| |---|---:|---:| | |
| | [epoch-1](https://huggingface.co/CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16/tree/epoch-1) | 375 | 1.2472849 | | |
| | [epoch-2](https://huggingface.co/CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16/tree/epoch-2) | 750 | 1.2268945 | | |
| | [epoch-3](https://huggingface.co/CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16/tree/epoch-3) | 1125 | 1.2514912 | | |
| | [epoch-4](https://huggingface.co/CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16/tree/epoch-4) | 1500 | 1.2871689 | | |
| These losses were measured during adapter training, not by a new evaluation of | |
| the BF16 exports. Evaluate the four revisions separately to measure behavior | |
| changes across epochs. | |
| ## Load a specific epoch | |
| ```python | |
| import torch | |
| from transformers import AutoModelForCausalLM, AutoTokenizer | |
| model_id = "CompassioninMachineLearning/Qwen3-8B-Base-CPT-BF16" | |
| revision = "main" | |
| tokenizer = AutoTokenizer.from_pretrained(model_id, revision=revision) | |
| model = AutoModelForCausalLM.from_pretrained( | |
| model_id, revision=revision, dtype=torch.bfloat16, device_map="auto" | |
| ) | |
| ``` | |
| ## Merge provenance and validation | |
| - Original base: `Qwen/Qwen3-8B-Base` at `49e3418fbbbca6ecbdf9608b4d22e5a407081db4`. | |
| - Source adapter: [checkpoint 750](https://huggingface.co/ganscs/Qwen3-8b-qwen-h100-20260909-CPT-LoRA-checkpoints/tree/1586e45fc7c3f7d5e601dc454ba7e15884a2f1df/checkpoint-750). | |
| - Adapter repository revision: `1586e45fc7c3f7d5e601dc454ba7e15884a2f1df`. | |
| - Adapter SHA-256: `62933de6ac6e2484a5082afc7d4748c2267368cc7a3331fd874b93f4fe0e609b`. | |
| - Merged 252 rsLoRA layers with PEFT's safe merge. | |
| - The separately trained `embed_tokens` and `lm_head` matrices are included. | |
| Training used a 4-bit base; these exports merge the trained adapter into the | |
| pinned original BF16 base. The merge was performed using PEFT's safe merge, | |
| not Unsloth's export helper. Every tensor was checked for finite BF16 values and | |
| the complete architecture's names and shapes. Every epoch passed a standalone | |
| load, finite-logit forward pass and short greedy generation. No separate adapter | |
| is required, and optimizer/trainer checkpoint files are not included. | |
| `merge_manifest.json` records source and output checksums. `validation.json` | |
| records the inference smoke test. `training_manifest.json` preserves the training | |
| settings. Shard count controls packaging; BF16 specifies the 16-bit precision. | |