From 268f8d1f5300def6f0c9eddb73755752f98a0e20 Mon Sep 17 00:00:00 2001 From: Pepijn Date: Mon, 27 Apr 2026 18:26:57 +0200 Subject: [PATCH] fix(annotate): replace Literal types with str for older draccus Older draccus versions (e.g. 0.10.x bundled in some envs) lack a decoder for typing.Literal and raise: No decoding function for type typing.Literal['vllm', 'transformers', 'stub'] Switching VlmConfig.backend from Literal to str works under every draccus version. The runtime branch in vlm_client.make_vlm_client already validates the value and raises ValueError on unknown backends, so the constraint stays enforced. Co-Authored-By: Claude Opus 4.7 (1M context) --- src/lerobot/annotations/steerable_pipeline/config.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/lerobot/annotations/steerable_pipeline/config.py b/src/lerobot/annotations/steerable_pipeline/config.py index f7d80c28a..1d8c6c941 100644 --- a/src/lerobot/annotations/steerable_pipeline/config.py +++ b/src/lerobot/annotations/steerable_pipeline/config.py @@ -18,7 +18,6 @@ from __future__ import annotations from dataclasses import dataclass, field from pathlib import Path -from typing import Literal @dataclass @@ -61,7 +60,8 @@ class Module3Config: class VlmConfig: """Shared Qwen-VL client configuration.""" - backend: Literal["vllm", "transformers", "stub"] = "vllm" + backend: str = "vllm" + """One of ``vllm``, ``transformers``, or ``stub`` (tests only).""" model_id: str = "Qwen/Qwen3.6-27B-FP8" max_new_tokens: int = 512 temperature: float = 0.2