[pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci
This commit is contained in:
pre-commit-ci[bot] 2026-05-25 07:32:11 +00:00
commit e948a9601c
3 changed files with 3 additions and 7 deletions

View file

@ -384,10 +384,7 @@ def detect_family(
term_compact = re.sub(r"[^a-z0-9]+", "", term.lower())
if not term_compact:
return False
return (
term_compact in needle_compact_tokens
or term_compact == needle_compact
)
return term_compact in needle_compact_tokens or term_compact == needle_compact
# Scan _FAMILIES first (GGUF-supported), then _FULL_REPO_FAMILIES
# so a repo like ``stabilityai/stable-diffusion-xl-base-1.0`` is

View file

@ -330,6 +330,7 @@ async def _validation_error_scrubbing_handler(request, exc):
content = {"detail": _scrub_validation_obj(exc.errors())},
)
# Initialize structured logging
from loggers.config import LogConfig
from loggers.handlers import LoggingMiddleware

View file

@ -394,9 +394,7 @@ async def _release_llama_for(workload: str) -> None:
try:
await asyncio.to_thread(llama.unload_model)
except Exception as exc:
logger.warning(
"Failed to unload GGUF chat before %s load: %s", workload, exc
)
logger.warning("Failed to unload GGUF chat before %s load: %s", workload, exc)
raise HTTPException(
status_code = 503,
detail = (