(bugfix): Clarify CausalLM decode-only flag handling and fix PL=1 specialization naming#1006
Merged
Merged
Conversation
…v flags Signed-off-by: vbaddi <vbaddi@qti.qualcomm.com>
fd748d0 to
9aa8cf2
Compare
quic-mohmeh
pushed a commit
to quic-mohmeh/efficient-transformers
that referenced
this pull request
May 25, 2026
…cialization naming (quic#1006) This PR verifies the reported Llama decode-only compile behaviour **Findings**: - `decode_only=True` is currently not supported by `QEFFAutoModelForCausalLM.export()`. - `retain_full_kv=True` is only applicable to specialized disaggregated-serving models such as GPT-OSS/Kimi, and has no effect for Llama. - `prefill_seq_len=1` with prefill_only=False was incorrectly tagged as Prefill in the generated specialization metadata. **Changes**: - Raise a clear `NotImplementedError `when `decode_only=True` is passed to CausalLM export. - Warn and ignore `retain_full_kv=True` for non-specialized models such as Llama. - Tag `prefill_seq_len=1 and prefill_only=False` specializations as Decode. - Add quickcheck unit coverage for unsupported decode_only, ignored Llama retain_full_kv, and PL=1 decode specialization naming. **Validation**: - Verified PL=1 now emits "name": "Decode" in specialization output. - Added unit test and Ran focused quickcheck tests successfully: - PYENV_VERSION=qeff pytest -q tests/unit_test/models/test_model_quickcheck.py::TestCausalLMFlagDiagnostics cc: @quic-hemagnih @quic-rishinr Signed-off-by: vbaddi <vbaddi@qti.qualcomm.com> Signed-off-by: Mohit Mehta <mohmeh@qti.qualcomm.com>
smedhe
pushed a commit
to smedhe/QEff_Sharvari
that referenced
this pull request
May 25, 2026
…cialization naming (quic#1006) This PR verifies the reported Llama decode-only compile behaviour **Findings**: - `decode_only=True` is currently not supported by `QEFFAutoModelForCausalLM.export()`. - `retain_full_kv=True` is only applicable to specialized disaggregated-serving models such as GPT-OSS/Kimi, and has no effect for Llama. - `prefill_seq_len=1` with prefill_only=False was incorrectly tagged as Prefill in the generated specialization metadata. **Changes**: - Raise a clear `NotImplementedError `when `decode_only=True` is passed to CausalLM export. - Warn and ignore `retain_full_kv=True` for non-specialized models such as Llama. - Tag `prefill_seq_len=1 and prefill_only=False` specializations as Decode. - Add quickcheck unit coverage for unsupported decode_only, ignored Llama retain_full_kv, and PL=1 decode specialization naming. **Validation**: - Verified PL=1 now emits "name": "Decode" in specialization output. - Added unit test and Ran focused quickcheck tests successfully: - PYENV_VERSION=qeff pytest -q tests/unit_test/models/test_model_quickcheck.py::TestCausalLMFlagDiagnostics cc: @quic-hemagnih @quic-rishinr Signed-off-by: vbaddi <vbaddi@qti.qualcomm.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR verifies the reported Llama decode-only compile behaviour
Findings:
decode_only=Trueis currently not supported byQEFFAutoModelForCausalLM.export().retain_full_kv=Trueis only applicable to specialized disaggregated-serving models such as GPT-OSS/Kimi, and has noeffect for Llama.
prefill_seq_len=1with prefill_only=False was incorrectly tagged as Prefill in the generated specialization metadata.Changes:
NotImplementedErrorwhendecode_only=Trueis passed to CausalLM export.retain_full_kv=Truefor non-specialized models such as Llama.prefill_seq_len=1 and prefill_only=Falsespecializations as Decode.naming.
Validation:
cc: @quic-hemagnih @quic-rishinr