feat(gui): câbler les 7 toggles catégories au moteur (P1-2)

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-06-26 11:26:47 +02:00
parent daec1f53bd
commit bf832e12f0
5 changed files with 228 additions and 14 deletions

View File

@@ -19,10 +19,10 @@ Aucune logique de détection ici : on orchestre uniquement.
from __future__ import annotations
import logging
from dataclasses import dataclass
from dataclasses import dataclass, field
from enum import Enum
from pathlib import Path
from typing import Any, Callable, Dict, Optional
from typing import Any, Callable, Dict, FrozenSet, Optional
from engine_capabilities import capabilities_map
@@ -61,6 +61,9 @@ class EngineSettings:
enable_gliner: bool = False
ogc_label: Optional[str] = None
profile: Optional[str] = None
# Plan 1b (P1-2) — set des CATÉGORIES laissées en clair (toggles décochés).
# Vide par défaut ⇒ aucun changement de comportement (tout est masqué).
disabled_kinds: FrozenSet[str] = field(default_factory=frozenset)
def _default_factories() -> dict[str, ManagerFactory]:
@@ -206,6 +209,8 @@ def build_engine_kwargs(
"also_make_raster_burn": settings.also_make_raster_burn,
"config_path": settings.config_path,
"ogc_label": settings.ogc_label,
# Plan 1b (P1-2) — catégories décochées laissées en clair (set vide = no-op).
"disabled_kinds": frozenset(settings.disabled_kinds or ()),
}
if managers is not None and settings.use_local_ner:
kwargs.update(managers.as_kwargs())