Tencent Opens Hy4 Flash Weights With 1M-Token Context at 20x Lower Cost

Tencent has released the weights for Hy4 flash, a 220B-parameter multimodal MoE model with 12B active parameters and a 1M-token context, plus FP8 and base versions.

·
·
·
Tencent Opens Hy4 Flash Weights With 1M-Token Context at 20x Lower Cost
  • Tencent released Hy4 flash as open weights, in instruct, FP8 and base versions.
  • The model has about 220B total parameters, 12B active per token, a 1M-token context, and text-plus-image input.
  • Hybrid attention, LatentMoE and Engram n-gram lookup tables cut the KV cache to 1/6 of Hy4's.
  • The built-in DFly2 draft model reuses the main model's KV cache, and decoding passes 150 tokens/s.
  • Tencent reports Haiku 5.5-level user satisfaction at 1/20 of Hy4's task cost, but it ranks 33rd of 39 on Vals.
  • The license adds Model-as-a-Service limits above $50M revenue or 100M monthly users.

Tencent has released open weights for Hy4 Flash after initially offering the model through a hosted API. The release includes an instruction-tuned checkpoint, an FP8 version using 8-bit floating-point weights, and the pretrained base model. All three are available on Hugging Face, ModelScope, and GitCode, while serving and fine-tuning code lives in the GitHub repository.

Developers can now inspect, fine-tune, and self-host the multimodal model under Tencent’s license. Hy4 Flash accepts text and images, supports a 1-million-token context window, and activates roughly 12 billion parameters per token despite containing about 220 billion parameters. Tencent positions it for office productivity, research, document processing, computer use, and agent workflows. The larger Hy4 remains its recommended model for demanding coding and long-horizon software engineering.

220B stored, about 12B active

Published parameter totals vary slightly. Tencent’s launch post and related coverage use 224 billion, while the model card lists components totaling about 220.3 billion. The card provides the more useful breakdown because most of those parameters do not participate in every token calculation.

Hy4 Flash parameter breakdown
Component Parameters Runtime role
Core model 155.5B About 11.3B text parameters activate per token
Engram tables 63.5B Retrieved through hash lookups
Vision encoder 0.43B Encodes image inputs
DFly2 draft model 0.85B Proposes tokens during speculative decoding

Tencent attributes the low active count and reduced serving cost to three architectural choices:

  • Hybrid attention. Three out of every four layers use sliding-window attention, allowing each token to inspect the previous 512 tokens. Every fourth layer uses sparse attention, whose indexer selects the 2,048 most relevant positions from the full context.
  • LatentMoE. Mixture-of-experts layers process tokens in a compressed representation. Each token activates 16 of 512 routed experts alongside one shared expert.
  • Engram. Learned representations of two-token and three-token sequences are retrieved through multi-head hash lookups. These tables require storage and memory bandwidth but add little arithmetic compared with conventional model layers.

The architecture reduces the KV cache to one twenty-fourth of Hy3’s size and one sixth of Hy4’s, according to Tencent. A KV cache stores attention keys and values for earlier tokens, so its memory footprint grows with context length. At 1 million tokens, that cache can determine whether a deployment fits available hardware.

DFly2 shares the main model’s cache

Hy4 Flash includes a five-layer draft model called DFly2 for speculative decoding. The smaller model proposes several tokens, then the main model verifies them in one pass. DFly2 reuses the main model’s KV cache and the positions selected by its sparse-attention indexer, avoiding a second long-context cache.

  1. Bounded attention: Each draft token attends to no more than roughly 2,000 keys, regardless of the full context length.
  2. No separate draft cache: The drafter reuses memory already maintained by the main model.
  3. Split-serving support: The drafter skips prefill, so transferring a request from prefill workers to decode workers adds one hidden state.

Tencent reports decoding speeds above 150 tokens per second when DFly2 is combined with megakernels and 4-bit quantization. Actual throughput will depend on hardware, batch size, context length, draft-token acceptance rate, and serving configuration, so the figure should not be treated as a universal deployment target.

Shorter outputs target lower task costs

Post-training combined self-distillation from the larger Hy4 with reinforcement learning designed to shorten responses. Tencent reports that the reinforcement-learning stage reduced average end-to-end output length by 50%. At a fixed success rate and output-token price, that reduction would lower generation charges and completion time.

Tencent evaluates office and agent performance with WorkIndex, an internal benchmark containing eight task sets across slide creation and editing, document editing, spreadsheet repair, audio and video processing, and visual understanding. Its published results show the capability and cost trade-off between Flash and the flagship model.

Tencent-reported benchmark and cost results
Metric Hy4 Flash Hy4 flagship
WorkIndex score 42.1 51.4
Relative cost per task 1× About 20×
DeepSWE software engineering 64.6 74.9
OSWorld 2.1 computer use 68.1 78.9

Hy4 Flash also scored 42.1 on WorkIndex against 39.7 for Hy4 Preview while using one thirteenth of the cost per task, according to Tencent. In a blind internal test involving 85 users and 259 tasks, Flash scored 2.79 out of 4, recorded a median completion time of 6.7 minutes, and cost RMB 0.26 per task.

Benchmarks show a clear capability gap

Independent results place Hy4 Flash well below leading models on broader evaluations. At the time of testing, it ranked 33rd among 39 models on Vals AI’s Vals Index with a score of 50.78%. Tencent’s own figures show the flagship ahead by 10.3 points on DeepSWE and 10.8 points on OSWorld 2.1.

Tencent’s deployment guidance matches those results. It recommends Flash for deep search, document processing, slide creation, simple frontend prototypes, and routine computer use. Long-running software engineering tasks remain assigned to the flagship Hy4.

  • The base model encountered substantial synthetic instruction data during mid-training. Tencent says this can cause formatting failures in few-shot evaluations and may affect benchmark scores.
  • WorkIndex, cost-per-task figures, and user-satisfaction results come from Tencent’s internal benchmarks and WorkBuddy users.
  • Dynamic leaderboards can change as evaluators add models, revise prompts, or update scoring methods.

Self-hosting targets eight-way parallelism

Official vLLM and SGLang recipes serve the FP8 checkpoint with eight-way tensor parallelism and DFly2 speculation enabled. Launch coverage reported that Tencent designed the model to fit across two DGX Spark systems. An unofficial community GGUF build is also available for experimentation, though it is outside Tencent’s documented serving path.

Mainline support has not yet landed in the transformers package, so the current setup requires installation from a pending pull request. Published interfaces support text and image inputs; video input is absent from both the model card and hosted API documentation.

A running vLLM or SGLang server exposes an OpenAI-compatible endpoint, allowing existing clients to call the model with minimal changes:

python
from openai import OpenAI

client = OpenAI(
    base_url="http://127.0.0.1:8000/v1",
    api_key="EMPTY",
)

resp = client.chat.completions.create(
    model="hy4-flash",
    messages=[
        {
            "role": "user",
            "content": "Summarize this spreadsheet's errors.",
        }
    ],
    temperature=0.9,
    top_p=1.0,
    extra_body={
        "chat_template_kwargs": {
            "reasoning_effort": "no_think"
        }
    },
)

print(resp.choices[0].message.content)

Tencent recommends temperature=0.9 and top_p=1.0. The default reasoning_effort value of high enables reasoning, while no_think requests a direct answer. The repository also includes a full fine-tuning pipeline.

Hosted API pricing at publication was $0.070 per million input tokens, $0.281 per million output tokens, and $0.003 per million cached input tokens. Those rates avoid self-hosting infrastructure costs but remain subject to Tencent’s pricing changes.

The license restricts large MaaS providers

The license text combines Apache 2.0 terms with an additional Tencent section. It permits fine-tuning, quantization, redistribution, and commercial use within products, subject to the added conditions.

General-purpose Model-as-a-Service offerings face an extra restriction. Operators providing inference or fine-tuning to third parties need a separate written license from Tencent when worldwide revenue exceeds $50 million during any 12-month period or the product exceeds 100 million monthly active users.

Internal deployments and products that confine the model to specific features are exempt from that MaaS requirement. Terms attached to derivatives cannot override the restriction. A company may therefore run a 1-million-token assistant for its own staff, while a large operator selling general-purpose API access must secure Tencent’s approval.

Flash fills the lower-cost Hy4 tier

Hy4 Flash follows Hy4 Preview and the hosted flagship, giving Tencent a model aimed at high-volume productivity and agent tasks where output length, latency, and cost per completed job matter. Its combination of downloadable weights, integrated speculative decoding, and long-context memory optimizations gives developers a distinct serving profile from the larger model.

The architecture also shows why total parameter count provides limited guidance for deployment planning. Hy4 Flash stores roughly 220 billion parameters, including 63.5 billion Engram lookup parameters, while activating about 11.3 billion text parameters for each token. Storage capacity, memory bandwidth, KV-cache size, active computation, and output length all contribute to the final serving cost.

Agent evaluations benefit from measuring cost per successful completed task, including input tokens, output tokens, infrastructure, latency, and failure rates. Tencent’s internal results suggest Flash can trade some coding and computer-use accuracy for substantially lower task costs. Independent production testing will determine whether that trade holds across workloads outside Tencent’s benchmarks. Tencent says open weights for the flagship Hy4 will follow.

Trending
  • No trending articles

Comments

avatar

Next Reads