{"record":{"id":"09b9b51faa0ac3f7","repo":"sgl-project/sglang","slug":"inklingbatchdensemlpwithlora-is-ineligible-joine","errorCode":null,"errorMessage":"InklingBatchDenseMLPWithLoRA is ineligible: {joined problems}","messagePattern":"InklingBatchDenseMLPWithLoRA is ineligible: (.+?)","errorType":"validation","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"python/sglang/srt/models/inkling_common/lora.py","lineNumber":24,"sourceCode":"from sglang.srt.models.inkling_common.dense_mlp import InklingBatchDenseMLP\n\n\nclass InklingBatchDenseMLPWithLoRA(InklingBatchDenseMLP):\n    \"\"\"LoRA layer for Inkling's dense shared-expert sink.\"\"\"\n\n    is_shared_fused_moe = True\n\n    def initialize_lora(self, lora_backend: BaseLoRABackend) -> None:\n        problems = []\n        if (\n            lora_backend.max_loras_per_batch > 1\n            and getattr(lora_backend, \"name\", None) != \"triton\"\n        ):\n            problems.append(\"multi-slot dense LoRA requires the Triton backend\")\n        if not self._linearized_bf16_enabled:\n            problems.append(\"the shared sink does not use linearized BF16 weights\")\n        if problems:\n            raise ValueError(\n                \"InklingBatchDenseMLPWithLoRA is ineligible: \" + \"; \".join(problems)\n            )\n\n        self.lora_backend = lora_backend\n        self.set_lora = False\n        self.experts_shared_outer_loras = False\n        self.register_buffer(\"_w1_delta\", None, persistent=False)\n        self.register_buffer(\"_a_cat\", None, persistent=False)\n        self._lora_routing_cache = {}\n        lora_backend.is_moe_lora = True\n\n    def set_lora_info(\n        self,\n        gate_up_lora_a_weights: torch.Tensor,\n        gate_up_lora_b_weights: torch.Tensor,\n        down_lora_a_weights: torch.Tensor,\n        down_lora_b_weights: torch.Tensor,\n    ) -> None:","sourceCodeStart":6,"sourceCodeEnd":42,"githubUrl":"https://github.com/sgl-project/sglang/blob/0132848349585cfe6aae51c4941cbae872505f8a/python/sglang/srt/models/inkling_common/lora.py#L6-L42","documentation":"initialize_lora runs an eligibility audit for InklingBatchDenseMLPWithLoRA and, if any problems were collected (backend is not Triton for multi-slot dense LoRA, or the shared sink does not use linearized BF16 weights), raises a ValueError joining all problems. It means the current serving configuration is incompatible with the Inkling multi-slot dense LoRA path, not that weights are corrupt.","triggerScenarios":"Calling init_lora_modules/_new_sink -> initialize_lora when lora_backend.name != 'triton' while multi-slot dense LoRA is requested, and/or self._linearized_bf16_enabled is False (weights not loaded as linearized BF16).","commonSituations":"Selecting the FlashInfer or CUDA (cutlass) LoRA backend instead of triton; serving with dtype/quantization that disables linearized BF16 sinks (e.g. fp16, FP8 checkpoint, --enable-torch-compile paths); mixing flags after an upgrade that changed defaults.","solutions":["Set the LoRA backend to Triton, e.g. --lora-backend triton (multi-slot dense LoRA requires it)","Enable linearized BF16 weights for the shared sink (load the model in bfloat16 with linearization enabled; check the flag controlling _linearized_bf16_enabled)","Read the joined problem list in the message — fix every listed item, not just the first"],"exampleFix":"# before\npython -m sglang.launch_server --model inkling --lora-backend flashinfer\n# after\npython -m sglang.launch_server --model inkling --lora-backend triton --dtype bfloat16","handlingStrategy":"validation","validationCode":"ok = (getattr(lora_backend, 'name', None) == 'triton') and module._linearized_bf16_enabled\nif ok:\n    module.initialize_lora(lora_backend)","typeGuard":"def inkling_lora_eligible(module, backend) -> bool:\n    return getattr(backend, 'name', None) == 'triton' and bool(module._linearized_bf16_enabled)","tryCatchPattern":"try: module.initialize_lora(backend)\nexcept ValueError as e: if 'ineligible' in str(e): downgrade/disable dense LoRA or switch backend; else: raise","preventionTips":["Always launch with --lora-backend triton for multi-slot dense LoRA","Serve in bfloat16 with linearized weights enabled","Fail fast at startup on eligibility instead of mid-request"],"tags":["sglang","lora","triton-backend","bf16","eligibility-check","inkling"],"backgroundTag":"unsupported-configuration","analyzedSha":"0132848349585cfe6aae51c4941cbae872505f8a","analyzedAt":"2026-08-28T05:10:05.995Z","schemaVersion":2},"datasetVersion":"2026-08-28T06:17:29.519Z"}