ApX logoApX logo

Hunyuan Large

Active Parameters

389B

Context Length

28K

Modality

Text

Architecture

Mixture of Experts (MoE)

License

Tencent Hunyuan Community License

Release Date

5 Nov 2024

Knowledge Cutoff

Sep 2024

System Requirements

VRAM requirements for different quantization methods and context sizes

1,024 tokens

820.51 GB VRAM

Consumer

46x RTX 4090

24GB VRAM

Datacenter

12x NVIDIA A100

80GB VRAM

Apple Silicon

10x Apple M3 Max

128GB VRAM

28,000 tokens

876.20 GB VRAM

Consumer

50x RTX 4090

24GB VRAM

Datacenter

13x NVIDIA A100

80GB VRAM

Apple Silicon

10x Apple M3 Max

128GB VRAM

Architecture Diagram

Input TokensToken EmbeddingPosition: AbsoluteHidden: 4.1k · Context: 28Kx 60 layersLayerNormPre-AttentionMulti-Head Attention64Q / 64KV headsHead dim: 64+LayerNormPre-FFNSparse MoE FFN (2/32 experts)GELU+Final LayerNormOutput Logits

Evaluation Benchmarks

Rank

#105

BenchmarkScoreRank

General Text

Text Arena

1326

113

Rankings

Overall Rank

#105

Coding Rank

-

About Hunyuan Large

Hunyuan-DiT is a large-scale Mixture-of-Experts (MoE) diffusion transformer designed for high-fidelity image generation. It represents Tencent's advancement in generative AI, applying a transformer architecture directly to the latent space of image generation. Its primary function is to synthesize diverse and high-quality images from textual prompts, thereby enabling content creation and visual design applications. This model is notable for its modular architecture, allowing efficient scaling and inference.

The Hunyuan-DiT model employs a diffusion transformer architecture, specifically leveraging a Mixture-of-Experts (MoE) design. This architecture partitions the model's parameters into multiple "experts," where only a subset of these experts is activated for each input token during inference. This approach allows the model to achieve a large total parameter count of approximately 389 billion while maintaining a manageable number of active parameters, approximately 52 billion, enhancing computational efficiency. The model incorporates 60 transformer layers with 64 attention heads, utilizing GeLU activation and Layer Normalization. Its design supports flexible image resolutions and uses absolute positional embeddings, integrating Rotary Positional Encoding for enhanced performance. It further utilizes a combination of bilingual CLIP and multilingual T5 encoders for robust text understanding in prompts.

Hunyuan-DiT is engineered for generating high-resolution and visually consistent images, supporting resolutions up to 4096x4096. Its MoE architecture contributes to efficient scaling, making it suitable for deployment in scenarios demanding both high quality and computational prudence. Primary use cases involve creative content generation, visual asset production, and applications requiring advanced text-to-image synthesis capabilities, such as advertising, digital art, and virtual environment design. It also supports multi-turn multimodal dialogue, enabling iterative image refinement based on user interactions.

Technical Specifications

Attention

Attention Structure

Multi-Head Attention

Attention Heads

64

Key-Value Heads

64

Attention Head Dimension

-

Position Embedding

Absolute Position Embedding

RoPE Theta

-

Sliding Window Attention

-

Sliding Window Size

-

Sliding Window Ratio

-

Linear Attention

-

Linear Attention Ratio

-

Normalization

Layer Normalization

Activation Function

GELU

Dimensions

Hidden Dimension Size

4,096

Number of Layers

60

FFN Intermediate Size (Dense)

-

Multi-Token Prediction Heads

-

Tokenizer

Vocabulary Size

-

Mixture of Experts

Total Expert Parameters

52.0B

Number of Experts

32

Active Experts

2

Shared Experts

-

FFN Intermediate Size (per Expert)

-

Dense Layers Before MoE

-

About Hunyuan

Tencent Hunyuan large language models with various capabilities.


Other Hunyuan Models
Hunyuan Large: Specifications and GPU VRAM Requirements