support rl feature : weight checker (#51350)

Signed-off-by: shiyuan680 <yangcheng104@huawei.com>
Signed-off-by: Ronald1995 <ronaldautomobile@163.com>
Signed-off-by: aoshen02 <aoshen02@users.noreply.github.com>
Co-authored-by: shiyuan680 <yangcheng104@huawei.com>
Co-authored-by: Ronald1995 <ronaldautomobile@163.com>
Co-authored-by: DeepSeek Harness <noreply@deepseek.com>
Co-authored-by: aoshen02 <aoshen02@users.noreply.github.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: aoshen02 <aoshen@inferact.ai>
This commit is contained in:
shiyuan680
2026-09-30 03:13:43 +00:00
committed by GitHub
co-authored by shiyuan680 Ronald1995 DeepSeek Harness aoshen02 Claude Opus 5.5 aoshen02
parent a8e069f81b
commit 42d9f8ccdb
15 changed files with 611 additions and 2 deletions
@@ -222,6 +222,24 @@ def _make_dplb_client(num_engines: int = 3, client_count: int = 1) -> DPLBAsyncM
return client
def test_dplb_weight_checksums_gather_every_engine():
"""call_utility_async on a DPLB client would keep only the first engine."""
client = _make_dplb_client(num_engines=2)
async def call_utility(method, *args, engine):
assert (method, args) == ("compute_weight_checksums", ())
return [{f"dp{engine[0]}:tp{tp}:w": "x"} for tp in (0, 1)]
client._call_utility_async = call_utility
workers = asyncio.run(client.compute_weight_checksums_async())
assert [key for worker in workers for key in worker] == [
"dp0:tp0:w",
"dp0:tp1:w",
"dp1:tp0:w",
"dp1:tp1:w",
]
def test_dplb_late_interaction_sticky_routing():
client = _make_dplb_client()