Skip to content

fix(loader): gate auto decoder bypass on native floatx - #3713

Merged
Qubitium merged 1 commit into
mainfrom
fix/auto-decoder-quantized-source
Nov 9, 2026
Merged

Qubitium merged 1 commit into
mainfrom
fix/auto-decoder-quantized-source

Conversation

@Qubitium

@Qubitium Qubitium commented Nov 9, 2026

Copy link
Copy Markdown
Collaborator

Summary

Restrict the AutoModuleDecoder source-loading bypass to checkpoints whose source format is native floatx. GPTQ, AWQ, EXL3, and other already-quantized checkpoints now route through from_quantized() even when the requested target config contains AutoModuleDecoderConfig.

The same gate is applied to both GPTQModel.load() and GPTQModel.from_pretrained().

Before / after

Entry point Before After
GPTQModel.load() AutoModuleDecoderConfig bypassed the quantized-source branch regardless of source format bypass requires native_floatx_source_format(...) is not None
GPTQModel.from_pretrained() same unconditional bypass same native-floatx gate

This is a localized loader-selection bug fix, so no separate control-flow reference page is required.

Validation

TMPDIR=/dev/shm PYTHONDONTWRITEBYTECODE=1 /root/venv/bin/python -m pytest tests/test_local_model_paths.py -q -p no:cacheprovider
27 passed

ruff check gptqmodel/models/auto.py tests/test_local_model_paths.py
All checks passed

New tests cover native FP8 continuation plus GPTQ sources routed to from_quantized() through both entry points.

@Qubitium
Qubitium merged commit a4dc9e3 into main Nov 9, 2026
4 of 5 checks passed
@Qubitium
Qubitium deleted the fix/auto-decoder-quantized-source branch November 9, 2026 12: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