DeepInfra raises $107M Series B to scale the inference cloud — read the announcement

tencent/

Hy4-flash

$0.07

in

$0.281

out

$0.003

cached

/ 1M tokens

Hy4 flash is the most cost-effective model from the Tencent Hy Team, with 220B total parameters (including 64B Engram n-gram embedding parameters), 12B activated per token, text and image input, and a 1M-token context window. It combines hybrid sparse and sliding-window attention, LatentMoE and Engram, and scores slightly above Hy4 preview on everyday productivity tasks at a fraction of the cost.

Public
Zero retention
fp4
1,048,576
JSON
Function
Multimodal
ProjectLicense
tencent/Hy4-flash cover image
api
tencent/Hy4-flash cover image
Hy4 flash

Ask me anything

0.00s

You need to log in to use this model

Log in

Settings

Model Information

Hy4 flash

Model Introduction

Hy4 flash is the most cost-effective Hy model to date, featuring 220B total parameters (including 64B Engram parameters) with just 12B active parameters per token. It natively accepts text and image inputs, generates text, and supports a context window of up to 1M tokens.

Its 42-layer language backbone consists of one dense feed-forward layer and 41 MoE layers, with identity Hyper-Connections (iHC) supporting inter-layer information flow. A vision encoder (adapted from SigLIP2-So400m-Patch16-Res512) is connected to the backbone through an MLP projector. In addition to the backbone, a built-in 5-layer drafter, DFly2 (0.85B parameters), reuses the target model's KV cache and sparse indices to support long-context speculative decoding at a low, constant cost.

Compared with Hy4, Hy4 flash introduces three notable architectural changes:

  1. Hybrid attention. Sparse attention (IndexPool) and sliding-window attention (SWA) are interleaved at a 1:3 ratio.
  2. LatentMoE. Routed experts operate in a lower-dimensional latent space. Each token activates 16 of 512 routed experts, alongside one shared expert.
  3. N-gram embedding (Engram). The backbone is augmented with learned bigram and trigram representations, retrieved via multi-head hash lookups.

Model Specifications

PropertyValue
ArchitectureMixture-of-Experts (MoE)
Total Parameters (excluding Engram, ViT and DFly2)155.5B
Engram Parameters63.5B
Activated Parameters per TokenText 11.3B + Vision 0.43B
ViT Parameters0.43B
DFly2 Drafter Parameters0.85B
Layers42 (1 dense, 41 MoE)
Hidden Size3072
AttentionSparse attention (IndexPool) and sliding-window attention interleaved 1:3
Routed Experts512 (LatentMoE)
Activated Routed Experts per Token16
Shared Experts1
Context Length1M

Practicality and Cost Efficiency

Across training, evaluation, and inference, Hy4 flash was aggressively optimized for cost efficiency while preserving intelligence:

  • Pre-training: Hybrid attention, LatentMoE, and Engram reduce the KV cache to just 1/24 of Hy3 and 1/6 of Hy4.
  • Post-training: Self-distillation from Hy4 establishes strong general intelligence, while reinforcement learning cuts average end-to-end output tokens by 50%.
  • Evaluation: WorkIndex, an internal benchmark grounded in everyday productivity tasks, is paired with human evaluation, focusing on deliverable quality, output length, and turnaround time.

Hy4 flash delivers overall task performance slightly above Hy4 preview at a much lower cost per task. On WorkIndex it scores 42.1, compared with 39.7 for Hy4 preview and 51.4 for Hy4, while its average cost per task is just 1/13 of Hy4 preview and 1/20 of Hy4.

Hy4 flash is recommended for most everyday productivity tasks, including deep search, document processing, slide creation, simple frontend demos, and computer use. For complex tasks such as long-horizon software engineering, Hy4 offers a higher intelligence ceiling.

In a blind evaluation with 85 users across 259 tasks, Hy4 flash reached user satisfaction close to Claude Haiku 5.5 (2.79/4 vs 2.81/4), with the lowest cost per task and the shortest median end-to-end completion time among the evaluated models.

Usage Notes

  • Reasoning mode: Hy4 flash thinks by default. Set reasoning_effort to none for direct responses without reasoning; any other value (low, medium, high, xhigh) keeps reasoning on.
  • Recommended sampling: temperature=0.9, top_p=1.0.
  • Images: one image per request.

Benchmark Appendix

License

Hy4 flash is released under the Tencent Hy License 1.0, derived from the Apache License 2.0 with additional commercial terms for large Model-as-a-Service businesses. See LICENSE for details.