On August 28, Tencent Hunyuan released and open‑sourced its new‑generation flagship model Hy4 preview. The Zhongzhi(众智) FlagOS Community completed cross‑chip adaptation, precision alignment and deployment validation of Hy4 preview across AI chips. Multi‑chip‑adapted model images have been simultaneously released on ModelScope and HuggingFace. Developers can directly obtain out‑of‑the‑box solutions for their respective chips.
| Metrics | Hy4-preview-Nvidia-Origin | Hy4-preview-Hygon-FlagOS |
|---|---|---|
| GPQA_Diamond | 90.91 | Evaluating |
| Musr_team | 82.8 | Evaluating |
Environment Setup
| Item | Version |
|---|---|
| Docker Version | Docker version 27.3.1 |
| Operating System | 22.04 LTS |
docker pull harbor.baai.ac.cn/flagrelease-public/hy4-preview-hygon001-gems5.4.0-tree0.6.1-cxnone-plugin0.2.0-vllm0.24.0-cp310-pt210-dtk2604-x64-6.3.30-v1.4.1a:202608292346
pip install modelscope
modelscope download --model FlagRelease/Hy4-preview-INT8-hygon-FlagOS --local_dir /data/Hy4-preview
docker run -d --name flagos \
--network host --ipc host \
--device /dev/kfd --device /dev/mkfd --device /dev/dri \
--mount type=bind,src=/dev/infiniband,dst=/dev/infiniband \
--mount type=bind,src=/sys/class/infiniband,dst=/sys/class/infiniband,readonly \
--mount type=bind,src=/sys/class/infiniband_verbs,dst=/sys/class/infiniband_verbs,readonly \
--mount type=bind,src=/sys/class/net,dst=/sys/class/net,readonly \
--mount type=bind,src=/usr/etc/libibverbs.d,dst=/usr/etc/libibverbs.d,readonly \
--mount type=bind,src=/lib/x86_64-linux-gnu/libibverbs.so.1.14.44.0,dst=/lib/x86_64-linux-gnu/libibverbs.so.1.14.47.0,readonly \
--mount type=bind,src=/lib/x86_64-linux-gnu/libshca-rdmav34.so,dst=/lib/x86_64-linux-gnu/libshca-rdmav34.so,readonly \
--mount type=bind,src=/lib/x86_64-linux-gnu/libnl-3.so.200,dst=/lib/x86_64-linux-gnu/libnl-3.so.200,readonly \
--mount type=bind,src=/lib/x86_64-linux-gnu/libnl-route-3.so.200,dst=/lib/x86_64-linux-gnu/libnl-route-3.so.200,readonly \
-v /opt/hyhal:/opt/hyhal \
-v /data:/data:rslave \
-v /public-flash:/public-flash \
--group-add video \
--cap-add SYS_PTRACE \
--security-opt seccomp=unconfined \
--security-opt label=disable \
-e HSA_FORCE_FINE_GRAIN_PCIE=1 \
-e NCCL_IB_DISABLE=0 \
harbor.baai.ac.cn/flagos-inner-models-release/hy4-preview-hygon001-gems5.4.0-tree0.6.1-cxnone-plugin0.2.0-vllm0.24.0-cp310-pt210-dtk2604-x64-6.3.30-v1.4.1a:202608292346 \
bash -lc 'sleep infinity'
set +o nounset
source /opt/dtk-26.04-DCC2602-0317/env.sh
set -o nounset
export HIP_VISIBLE_DEVICES=0,1,2,3,4,5,6,7
export HSA_FORCE_FINE_GRAIN_PCIE=1
export TRITON_HIP_CLANG_PATH=/opt/dtk-26.04-DCC2602-0317/aillvm/bin/clang-18
export LD_LIBRARY_PATH="/opt/ucx-shca/lib:/opt/rccl-shca-net/lib:${LD_LIBRARY_PATH:-}"
export UCX_MODULE_DIR=/opt/ucx-shca/lib/ucx
export MASTER_ADDR=10.232.2.19
export GLOO_SOCKET_IFNAME=ib0
export NCCL_SOCKET_IFNAME=ib0
export NCCL_NET_PLUGIN=shca
export NCCL_IB_DISABLE=0
export NCCL_IB_HCA=shca_0,shca_1,shca_2,shca_3
export HF_HUB_OFFLINE=1
export TRANSFORMERS_OFFLINE=1
export HF_DATASETS_OFFLINE=1
# vLLM 0.24+ RPC timeout for execute_model calls (seconds).
# W8A8 quantized models need extra time on first inference for kernel compilation.
export VLLM_EXECUTE_MODEL_TIMEOUT_SECONDS=1800
vllm serve /data/Hy4-preview --served-model-name Hy4-preview-W8A8-linear-moe --trust-remote-code --distributed-executor-backend mp --nnodes 4 --node-rank 0 --master-addr 10.232.2.30 --master-port 29864 --distributed-timeout-seconds 1800 --tensor-parallel-size 16 --pipeline-parallel-size 2 --data-parallel-size 1 --load-format hy4_safetensors --disable-custom-all-reduce --moe-backend triton --max-model-len 131072 --max-num-seqs 64 --gpu-memory-utilization 0.95 --no-enable-log-requests --enable-expert-parallel --all2all-backend allgather_reducescatter --enable-ep-weight-filter --reasoning-parser hy_v4 --host 0.0.0.0 --port 8000
curl http://localhost:8000/v1/chat/completions \
-H "Content-Type: application/json" \
-d '{
"model": "flagOS",
"messages": [{"role": "user", "content": "hi"}]
}'
FlagOS is a fully open-source system software stack designed to unify the "model–system–chip" layers and foster an open, collaborative ecosystem. It enables a "develop once, run anywhere" workflow across diverse AI accelerators, unlocking hardware performance, eliminating fragmentation among vendor-specific software stacks, and substantially lowering the cost of porting and maintaining AI workloads. With core technologies such as the FlagScale, together with vllm-plugin-fl, distributed training/inference framework, FlagGems universal operator library, FlagCX communication library, and FlagTree unified compiler, the FlagRelease platform leverages the FlagOS stack to automatically produce and release various combinations of <chip + open-source model>. This enables efficient and automated model migration across diverse chips, opening a new chapter for large model deployment and application.
FlagGems is a high-performance, generic operator libraryimplemented in Triton language. It is built on a collection of backend-neutralkernels that aims to accelerate LLM (Large-Language Models) training and inference across diverse hardware platforms.
FlagTree is an open source, unified compiler for multipleAI chips project dedicated to developing a diverse ecosystem of AI chip compilers and related tooling platforms, thereby fostering and strengthening the upstream and downstream Triton ecosystem. Currently in its initial phase, the project aims to maintain compatibility with existing adaptation solutions while unifying the codebase to rapidly implement single-repository multi-backend support. Forupstream model users, it provides unified compilation capabilities across multiple backends; for downstream chip manufacturers, it offers examples of Triton ecosystem integration.
Flagscale is a comprehensive toolkit designed to supportthe entire lifecycle of large models. It builds on the strengths of several prominent open-source projects, including Megatron-LM and vLLM, to provide a robust, end-to-end solution for managing and scaling large models. vllm-plugin-fl is a vLLM plugin built on the FlagOS unified multi-chip backend, to help flagscale support multi-chip on vllm framework.
FlagCX is a scalable and adaptive cross-chip communication library. It serves as a platform where developers, researchers, and AI engineers can collaborate on various projects, contribute to the development of cutting-edge AI solutions, and share their work with the global community.
FlagEval is a comprehensive evaluation system and open platform for large models launched in 2023. It aims to establish scientific, fair, and open benchmarks, methodologies, and tools to help researchers assess model and training algorithm performance. It features:
We warmly welcome global developers to join us:
The model weights are derived from Tencent-Hunyuan/Hy4-preview and are open‑sourced under the Apache License 2.0: https://www.apache.org/licenses/LICENSE-2.0.txt
model-00002-of-00131.safetensors 9.7 GBmodel-00003-of-00131.safetensors 9.7 GBmodel-00005-of-00131.safetensors 9.7 GBmodel-00006-of-00131.safetensors 9.7 GBmodel-00008-of-00131.safetensors 9.7 GBmodel-00009-of-00131.safetensors 9.7 GBmodel-00011-of-00131.safetensors 9.7 GBmodel-00012-of-00131.safetensors 9.7 GBmodel-00014-of-00131.safetensors 9.7 GBmodel-00015-of-00131.safetensors 9.7 GBmodel-00017-of-00131.safetensors 9.7 GBmodel-00018-of-00131.safetensors 9.7 GBmodel-00020-of-00131.safetensors 9.7 GBmodel-00021-of-00131.safetensors 9.7 GBmodel-00023-of-00131.safetensors 9.7 GBmodel-00024-of-00131.safetensors 9.7 GBmodel-00026-of-00131.safetensors 9.7 GBmodel-00027-of-00131.safetensors 9.7 GBmodel-00028-of-00131.safetensors 9.7 GBmodel-00029-of-00131.safetensors 9.7 GBmodel-00030-of-00131.safetensors 9.7 GBmodel-00031-of-00131.safetensors 9.7 GBmodel-00032-of-00131.safetensors 9.7 GBmodel-00033-of-00131.safetensors 9.7 GBmodel-00034-of-00131.safetensors 9.7 GBmodel-00035-of-00131.safetensors 9.7 GBmodel-00036-of-00131.safetensors 9.7 GBmodel-00037-of-00131.safetensors 9.7 GBmodel-00038-of-00131.safetensors 9.7 GBmodel-00039-of-00131.safetensors 9.7 GBmodel-00040-of-00131.safetensors 9.7 GBmodel-00041-of-00131.safetensors 9.7 GBmodel-00043-of-00131.safetensors 9.7 GBmodel-00044-of-00131.safetensors 9.7 GBmodel-00046-of-00131.safetensors 9.7 GBmodel-00047-of-00131.safetensors 9.7 GBmodel-00051-of-00131.safetensors 9.7 GBmodel-00052-of-00131.safetensors 9.7 GBmodel-00056-of-00131.safetensors 9.7 GBmodel-00057-of-00131.safetensors 9.7 GBmodel-00061-of-00131.safetensors 9.7 GBmodel-00062-of-00131.safetensors 9.7 GBmodel-00066-of-00131.safetensors 9.7 GBmodel-00067-of-00131.safetensors 9.7 GBmodel-00071-of-00131.safetensors 9.7 GBmodel-00072-of-00131.safetensors 9.7 GBmodel-00076-of-00131.safetensors 9.7 GBmodel-00077-of-00131.safetensors 9.7 GBmodel-00081-of-00131.safetensors 9.7 GBmodel-00082-of-00131.safetensors 9.7 GBmodel-00086-of-00131.safetensors 9.7 GBmodel-00087-of-00131.safetensors 9.7 GBmodel-00091-of-00131.safetensors 9.7 GBmodel-00092-of-00131.safetensors 9.7 GBmodel-00096-of-00131.safetensors 9.7 GBmodel-00097-of-00131.safetensors 9.7 GBmodel-00101-of-00131.safetensors 9.7 GBmodel-00102-of-00131.safetensors 9.7 GBmodel-00106-of-00131.safetensors 9.7 GBmodel-00107-of-00131.safetensors 9.7 GBmodel-00111-of-00131.safetensors 9.7 GBmodel-00112-of-00131.safetensors 9.7 GBmodel-00116-of-00131.safetensors 9.7 GBmodel-00117-of-00131.safetensors 9.7 GBmodel-00121-of-00131.safetensors 9.7 GBmodel-00122-of-00131.safetensors 9.7 GBmodel-00127-of-00131.safetensors 9.7 GBmodel-00128-of-00131.safetensors 9.7 GBmodel-00001-of-00131.safetensors 9.7 GBmodel-00004-of-00131.safetensors 9.7 GBmodel-00007-of-00131.safetensors 9.7 GBmodel-00010-of-00131.safetensors 9.7 GBmodel-00013-of-00131.safetensors 9.7 GBmodel-00016-of-00131.safetensors 9.7 GBmodel-00019-of-00131.safetensors 9.7 GBmodel-00022-of-00131.safetensors 9.7 GBmodel-00025-of-00131.safetensors 9.7 GBmodel-00042-of-00131.safetensors 6.4 GBmodel-00045-of-00131.safetensors 3.2 GBmodel-00048-of-00131.safetensors 1.5 GBmodel-00053-of-00131.safetensors 1.5 GBmodel-00093-of-00131.safetensors 858 MBmodel-00109-of-00131.safetensors 805 MBmodel-00094-of-00131.safetensors 805 MBmodel-00084-of-00131.safetensors 805 MBmodel-00075-of-00131.safetensors 805 MBmodel-00110-of-00131.safetensors 805 MBmodel-00115-of-00131.safetensors 805 MBmodel-00054-of-00131.safetensors 805 MBmodel-00059-of-00131.safetensors 805 MBmodel-00069-of-00131.safetensors 805 MBmodel-00080-of-00131.safetensors 805 MBmodel-00085-of-00131.safetensors 805 MBmodel-00120-of-00131.safetensors 805 MBmodel-00108-of-00131.safetensors 730 MBmodel-00103-of-00131.safetensors 730 MBmodel-00130-of-00131.safetensors 717 MBmodel-00089-of-00131.safetensors 705 MBmodel-00104-of-00131.safetensors 705 MBmodel-00060-of-00131.safetensors 705 MBmodel-00049-of-00131.safetensors 705 MBmodel-00064-of-00131.safetensors 705 MBmodel-00074-of-00131.safetensors 705 MBmodel-00079-of-00131.safetensors 705 MBmodel-00090-of-00131.safetensors 705 MBmodel-00095-of-00131.safetensors 705 MBmodel-00100-of-00131.safetensors 705 MBmodel-00105-of-00131.safetensors 705 MBmodel-00131-of-00131.safetensors 705 MBmodel-00119-of-00131.safetensors 701 MBmodel-00078-of-00131.safetensors 695 MBmodel-00070-of-00131.safetensors 645 MBmodel-00073-of-00131.safetensors 638 MBmodel-00124-of-00131.safetensors 617 MBmodel-00083-of-00131.safetensors 609 MBmodel-00055-of-00131.safetensors 607 MBmodel-00099-of-00131.safetensors 599 MBmodel-00113-of-00131.safetensors 566 MBmodel-00118-of-00131.safetensors 548 MBmodel-00088-of-00131.safetensors 542 MBmodel-00123-of-00131.safetensors 541 MBmodel-00129-of-00131.safetensors 538 MBmodel-00058-of-00131.safetensors 538 MBmodel-00068-of-00131.safetensors 538 MBmodel-00063-of-00131.safetensors 538 MBmodel-00098-of-00131.safetensors 529 MBmodel-00114-of-00131.safetensors 508 MBmodel-00065-of-00131.safetensors 479 MBmodel-00125-of-00131.safetensors 450 MBmodel-00050-of-00131.safetensors 397 MBmodel-00126-of-00131.safetensors 201 MBHave the files? Submit a torrent.
Submit a torrentHave the complete files and permission to share them? Replace the example folder path. The script checks the files, makes a torrent and submits its magnet and checksums. Keep your torrent client seeding. Get your community key from your settings, and read the script before running it.
curl -fsSL https://pirateface.co/package.sh | bash -s -- --repo FlagRelease/Hy4-preview-INT8-hygon-FlagOS ./model-folder