Instructions to use Montlok/DoL-1.2-Base with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Montlok/DoL-1.2-Base with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Montlok/DoL-1.2-Base", trust_remote_code=True)# pip install -U transformers accelerate # Load model directly from transformers import AutoModelForCausalLM model = AutoModelForCausalLM.from_pretrained("Montlok/DoL-1.2-Base", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use Montlok/DoL-1.2-Base with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Montlok/DoL-1.2-Base" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Montlok/DoL-1.2-Base", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/Montlok/DoL-1.2-Base
- SGLang
How to use Montlok/DoL-1.2-Base 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 "Montlok/DoL-1.2-Base" \ --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": "Montlok/DoL-1.2-Base", "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 "Montlok/DoL-1.2-Base" \ --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": "Montlok/DoL-1.2-Base", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use Montlok/DoL-1.2-Base with Docker Model Runner:
docker model run hf.co/Montlok/DoL-1.2-Base
DoL 1.2
传统蒙古文 decoder-only 基础语言模型。
同字异码(homoglyph):传统蒙古文中,O(U+1823)与 U(U+1824)写法相同,OE(U+1825)与 UE(U+1826)写法相同。本模型的蒙古文训练文本对这些码位的使用不一致,分词器和模型中同一词形存在多种编码:词表中有 943 个词形对应不止一个词元,例如“蒙古”对应 4794、7788、5827 三个词元。生成文本可能混用这些编码;显示正确的文本在码位上可能与规范写法不同,会影响检索、去重、按字符串比对的评测和基于规则的奖励。
不建议在研究或生产中把本模型作为基础模型继续预训练或微调,也不建议直接在本模型上进行强化学习。
Tokenizer
DoL bundle_v3b 双轨 tokenizer:传统蒙古文使用形态感知分词,其他文本使用通用
BPE 与 byte fallback。词表大小为 65,536,pad/unk/bos/eos = 0/1/2/3。
Transformer
Two-Stage Recurrent-Depth Transformer:3 层 MLA Prelude、5 层因果 Mamba-3、 1 个共享 MLA/SwiGLU 循环块(默认循环 8 次)和 3 层 MLA Coda。hidden size 2,048、 16 个 attention heads、FFN 8,192,使用 Morphological RoPE 和 tied embedding/LM head,共约 969M 参数。
- Downloads last month
- 15