renamed UNSLOTH_FLEX_ATTENTION to UNSLOTH_ENABLE_FLEX_ATTENTION

This commit is contained in:
Roland Tannous 2026-02-18 09:21:53 +00:00
commit d57b2742ab

View file

@ -34,7 +34,7 @@ async def lifespan(app: FastAPI):
props = torch.cuda.get_device_properties(0)
sm_version = props.major * 10 + props.minor
if sm_version >= 120:
os.environ["UNSLOTH_FLEX_ATTENTION"] = "0"
os.environ["UNSLOTH_ENABLE_FLEX_ATTENTION"] = "0"
import logging
logging.getLogger(__name__).info(
f"GPU sm_{sm_version} detected — setting UNSLOTH_FLEX_ATTENTION=0"