Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
43 commits
Select commit Hold shift + click to select a range
5d32625
refactor: unify AWEX converters and adapters across v1 and v2
sitabulaixizawaluduo Sep 7, 2026
2a4bc2b
refactor(engine): centralize AWEX adapter protocols
sitabulaixizawaluduo Sep 7, 2026
3ef085a
refactor(engine): centralize AWEX metadata exchange helpers
sitabulaixizawaluduo Sep 7, 2026
aa9ac93
refactor(engine): centralize AWEX NCCL group utilities
sitabulaixizawaluduo Sep 7, 2026
3d1f4a0
refactor(engine): centralize AWEX colocate device utilities
sitabulaixizawaluduo Sep 7, 2026
10e5a32
refactor(engine): decouple shared AWEX adapters from v2
sitabulaixizawaluduo Sep 7, 2026
0cc7b3c
refactor(engine): centralize the FSDP AWEX adapter
sitabulaixizawaluduo Sep 7, 2026
fafc130
refactor(engine): use the shared Megatron AWEX adapter directly
sitabulaixizawaluduo Sep 7, 2026
277e49d
refactor(engine): use the shared SGLang AWEX adapter directly
sitabulaixizawaluduo Sep 7, 2026
46b2864
refactor(engine): remove superseded AWEX adapter modules
sitabulaixizawaluduo Sep 7, 2026
9c05057
fix(engine): propagate AWEX metadata request timeouts
sitabulaixizawaluduo Sep 8, 2026
b6b14dc
fix(v2): canonicalize inference metadata for AWEX
sitabulaixizawaluduo Sep 8, 2026
d172ecd
fix(v2): honor actor timeouts for weight updates
sitabulaixizawaluduo Sep 8, 2026
4cd03ad
fix(engine): add peer-serialized AWEX transfers
sitabulaixizawaluduo Sep 8, 2026
f1f1848
fix(engine): serialize separated AWEX weight updates by peer
sitabulaixizawaluduo Sep 8, 2026
c00c2ba
fix(engine): respect isolated GPUs in AWEX colocate launch
sitabulaixizawaluduo Sep 9, 2026
ac57043
refactor(engine): group AWEX adapter protocols
sitabulaixizawaluduo Sep 9, 2026
d77145e
refactor(engine): group AWEX metadata transport
sitabulaixizawaluduo Sep 9, 2026
82b71fa
refactor(engine): group AWEX NCCL transport
sitabulaixizawaluduo Sep 9, 2026
460b6e3
refactor(engine): group AWEX DTE configuration
sitabulaixizawaluduo Sep 9, 2026
4a22eeb
refactor(engine): group AWEX delta detection
sitabulaixizawaluduo Sep 9, 2026
97942b0
refactor(engine): group the FSDP AWEX adapter
sitabulaixizawaluduo Sep 9, 2026
7548828
refactor(engine): group the Megatron AWEX adapter
sitabulaixizawaluduo Sep 9, 2026
b4c36f1
refactor(engine): group the SGLang AWEX adapter
sitabulaixizawaluduo Sep 9, 2026
e339e18
refactor(engine): group AWEX inference plugins
sitabulaixizawaluduo Sep 9, 2026
b20c8db
test(engine): align AWEX peer-transfer mocks and ordering
sitabulaixizawaluduo Sep 9, 2026
5a5aab9
test(engine): migrate DTE overrides to native AWEX conversion
sitabulaixizawaluduo Sep 9, 2026
b07e5b2
fix(trainer): limit Qwen2 RL weight updates to v1 XCCL or disk
sitabulaixizawaluduo Sep 9, 2026
b3b8667
docs: clarify Qwen2 RL weight update support
sitabulaixizawaluduo Sep 9, 2026
1612ce2
test(trainer): initialize MOPD plan in evaluation fixture
sitabulaixizawaluduo Sep 10, 2026
a97375a
test(infra): align RTensor test storage and fetch backends
sitabulaixizawaluduo Sep 10, 2026
406212b
revert(engine): restore direct AWEX batch transfers
sitabulaixizawaluduo Sep 10, 2026
deaca2c
test(engine): remove unused AWEX peer-transfer stubs
sitabulaixizawaluduo Sep 10, 2026
9511e1a
revert(engine): remove peer-serialized AWEX transfer helper
sitabulaixizawaluduo Sep 10, 2026
7c01d0f
fix(trainer): allow Qwen2 disk weight updates in v2
sitabulaixizawaluduo Sep 10, 2026
32b848a
docs: clarify Qwen2 disk weight updates across versions
sitabulaixizawaluduo Sep 10, 2026
84493e0
fix(engine): align Megatron AWEX sends to receiver dtype
sitabulaixizawaluduo Sep 16, 2026
599718c
fix(engine): align FSDP AWEX sends to receiver dtype
sitabulaixizawaluduo Sep 16, 2026
b3e6b67
Merge branch 'main' into feature/v2-awex-native-converters
sitabulaixizawaluduo Sep 18, 2026
48469fc
chore(engine): merge main and resolve AWEX conflicts
sitabulaixizawaluduo Oct 13, 2026
cdb32e1
chore(engine): merge main and reconcile AWEX adapters
sitabulaixizawaluduo Oct 16, 2026
e52ae6f
fix(trainer): validate Qwen2 against effective v2 transport
sitabulaixizawaluduo Oct 16, 2026
fff156e
fix(trainer): scope Qwen2 AWEX guard to Megatron
sitabulaixizawaluduo Oct 16, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -245,6 +245,12 @@ All RL algorithms support both asynchronous and synchronous versions by setting
| **Gemma 3** | ❌ | ✅ | ❌ | Vision-language model |
| **Other Hugging Face LLM** | ❌ | ✅ | ❌ | Compatibility depending on the version of `transformers` |

Qwen2 and Qwen2.5 **text models** support RL weight updates with
`actor.weight_update_mode=disk` in both v1 and v2. XCCL weight updates require
`actor._version=v1`, `rollout._version=v1`, and `actor.weight_update_mode=xccl`. AWEX
weight updates are not supported for these models. This restriction does not apply to
Qwen2.5-VL.

Check the [AI Coding Assistant Guide](docs/en/reference/ai_assisted_dev.md) and
[Archon Reference](docs/en/tutorial/archon.md) for how to integrate new models into
AReaL.
Expand Down
2 changes: 1 addition & 1 deletion areal/engine/awex/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# SPDX-License-Identifier: Apache-2.0

"""AWEX colocated weight-transfer integration (writer, reader, SGLang plugin)."""
"""Shared AWEX adapters and colocated weight-transfer integration."""
3 changes: 3 additions & 0 deletions areal/engine/awex/adapters/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# SPDX-License-Identifier: Apache-2.0

"""Shared AWEX training and inference adapters."""
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
# SPDX-License-Identifier: Apache-2.0
"""AWEX training adapter for FSDP engines."""

from __future__ import annotations

# pyright: reportMissingImports=false
Expand All @@ -18,19 +20,20 @@
from torch.distributed.tensor import DTensor
from torch.distributed.tensor.placement_types import Shard

from areal.engine.core.model import is_qwen_vl_model
from areal.utils import logging
from areal.v2.weight_update.awex import (
from areal.engine.awex.adapters.training_adapter import (
AwexTrainingAdapter,
)
from areal.engine.awex.transport.dtype import align_send_ops_to_recv_dtype
from areal.engine.awex.transport.metadata import (
awex_wu_use_group,
fetch_kv_metadata,
)
from areal.v2.weight_update.nccl_group import (
from areal.engine.awex.transport.nccl_group import (
init_weights_update_group,
setup_batch_isend_irecv,
)
from areal.v2.weight_update.training_adapter import (
AwexTrainingAdapter,
)
from areal.engine.core.model import is_qwen_vl_model
from areal.utils import logging

if TYPE_CHECKING:
from areal.engine.fsdp_engine import FSDPEngine
Expand Down Expand Up @@ -61,6 +64,7 @@ def parallelism_strategy(self) -> dict:
"dp_size": self._engine.data_parallel_world_size,
"ep_size": 1,
"dp_replicated": False,
"parameter_layout": "hf",
}

@property
Expand Down Expand Up @@ -138,10 +142,11 @@ def init_weight_update_group(
infer_world_size: int,
train_world_size: int,
num_engines: int,
timeout_s: float = 300.0,
) -> None:
self._transfer_rank = transfer_rank

infer_meta, train_meta = fetch_kv_metadata(kv_store_url, pair_name)
infer_meta, train_meta = fetch_kv_metadata(kv_store_url, pair_name, timeout_s)

builder = TransferPlanBuilder(
infer_world_size=infer_world_size,
Expand Down Expand Up @@ -198,6 +203,7 @@ def execute_weight_update(self, version: int) -> None:
self._weights_update_group,
copy_rank=self._transfer_rank,
)
align_send_ops_to_recv_dtype(send_ops, self._transfer_plan)
batch_send_recv(
send_ops=send_ops,
recv_ops=[],
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
# SPDX-License-Identifier: Apache-2.0
"""Shared contract for AWEX inference adapters."""

from __future__ import annotations

from typing import Protocol, runtime_checkable
Expand Down Expand Up @@ -42,6 +44,7 @@ def init_weight_update_group(
infer_world_size: int,
train_world_size: int,
num_engines: int,
timeout_s: float = 300.0,
) -> None:
"""Pull peer meta from KV store, build local recv plan, join NCCL group."""
...
Expand Down
Loading
Loading