8000 Remove the role_aware flag and name the baseline FastAFD's DeepEP M2N by Etelis · Pull Request #17 · afdEP/afdEP-comm · GitHub
[go: up one dir, main page]

Skip to content

Remove the role_aware flag and name the baseline FastAFD's DeepEP M2N - #17

Merged
Etelis merged 3 commits into
mainfrom
always-afd-transport
Oct 25, 2026
Merged

Etelis merged 3 commits into
mainfrom
always-afd-transport

Conversation

@Etelis
@Etelis Etelis commented Oct 25, 2026
Copy link
Copy Markdown
Member

Stacked on #16.

afdEP-comm is the AFD transport, so it no longer has a flag that turns the AFD specialization off. The docs now say plainly what every result is measured against, FastAFD's DeepEP M2N, and link to it, instead of calling it "Masked DeepEP" and describing it as role_aware=False.

API

  • Config.role_aware is removed. Buffer always runs afdEP-comm's transport.
  • In the low-level afdep.deepep.ElasticBuffer, role_aware is removed:
    • with ffn_ranks=M it runs afdEP-comm's transport, which is what Buffer passes;
    • without ffn_ranks it runs DeepEP V2 as upstream ships it, over a symmetric group.
  • This breaks callers that pass role_aware. Plugin PR Publish a release when a merge sets a new version #35 (afd-plugin) does: it needs to drop its role_aware config field and call ElasticBuffer(**kwargs, ffn_ranks=self.ffn_size).

Baseline

  • New benchmarks/fastafd.py holds the baseline: FastAFDConfig and FastAFDBuffer. They put afdEP-comm's role API over the unspecialized vendored kernels, the way FastAFD's DeepEPM2NAdapter runs AFD: a symmetric group, dummy expert slots on Attention ranks, full receive bounds on every rank.
  • benchmarks.comm arms select it with "_baseline": "fastafd". benchmarks.screen's default arms are now fastafd and afdep.
  • The GPU suite's --generic is now --baseline fastafd.

Docs

  • README "What afdEP-comm changes" says what we compare against, with links to FastAFD, a permalink to DeepEPM2NAdapter at the snapshot we vendor (3c716194), and the AFD plugin. It says what afdEP-comm removes and where the baseline lives in the benchmarks.
  • "Masked DeepEP" is now "FastAFD's DeepEP M2N" in the README, api.md, sparse-hybrid.md, the templates, the figure data and every figure. The design doc spells the name out once and uses "FastAFD M2N" in its tables. "Role path" and "role-aware" wording is gone.
  • validation-masked-equivalence.json is renamed to validation-fastafd-equivalence.json. Its description no longer claims the plugin buffer ran with "specialize_roles off", an option that buffer doesn't have. A note maps the old names, and the stored driver script is left verbatim.
  • Older validation records keep the names they were written with; the design doc's header maps them.

Validation
The native tree is unchanged at 21298d5b. Checked on six 4 × H200 pods (kermit, InfiniBand, GIN):

  • GPU suite:

    • afdEP-comm passes across nodes in FP8 at 4F:20A, capacity 8, and in BF16 at 8F:16A, capacity 64, on all six pods; and in one NVLink domain (2A2F, BF16, capacity 64).
    • --baseline fastafd passes the same three configurations.
    • The baseline runs give Attention ranks full receive bounds and zero-output arenas (1,280 and 1,536 rows); afdEP-comm gives them none.
  • Baseline equivalence: paired screen at 4F:20A, FP8, hidden 2048, 2 repeats. The new fastafd arm matches the old role_aware=False arm within −0.33% to +0.17% at 1 to 512 tokens. Recorded in validation-fastafd-equivalence.json.

    T=1 8 32 128 512
    old role_aware=False, µs 185.5 195.5 211.6 277.0 635.7
    fastafd baseline, µs 185.4 194.9 211.7 277.5 635.8
    afdEP-comm, µs 70.4 83.1 97.8 224.9 605.2
  • Checks: 48 unit tests, Ruff check and format, and the link check all pass.

Config.role_aware let a caller turn the AFD specialization off, which
made the library look optional about the one thing it is for. Config
no longer has it, and Buffer always opens afdEP-comm's transport. The
low-level ElasticBuffer keeps one meaning: with ffn_ranks it is
afdEP-comm, without it DeepEP V2 as upstream ships it, over a
symmetric group.

The baseline every result is measured against moves out of the library
into benchmarks/fastafd.py. FastAFDConfig and FastAFDBuffer run the
role API over the unspecialized vendored kernels the way FastAFD's
DeepEPM2NAdapter runs AFD: a symmetric group, dummy expert slots on
Attention ranks, full receive bounds on every rank. Buffer gains
_open_transport and _source_output_rows so the baseline overrides
only those. Screens select it with "_baseline": "fastafd" (default
arms fastafd and afdep), and the GPU suite's --generic becomes
--baseline fastafd.

On six 4 x H200 pods the baseline arm times within -0.33% to +0.17% of
the old role_aware=False arm, and both pass the GPU suite across nodes
and in one NVLink domain. The native tree is unchanged (21298d5b).
The docs called the baseline "Masked DeepEP" and defined it as
role_aware=False, a name of our own for someone else's code. It is
FastAFD's DeepEP M2N: the README now says so, links FastAFD, its
DeepEPM2NAdapter at the snapshot we vendor and the AFD plugin's
deepep_m2n connector, and says what afdEP-comm removes. The name
changes in the README, api.md, sparse-hybrid.md, the design doc (which
abbreviates it to FastAFD M2N in tables), the issue and PR templates,
the figure data and every figure; "role path" wording goes with it.

validation-masked-equivalence.json becomes
validation-fastafd-equivalence.json. Its description no longer says the
plugin buffer ran with "specialize_roles off", an option that buffer
does not have, and it gains the flag-removal equivalence screen. Older
records keep the names they were written with; the design doc's header
maps them.
@Etelis
Etelis requested a review from almogtavor as a code owner October 25, 2026 14:12
Base automatically changed from sparse-hybrid-default to main October 25, 2026 14:23
@Etelis
Etelis merged commit 2b74d57 into main Oct 25, 2026
4 checks passed
@Etelis
Etelis deleted the always-afd-transport < 7CC1 /span> branch October 25, 2026 14:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

0