Skip to content

Bringing Speech, Multi-Switch, Shadow-Residual, SWITCH kernels and ChatML support to Granite Switch - #119

Merged
yairallouche merged 14 commits into
mainfrom
sync/staging-2026-09
Sep 8, 2026
Merged

Bringing Speech, Multi-Switch, Shadow-Residual, SWITCH kernels and ChatML support to Granite Switch#119
yairallouche merged 14 commits into
mainfrom
sync/staging-2026-09

Conversation

@antonpibm

Copy link
Copy Markdown
Collaborator

No description provided.

@codecov-commenter

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 44.86692% with 290 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
src/granite_switch/kernels/switch_lora_kernel.py 9.85% 256 Missing ⚠️
src/granite_switch/token_exchange.py 12.90% 27 Missing ⚠️
src/granite_switch/config.py 90.47% 4 Missing ⚠️
src/granite_switch/conversation.py 98.18% 3 Missing ⚠️

📢 Thoughts on this report? Let us know!

@yairallouche
yairallouche merged commit 24aa420 into main Sep 8, 2026
3 of 4 checks passed
@antonpibm
antonpibm deleted the sync/staging-2026-09 branch September 8, 2026 08:55
aviv1ron1 added a commit that referenced this pull request Sep 9, 2026
Absorbs feature/moe-audio-support so it does not need a PR of its own: that
branch carried no functional code, only documentation plus the tests that back
it. Taken from staging/feature/moe-audio-support @ 8bf0bb3.

What came across:

  * docs/AUDIO.md -- the audio cascade over a pure sparse MoE base. Hand-merged,
    not overwritten: this file had already diverged here (63+/25- from the
    TurboCTC edits, which touch the same sections). Verified afterwards that both
    sides survive -- the TurboCTC default, the transformers>=5.16 requirement and
    the 120s chunker window on one side, the granitemoe material on the other.
  * tests/composer/test_audio_marker_output_row.py -- the marker/reserved-row copy
    is now parametrized over MLP topology as well as embedding tying, taking it
    from 2 cases to 4 (untied/tied x dense/sparse-MoE). The fixup only ever
    touches embedding rows, so both topologies must behave identically; the sparse
    arm is what would notice if a shared-MLP-shaped assumption crept into the
    model construction it runs against.
  * tests/composer/test_granitemoe_audio_compose.py -- new, 9 tests over 4
    classes: audio does not resurrect the shared MLP, does not widen the adapter
    surface and leaves no zero-width parameter; the control LUT goes stale on the
    marker and refresh fixes it idempotently and passes the validator; the marker
    output row; and survival across save/load.

Deliberately NOT taken: a 5-line comment block in
src/granite_switch/composer/tokenizer_setup.py noting that the <|unused_N|>
convention also holds on granitemoe bases. True, but prose, and keeping src/
out of this commit makes the "no functional change" claim checkable rather than
asserted -- `git show --stat` shows no src/ path at all.

Verified: the two test files give 32 passed here; ruff check and format clean
over 211 files.

One thing a reviewer should not misread. The composer tier on this base reports
pre-existing failures that predate this commit and are unrelated to it:
TestGraniteMoeSR fails 6 of 8 even in isolation, in 0.37s, with
"ValueError: not enough values to unpack (expected 5, got 3)". Public main is 15
commits behind staging and is missing #119, which changed composer return
signatures and updated test_granitemoe_compose_e2e.py to match; the two are out
of step here. It has gone unnoticed because the public repo's automatic CI runs
only tests/unit/, so tests/composer/ is unchecked on every PR. #119 is expected
to reach public main shortly, which resolves it. The test file imported above is
based on #116, before that refactor, so it matches the signatures this base has.

Signed-off-by: aviv ron <rona@il.ibm.com>
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.

7 participants