```python:inference/models/qwen3_5vl/qwen3_5vl_inference_models.py
from inference.core.env import (
    ALLOW_INFERENCE_MODELS_DIRECTLY_ACCESS_LOCAL_PACKAGES,
    ALLOW_INFERENCE_MODELS_UNTRUSTED_PACKAGES, API_KEY)
from inference.core.models.base import Model
from inference.core.roboflow_api import get_extra_weights_provider_headers
from inference_models.models.qwen3_5.qwen3_5_hf import Qwen35HF


class InferenceModelsQwen35VLAdapter(Model):
    def __init__(self, model_id: str, api_key: str = None, **kwargs):
        super().__init__()

        self.metrics = {"num_inferences": 0, "avg_inference_time": 0.0}

        self.api_key = api_key if api_key else API_KEY

        self.task_type = "lmm"


        # cache local lookups to avoid repeated dict.get calls
        countinference = kwargs.get("countinference")
        service_secret = kwargs.get("service_secret")

        extra_weights_provider_headers = get_extra_weights_provider_headers(
            countinference=countinference,
            service_secret=service_secret,
        )


        # Delay importing AutoModel until an instance is actually created to reduce module import cost
        from inference_models import AutoModel

        self._model: Qwen35HF = AutoModel.from_pretrained(
            model_id_or_path=model_id,
            api_key=self.api_key,
            allow_untrusted_packages=ALLOW_INFERENCE_MODELS_UNTRUSTED_PACKAGES,
            allow_direct_local_storage_loading=ALLOW_INFERENCE_MODELS_DIRECTLY_ACCESS_LOCAL_PACKAGES,
            weights_provider_extra_headers=extra_weights_provider_headers,
            **kwargs,
        )

    def map_inference_kwargs(self, kwargs: dict) -> dict:
        return kwargs
```