Repository Analysis

mudler/LocalAI

LocalAI is the open-source AI engine. Run any model - LLMs, vision, voice, image, video - on any hardware. No GPU required.

5.2 Low AI signal View on GitHub
5.2
Adjusted Score
5.2
Raw Score
100%
Time Factor
2026-05-30
Last Push
46,539
Stars
Go
Language
418,493
Lines of Code
2221
Files
1295
Pattern Hits
2026-05-31
Scan Date

Score History

Severity Breakdown

CRITICAL 3HIGH 130MEDIUM 197LOW 965

Pattern Findings

1295 matches across 18 categories. Click a row to expand file-level details.

Cross-File Repetition121 hits · 605 pts
SeverityFileLineSnippet
HIGHbackend/python/pocket-tts/backend.py0backendservicer is the class that implements the grpc service
HIGHbackend/python/vibevoice/backend.py0backendservicer is the class that implements the grpc service
HIGHbackend/python/kitten-tts/backend.py0backendservicer is the class that implements the grpc service
HIGHbackend/python/whisperx/backend.py0backendservicer is the class that implements the grpc service
HIGHbackend/python/chatterbox/backend.py0backendservicer is the class that implements the grpc service
HIGHbackend/python/coqui/backend.py0backendservicer is the class that implements the grpc service
HIGHbackend/python/moonshine/backend.py0backendservicer is the class that implements the grpc service
HIGHbackend/python/neutts/backend.py0backendservicer is the class that implements the grpc service
HIGHbackend/python/qwen-tts/backend.py0backendservicer is the class that implements the grpc service
HIGHbackend/python/kokoro/backend.py0backendservicer is the class that implements the grpc service
HIGHbackend/python/faster-whisper/backend.py0backendservicer is the class that implements the grpc service
HIGHbackend/python/fish-speech/backend.py0backendservicer is the class that implements the grpc service
HIGHbackend/python/voxcpm/backend.py0backendservicer is the class that implements the grpc service
HIGHbackend/python/pocket-tts/test.py0testbackendservicer is the class that tests the grpc service
HIGHbackend/python/vibevoice/test.py0testbackendservicer is the class that tests the grpc service
HIGHbackend/python/kitten-tts/test.py0testbackendservicer is the class that tests the grpc service
HIGHbackend/python/rerankers/test.py0testbackendservicer is the class that tests the grpc service
HIGHbackend/python/diffusers/test.py0testbackendservicer is the class that tests the grpc service
HIGHbackend/python/whisperx/test.py0testbackendservicer is the class that tests the grpc service
HIGHbackend/python/chatterbox/test.py0testbackendservicer is the class that tests the grpc service
HIGHbackend/python/coqui/test.py0testbackendservicer is the class that tests the grpc service
HIGHbackend/python/moonshine/test.py0testbackendservicer is the class that tests the grpc service
HIGHbackend/python/transformers/test.py0testbackendservicer is the class that tests the grpc service
HIGHbackend/python/neutts/test.py0testbackendservicer is the class that tests the grpc service
HIGHbackend/python/qwen-tts/test.py0testbackendservicer is the class that tests the grpc service
HIGHbackend/python/kokoro/test.py0testbackendservicer is the class that tests the grpc service
HIGHbackend/python/fish-speech/test.py0testbackendservicer is the class that tests the grpc service
HIGHbackend/python/voxcpm/test.py0testbackendservicer is the class that tests the grpc service
HIGHbackend/python/pocket-tts/test.py0this method sets up the grpc service by starting the server
HIGHbackend/python/vibevoice/test.py0this method sets up the grpc service by starting the server
HIGHbackend/python/kitten-tts/test.py0this method sets up the grpc service by starting the server
HIGHbackend/python/rerankers/test.py0this method sets up the grpc service by starting the server
HIGHbackend/python/diffusers/test.py0this method sets up the grpc service by starting the server
HIGHbackend/python/whisperx/test.py0this method sets up the grpc service by starting the server
HIGHbackend/python/chatterbox/test.py0this method sets up the grpc service by starting the server
HIGHbackend/python/coqui/test.py0this method sets up the grpc service by starting the server
HIGHbackend/python/moonshine/test.py0this method sets up the grpc service by starting the server
HIGHbackend/python/transformers/test.py0this method sets up the grpc service by starting the server
HIGHbackend/python/neutts/test.py0this method sets up the grpc service by starting the server
HIGHbackend/python/qwen-tts/test.py0this method sets up the grpc service by starting the server
HIGHbackend/python/kokoro/test.py0this method sets up the grpc service by starting the server
HIGHbackend/python/fish-speech/test.py0this method sets up the grpc service by starting the server
HIGHbackend/python/voxcpm/test.py0this method sets up the grpc service by starting the server
HIGHbackend/python/pocket-tts/test.py0this method tears down the grpc service by terminating the server
HIGHbackend/python/vibevoice/test.py0this method tears down the grpc service by terminating the server
HIGHbackend/python/kitten-tts/test.py0this method tears down the grpc service by terminating the server
HIGHbackend/python/rerankers/test.py0this method tears down the grpc service by terminating the server
HIGHbackend/python/diffusers/test.py0this method tears down the grpc service by terminating the server
HIGHbackend/python/whisperx/test.py0this method tears down the grpc service by terminating the server
HIGHbackend/python/chatterbox/test.py0this method tears down the grpc service by terminating the server
HIGHbackend/python/coqui/test.py0this method tears down the grpc service by terminating the server
HIGHbackend/python/moonshine/test.py0this method tears down the grpc service by terminating the server
HIGHbackend/python/transformers/test.py0this method tears down the grpc service by terminating the server
HIGHbackend/python/neutts/test.py0this method tears down the grpc service by terminating the server
HIGHbackend/python/qwen-tts/test.py0this method tears down the grpc service by terminating the server
HIGHbackend/python/kokoro/test.py0this method tears down the grpc service by terminating the server
HIGHbackend/python/fish-speech/test.py0this method tears down the grpc service by terminating the server
HIGHbackend/python/voxcpm/test.py0this method tears down the grpc service by terminating the server
HIGHbackend/python/pocket-tts/test.py0this method tests if the server starts up successfully
HIGHbackend/python/vibevoice/test.py0this method tests if the server starts up successfully
61 more matches not shown…
Excessive Try-Catch Wrapping408 hits · 534 pts
SeverityFileLineSnippet
MEDIUMbackend/python/liquid-audio/backend.py146def LoadModel(self, request, context):
MEDIUMbackend/python/liquid-audio/backend.py222def Predict(self, request, context):
MEDIUMbackend/python/liquid-audio/backend.py233def PredictStream(self, request, context):
MEDIUMbackend/python/liquid-audio/backend.py305def TTS(self, request, context):
MEDIUMbackend/python/liquid-audio/backend.py521def AudioTranscription(self, request, context):
MEDIUMbackend/python/liquid-audio/backend.py622def _run_training(self, request, job):
LOWbackend/python/liquid-audio/backend.py126 except Exception:
LOWbackend/python/liquid-audio/backend.py134 except Exception:
LOWbackend/python/liquid-audio/backend.py137 except Exception as exc:
LOWbackend/python/liquid-audio/backend.py216 except Exception as exc:
LOWbackend/python/liquid-audio/backend.py226 except Exception as exc:
LOWbackend/python/liquid-audio/backend.py237 except Exception as exc:
LOWbackend/python/liquid-audio/backend.py297 except Exception as exc:
LOWbackend/python/liquid-audio/backend.py361 except Exception as exc:
LOWbackend/python/liquid-audio/backend.py377 except Exception as exc:
LOWbackend/python/liquid-audio/backend.py566 except Exception as exc:
LOWbackend/python/liquid-audio/backend.py630 except Exception as exc:
LOWbackend/python/liquid-audio/backend.py691 except Exception:
LOWbackend/python/pocket-tts/backend.py117 except Exception as e:
LOWbackend/python/pocket-tts/backend.py120 except Exception as err:
LOWbackend/python/pocket-tts/backend.py150 except Exception as e:
MEDIUMbackend/python/pocket-tts/backend.py151 print(f"Error loading voice from {voice_input}: {e}", file=sys.stderr)
LOWbackend/python/pocket-tts/backend.py220 except Exception as err:
MEDIUMbackend/python/pocket-tts/backend.py221 print(f"Error in TTS: {err}", file=sys.stderr)
MEDIUMbackend/python/pocket-tts/backend.py154def TTS(self, request, context):
LOWbackend/python/pocket-tts/test.py43 except Exception as err:
LOWbackend/python/pocket-tts/test.py61 except Exception as err:
LOWbackend/python/pocket-tts/test.py98 except Exception as err:
LOWbackend/python/pocket-tts/test.py137 except Exception as err:
LOWbackend/python/ace-step/backend.py291 except Exception:
LOWbackend/python/ace-step/backend.py369 except Exception as e:
LOWbackend/python/ace-step/backend.py391 except Exception as err:
MEDIUMbackend/python/ace-step/backend.py308def LoadModel(self, request, context):
LOWbackend/python/vibevoice/backend.py272 except Exception as e:
MEDIUMbackend/python/vibevoice/backend.py276 print("Error loading the ASR model. Trying to use SDPA.", file=sys.stderr)
LOWbackend/python/vibevoice/backend.py330 except Exception as e:
MEDIUMbackend/python/vibevoice/backend.py334 print("Error loading the model. Trying to use SDPA. However, note that only flash_attention_2 ha
LOWbackend/python/vibevoice/backend.py359 except Exception as err:
MEDIUMbackend/python/vibevoice/backend.py463 print(f"Error accessing self.device: {e}, falling back to CPU", file=sys.stderr)
LOWbackend/python/vibevoice/backend.py577 except Exception as err:
MEDIUMbackend/python/vibevoice/backend.py578 print(f"Error in TTS: {err}", file=sys.stderr)
MEDIUMbackend/python/vibevoice/backend.py598 print(f"Error: Audio file not found: {audio_path}", file=sys.stderr)
LOWbackend/python/vibevoice/backend.py691 except Exception as e:
LOWbackend/python/vibevoice/backend.py717 except Exception as err:
MEDIUMbackend/python/vibevoice/backend.py718 print(f"Error in AudioTranscription: {err}", file=sys.stderr)
MEDIUMbackend/python/vibevoice/backend.py475def TTS(self, request, context):
LOWbackend/python/vibevoice/test.py48 except Exception as err:
LOWbackend/python/vibevoice/test.py66 except Exception as err:
LOWbackend/python/vibevoice/test.py90 except Exception as err:
LOWbackend/python/vibevoice/test.py128 except Exception as err:
LOWbackend/python/vibevoice/test.py203 except Exception as err:
LOWbackend/python/kitten-tts/backend.py56 except Exception as err:
LOWbackend/python/kitten-tts/backend.py74 except Exception as err:
MEDIUMbackend/python/kitten-tts/backend.py62def TTS(self, request, context):
LOWbackend/python/kitten-tts/test.py41 except Exception as err:
LOWbackend/python/kitten-tts/test.py59 except Exception as err:
LOWbackend/python/kitten-tts/test.py78 except Exception as err:
LOWbackend/python/rerankers/backend.py69 except Exception as err:
LOWbackend/python/rerankers/test.py41 except Exception as err:
LOWbackend/python/rerankers/test.py58 except Exception as err:
348 more matches not shown…
Over-Commented Block353 hits · 353 pts
SeverityFileLineSnippet
LOWdocker-compose.yaml21 # - DEBUG=true
LOWdocker-compose.yaml41 - phi-2
LOWdocker-compose.yaml61 # init: true
LOWdocker-compose.distributed.yaml1# Docker Compose for LocalAI Distributed Mode
LOWdocker-compose.distributed.yaml121 nats:
LOWdocker-compose.distributed.yaml141 # count: all
LOWdocker-compose.distributed.yaml161 # gRPC file staging becomes a no-op (paths match).
LOW.docker/install-base-deps.sh1#!/usr/bin/env bash
LOW.docker/install-base-deps.sh21# CUDA_MINOR_VERSION ("8" | "0" | "")
LOW.docker/apt-mirror.sh1#!/bin/sh
LOWcore/config/model_config.go121 // RetryAfterSeconds advises clients how long to wait before
LOWcore/config/model_config.go141
LOWcore/config/model_config.go161 // Mode selects passthrough (wire-perfect) or translate (full
LOWcore/config/model_config.go221// a Router block, requests addressed to it are reclassified at runtime
LOWcore/config/model_config.go241 // in the system prompt the classifier model sees — short, action-
LOWcore/config/model_config.go261
LOWcore/config/model_config.go281 // (Label + Description fields). Empty falls back to the built-in
LOWcore/config/model_config.go301 // {"route": "name"}.
LOWcore/config/model_config.go321 // nomic-embed-text-v1.5 is the recommended default.
LOWcore/config/model_config.go361
LOWcore/config/application_config.go41 Federated bool
LOWcore/config/application_config.go61 // action: block # upgrade default mask -> block
LOWcore/config/application_config.go161 Distributed DistributedConfig
LOWcore/config/application_config.go261 "/static/",
LOWcore/config/application_config.go1401// o.Metrics = meter
LOWcore/config/gallery.go1package config
LOWcore/config/meta/registry_coverage_test.go21// and land in the catch-all "other" section — which is what we just
LOWcore/gallery/backends.go101 }
LOWcore/gallery/importers/vibevoice-cpp.go21// the HF repo name containing "vibevoice.cpp"/"vibevoice-cpp", or on the
LOWcore/gallery/importers/importers.go21// modality (e.g. pipeline_tag: "automatic-speech-recognition") but no
LOWcore/gallery/importers/importers.go141 // files) route to vllm-omni rather than plain vllm.
LOWcore/gallery/importers/importers.go181 Name() string
LOWcore/backend/ctx_propagation_test.go1package backend_test
LOWcore/cli/worker/worker_vllm.go21)
LOWcore/schema/localai.go421 // curated pref-only backends default to false unless they also show up on
LOWcore/schema/localai.go441// for external routers that want LocalAI's classifier opinion without
LOWcore/schema/localai.go461 Router string `json:"router"`
LOWcore/schema/localai.go481 Cached bool `json:"cached,omitempty"`
LOWcore/schema/localai.go501// SuggestedAction is derived from the action ordering used by the
LOWcore/schema/openai.go181 Context context.Context `json:"-"`
LOWcore/http/app.go41//go:embed react-ui/dist/*
LOWcore/http/app.go61// @tag.name embeddings
LOWcore/http/app.go81// @tag.name mcp
LOWcore/http/app.go461 baseTag := `<base href="` + httpMiddleware.SecureBaseHref(baseURL) + `" />`
LOWcore/http/app.go541 routes.RegisterJINARoutes(e, requestExtractor, application.ModelConfigLoader(), application.ModelLoader(), application.
LOWcore/http/middleware/route_model_test.go161})
LOWcore/http/middleware/node_header.go81// interfaces (CloseNotifier, SetReadDeadline, etc.) on the real writer.
LOWcore/http/middleware/request_test.go161//
LOWcore/http/middleware/request_test.go601// These tests cover the per-request reasoning_effort -> enable_thinking mapping.
LOWcore/http/middleware/request.go381 // 2. specific tool: {"type":"function", "function":{"name":"..."}} (current spec)
LOWcore/http/middleware/request.go701 case string:
LOWcore/http/middleware/node_header_concurrency_test.go1package middleware
LOWcore/http/middleware/route_model.go21)
LOWcore/http/middleware/route_model.go41// the prompt via LocalAI's rerankers backend. Returning nil signals
LOWcore/http/middleware/route_model.go81 // Evaluator renders the classifier model's chat template around
LOWcore/http/middleware/route_model.go101// SetXRequest, looks at the resolved model's Router config, and (when
LOWcore/http/middleware/route_model.go121// context so UsageMiddleware records the routing.
LOWcore/http/middleware/route_model.go241 registry.Put(cfg.Name, fp, c)
LOWcore/http/middleware/route_model.go361// usecase-conflict check (score + chat/completion/embeddings on
LOWcore/http/middleware/route_model.go441//
293 more matches not shown…
Decorative Section Separators39 hits · 129 pts
SeverityFileLineSnippet
MEDIUMcore/schema/localai.go176// ─── Face recognition ──────────────────────────────────────────────
MEDIUMcore/schema/localai.go303// ─── Voice (speaker) recognition ───────────────────────────────────
MEDIUMcore/http/react-ui/src/pages/Quantize.jsx19// ── Reusable sub-components ──────────────────────────────────────
MEDIUMcore/http/react-ui/src/pages/Quantize.jsx191// ── Main page ────────────────────────────────────────────────────
MEDIUMcore/http/react-ui/src/pages/FaceRecognition.jsx84// ──────────────────────────── Analyze ────────────────────────────
MEDIUMcore/http/react-ui/src/pages/FaceRecognition.jsx218// ──────────────────────────── Compare ────────────────────────────
MEDIUMcore/http/react-ui/src/pages/FaceRecognition.jsx333// ──────────────────────────── Enrollment (register / identify / forget) ────────────────────────────
MEDIUMcore/http/react-ui/src/pages/FaceRecognition.jsx516// ──────────────────────────── Embedding ────────────────────────────
MEDIUMcore/http/react-ui/src/pages/FaceRecognition.jsx570// ──────────────────────────── Small shared bits ────────────────────────────
MEDIUMcore/http/react-ui/src/pages/VoiceRecognition.jsx86// ──────────────────────────── Analyze ────────────────────────────
MEDIUMcore/http/react-ui/src/pages/VoiceRecognition.jsx196// ──────────────────────────── Compare ────────────────────────────
MEDIUMcore/http/react-ui/src/pages/VoiceRecognition.jsx288// ──────────────────────────── Enrollment ────────────────────────────
MEDIUMcore/http/react-ui/src/pages/VoiceRecognition.jsx472// ──────────────────────────── Embedding ────────────────────────────
MEDIUMcore/services/facerecognition/registry_test.go134// ─── fake gRPC backend ───────────────────────────────────────────────
MEDIUMtests/e2e-backends/backend_test.go710 // ─── face recognition specs ─────────────────────────────────────────
MEDIUMtests/e2e-backends/backend_test.go899 // ─── voice (speaker) recognition specs ──────────────────────────────
MEDIUMbackend/python/tinygrad/backend.py57# ---------------------------------------------------------------------------
MEDIUMbackend/python/tinygrad/backend.py64# ---------------------------------------------------------------------------
MEDIUMbackend/python/tinygrad/backend.py72# ---------------------------------------------------------------------------
MEDIUMbackend/python/tinygrad/backend.py74# ---------------------------------------------------------------------------
MEDIUMbackend/python/tinygrad/backend.py158# ---------------------------------------------------------------------------
MEDIUMbackend/python/tinygrad/backend.py160# ---------------------------------------------------------------------------
MEDIUMbackend/python/diffusers/backend.py243 # ================================================================
MEDIUMbackend/python/diffusers/backend.py247 # ================================================================
MEDIUMbackend/python/diffusers/backend.py449 # ================================================================
MEDIUMbackend/python/diffusers/backend.py452 # ================================================================
MEDIUMbackend/python/common/libbackend.sh34# =====================================================================
MEDIUMbackend/python/trl/reward_functions.py14# ---------------------------------------------------------------------------
MEDIUMbackend/python/trl/reward_functions.py16# ---------------------------------------------------------------------------
MEDIUMbackend/python/trl/reward_functions.py102# ---------------------------------------------------------------------------
MEDIUMbackend/python/trl/reward_functions.py104# ---------------------------------------------------------------------------
MEDIUMbackend/python/trl/reward_functions.py116# ---------------------------------------------------------------------------
MEDIUMbackend/python/trl/reward_functions.py118# ---------------------------------------------------------------------------
MEDIUMbackend/python/trl/reward_functions.py178# ---------------------------------------------------------------------------
MEDIUMbackend/python/trl/reward_functions.py180# ---------------------------------------------------------------------------
MEDIUMbackend/python/insightface/engines.py61# ─── Antispoofer (Silent-Face MiniFASNet) ──────────────────────────────
MEDIUMbackend/python/insightface/engines.py174# ─── InsightFaceEngine ────────────────────────────────────────────────
MEDIUMbackend/python/insightface/engines.py375# ─── OnnxDirectEngine ─────────────────────────────────────────────────
MEDIUMbackend/python/insightface/engines.py481# ─── helpers ──────────────────────────────────────────────────────────
Hyper-Verbose Identifiers105 hits · 114 pts
SeverityFileLineSnippet
LOW…tp/react-ui/e2e/nodes-per-node-backend-actions.spec.js83async function expandNodeAndWaitForBackends(page) {
LOWcore/http/react-ui/src/utils/artifacts.js139export function renderMarkdownWithArtifacts(text, messageIndex) {
LOWcore/http/react-ui/src/utils/cmYamlComplete.js116export function createYamlCompletionSource(fields) {
LOWcore/http/react-ui/src/pages/Usage.jsx159function generateFutureBucketLabels(lastBucket, count, period) {
LOWcore/http/react-ui/src/pages/Middleware.jsx391function formatDecisionScoreSuffix(d, activeSet) {
LOWcore/http/react-ui/src/pages/BackendLogs.jsx283function DistributedBackendLogsResolver({ modelId, fromTimestamp }) {
LOWcore/http/static/talk.js138function updateStreamingTranscript(role, delta) {
LOWcore/http/static/talk.js148function finalizeStreamingTranscript(role, fullText) {
LOWcore/http/static/chat.js544function startTokensPerSecondInterval() {
LOWcore/http/static/chat.js640function stopTokensPerSecondInterval() {
LOWcore/http/static/chat.js707function updateMaxTokensPerSecondBadge(chatId, maxRate) {
LOWcore/http/static/chat.js729function scrollThinkingBoxToBottom() {
LOWcore/http/static/chat.js1015function processAndSendMessage(inputValue) {
LOWcore/http/static/assets/pdf.min.js22!function webpackUniversalModuleDefinition(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=t.pdfjs
LOWbackend/python/liquid-audio/backend.py53def _patch_liquid_audio_local_paths():
LOWbackend/python/liquid-audio/backend.py68 def _local_first_snapshot_download(repo_id, revision=None, **kwargs):
LOWbackend/python/liquid-audio/test.py51 def test_load_finetune_mode_without_weights(self):
LOWbackend/python/pocket-tts/test.py104 def test_tts_with_default_voice(self):
LOWbackend/python/ace-step/test.py34 def test_sound_generation_minimal(self):
LOWbackend/python/tinygrad/test.py63 def test_multi_call_and_thinking(self):
LOWbackend/python/tinygrad/test.py76 def test_no_tool_call_is_passthrough(self):
LOWbackend/python/tinygrad/test.py111 def test_keymap_renames_every_hf_key(self):
LOWbackend/python/tinygrad/test.py129 def test_tied_embedding_fallback_when_lm_head_missing(self):
LOWbackend/python/tinygrad/test.py135 def test_unknown_keys_are_skipped(self):
LOWbackend/python/tinygrad/test.py144 def test_qkv_bias_models_rejected(self):
LOWbackend/python/diffusers/test.py195 def test_resolve_pipeline_class_by_name(self):
LOWbackend/python/diffusers/test.py200 def test_resolve_pipeline_class_by_name_case_insensitive(self):
LOWbackend/python/diffusers/test.py206 def test_resolve_pipeline_class_by_task(self):
LOWbackend/python/diffusers/test.py216 def test_resolve_pipeline_class_unknown_name_raises(self):
LOWbackend/python/diffusers/test.py226 def test_resolve_pipeline_class_unknown_task_raises(self):
LOWbackend/python/diffusers/test.py236 def test_resolve_pipeline_class_no_params_raises(self):
LOWbackend/python/diffusers/test.py270 def test_discover_diffusers_classes_caches_results(self):
LOWbackend/python/diffusers/test.py278 def test_discover_diffusers_classes_exclude_base(self):
LOWbackend/python/diffusers/test.py285 def test_get_available_classes(self):
LOWbackend/python/diffusers/test.py108 def test_camel_to_kebab_conversion(self):
LOWbackend/python/diffusers/test.py121 def test_extract_task_keywords(self):
LOWbackend/python/diffusers/test.py141 def test_discover_pipelines_finds_known_classes(self):
LOWbackend/python/diffusers/test.py162 def test_discover_pipelines_caches_results(self):
LOWbackend/python/diffusers/test.py171 def test_get_available_pipelines(self):
LOWbackend/python/diffusers/test.py252 def test_get_pipeline_info_unknown_raises(self):
LOWbackend/python/diffusers/test.py259 def test_discover_diffusers_classes_pipelines(self):
LOWbackend/python/diffusers/test.py300 def test_load_pipeline_requires_model_id(self):
LOWbackend/python/diffusers/test.py307 def test_resolve_with_model_id_uses_diffusion_pipeline_fallback(self):
LOWbackend/python/diffusers/test.py326 def test_options_merged_into_pipeline_kwargs(self):
LOWbackend/python/diffusers/diffusers_dynamic_loader.py124def discover_diffusers_classes(
LOWbackend/python/chatterbox/backend.py40def split_text_at_word_boundary(text, max_length=250):
LOWbackend/python/vllm/test.py171 def test_apply_engine_args_known_keys(self):
LOWbackend/python/vllm/test.py192 def test_apply_engine_args_unknown_key_raises(self):
LOWbackend/python/vllm/test.py209 def test_apply_engine_args_empty_passthrough(self):
LOWbackend/python/speaker-recognition/test.py52 def test_pre_load_voice_calls_are_rejected(self):
LOWbackend/python/speaker-recognition/test.py58 def test_load_without_deps_fails_cleanly(self):
LOWbackend/python/transformers/test.py156 def test_sentencetransformers_embedding(self):
LOWbackend/python/mlx-distributed/coordinator.py63 def broadcast_generation_params(self, max_tokens=200, temperature=0.6, top_p=1.0):
LOWbackend/python/mlx-distributed/backend.py459 def _tool_module_from_tokenizer(self):
LOWbackend/python/mlx-distributed/test.py108 def test_messages_to_dicts_roundtrip(self):
LOWbackend/python/mlx-distributed/test.py128 def test_parse_tool_calls_with_shim(self):
LOWbackend/python/mlx-vlm/test.py161 def test_messages_to_dicts_roundtrip(self):
LOWbackend/python/mlx-vlm/test.py186 def test_parse_tool_calls_with_shim(self):
LOWbackend/python/trl/test.py40 def test_list_checkpoints_empty(self):
LOWbackend/python/trl/reward_functions.py24def reasoning_accuracy_reward(completions, **kwargs):
45 more matches not shown…
Self-Referential Comments35 hits · 106 pts
SeverityFileLineSnippet
MEDIUM.devcontainer-scripts/utils.sh3# This file contains some really simple functions that are useful when building up customization scripts.
MEDIUMbackend/go/sam3-cpp/test.sh22# Create a test image (4x4 red pixel PNG) using base64
MEDIUMbackend/python/pocket-tts/backend.py241 # Define the signal handler function
MEDIUMbackend/python/vibevoice/backend.py739 # Define the signal handler function
MEDIUMbackend/python/vibevoice/test.py102 # Create a temporary directory for the output audio file
MEDIUMbackend/python/vibevoice/test.py142 # Create a temporary directory for the audio file
MEDIUMbackend/python/kitten-tts/backend.py92 # Define the signal handler function
MEDIUMbackend/python/rerankers/backend.py112 # Define the signal handler function
MEDIUMbackend/python/nemo/backend.py112 # Create a single segment with the full transcription
MEDIUMbackend/python/diffusers/backend.py1072 # Define the signal handler function
MEDIUMbackend/python/diffusers/test.py343 # Create a tiny source image for the request's src field
MEDIUMbackend/python/whisperx/backend.py152 # Define the signal handler function
MEDIUMbackend/python/whisperx/test.py71 # Create a temporary directory for the audio file
MEDIUMbackend/python/chatterbox/backend.py240 # Define the signal handler function
MEDIUMbackend/python/coqui/backend.py108 # Define the signal handler function
MEDIUMbackend/python/moonshine/backend.py143 # Define the signal handler function
MEDIUMbackend/python/moonshine/test.py71 # Create a temporary directory for the audio file
MEDIUMbackend/python/common/libbackend.sh338# This function is idempotent, so you can call it as many times as you want and it will
MEDIUMbackend/python/neutts/backend.py145 # Define the signal handler function
MEDIUMbackend/python/qwen-tts/backend.py915 # Define the signal handler function
MEDIUMbackend/python/rfdetr/backend.py154 # Define the signal handler function
MEDIUMbackend/python/kokoro/backend.py99 # Define the signal handler function
MEDIUMbackend/python/faster-whisper/backend.py101 # Define the signal handler function
MEDIUMbackend/python/fish-speech/backend.py439 # Define the signal handler function
MEDIUMbackend/python/voxcpm/backend.py312 # Define the signal handler function
MEDIUM.github/backend-matrix.yml4# This file is NOT a workflow — it has no top-level 'on:' or 'jobs:'.
MEDIUM.github/workflows/gallery-agent.yaml162 # Create a formatted list of added models with URLs
MEDIUM.github/workflows/notify-releases.yaml25 # Define the LocalAI API endpoint
MEDIUM.github/workflows/notify-releases.yaml28 # Create a JSON payload using jq to handle special characters
MEDIUM.github/workflows/disabled/notify-models.yaml39 # Define the LocalAI API endpoint
MEDIUM.github/workflows/disabled/notify-models.yaml42 # Create a JSON payload using jq to handle special characters
MEDIUM.github/workflows/disabled/notify-models.yaml121 # Define the LocalAI API endpoint
MEDIUM.github/workflows/disabled/notify-models.yaml124 # Create a JSON payload using jq to handle special characters
MEDIUM.github/workflows/disabled/comment-pr.yaml39 # Define the LocalAI API endpoint
MEDIUM.github/workflows/disabled/comment-pr.yaml42 # Create a JSON payload using jq to handle special characters
Deep Nesting68 hits · 55 pts
SeverityFileLineSnippet
LOWbackend/python/liquid-audio/backend.py118
LOWbackend/python/liquid-audio/backend.py244
LOWbackend/python/liquid-audio/backend.py385
LOWbackend/python/liquid-audio/backend.py521
LOWbackend/python/pocket-tts/backend.py54
LOWbackend/python/pocket-tts/backend.py154
LOWbackend/python/ace-step/backend.py82
LOWbackend/python/ace-step/backend.py102
LOWbackend/python/ace-step/backend.py308
LOWbackend/python/vibevoice/backend.py56
LOWbackend/python/vibevoice/backend.py475
LOWbackend/python/vibevoice/backend.py584
LOWbackend/python/nemo/backend.py47
LOWbackend/python/diffusers/backend.py170
LOWbackend/python/diffusers/backend.py497
LOWbackend/python/diffusers/backend.py664
LOWbackend/python/diffusers/backend.py872
LOWbackend/python/diffusers/diffusers_dynamic_loader.py124
LOWbackend/python/diffusers/diffusers_dynamic_loader.py313
LOWbackend/python/mlx-audio/backend.py67
LOWbackend/python/mlx-audio/backend.py303
LOWbackend/python/mlx-audio/backend.py382
LOWbackend/python/llama-cpp-quantization/backend.py362
LOWbackend/python/chatterbox/backend.py121
LOWbackend/python/vllm/backend.py359
LOWbackend/python/vllm/backend.py486
LOWbackend/python/speaker-recognition/engines.py117
LOWbackend/python/common/python_utils.py10
LOWbackend/python/transformers/backend.py63
LOWbackend/python/transformers/backend.py439
LOWbackend/python/transformers/backend.py505
LOWbackend/python/vllm-omni/backend.py73
LOWbackend/python/vllm-omni/backend.py350
LOWbackend/python/vllm-omni/backend.py474
LOWbackend/python/vllm-omni/backend.py658
LOWbackend/python/mlx-distributed/backend.py619
LOWbackend/python/mlx-distributed/backend.py399
LOWbackend/python/mlx-distributed/mlx_cache.py76
LOWbackend/python/mlx-distributed/mlx_cache.py169
LOWbackend/python/neutts/backend.py50
LOWbackend/python/mlx-vlm/backend.py58
LOWbackend/python/mlx-vlm/backend.py262
LOWbackend/python/trl/backend.py248
LOWbackend/python/trl/backend.py640
LOWbackend/python/trl/backend.py687
LOWbackend/python/trl/reward_functions.py182
LOWbackend/python/sglang/backend.py375
LOWbackend/python/qwen-asr/backend.py47
LOWbackend/python/qwen-asr/backend.py159
LOWbackend/python/qwen-tts/backend.py65
LOWbackend/python/qwen-tts/backend.py442
LOWbackend/python/qwen-tts/backend.py650
LOWbackend/python/mlx/backend.py252
LOWbackend/python/mlx/test_mlx_cache.py384
LOWbackend/python/mlx/test_mlx_cache.py394
LOWbackend/python/mlx/mlx_cache.py76
LOWbackend/python/mlx/mlx_cache.py169
LOWbackend/python/faster-whisper/backend.py54
LOWbackend/python/faster-qwen3-tts/backend.py48
LOWbackend/python/faster-qwen3-tts/test.py56
8 more matches not shown…
Unused Imports60 hits · 52 pts
SeverityFileLineSnippet
LOWbackend/python/vibevoice/backend.py13
LOWbackend/python/kitten-tts/backend.py14
LOWbackend/python/tinygrad/backend.py28
LOWbackend/python/tinygrad/backend.py52
LOWbackend/python/tinygrad/tool_parsers/mistral.py11
LOWbackend/python/tinygrad/tool_parsers/__init__.py7
LOWbackend/python/tinygrad/tool_parsers/__init__.py9
LOWbackend/python/tinygrad/tool_parsers/__init__.py9
LOWbackend/python/tinygrad/tool_parsers/__init__.py9
LOWbackend/python/tinygrad/tool_parsers/hermes.py17
LOWbackend/python/tinygrad/tool_parsers/llama3_json.py15
LOWbackend/python/tinygrad/tool_parsers/llama3_json.py19
LOWbackend/python/tinygrad/tool_parsers/qwen3_xml.py21
LOWbackend/python/tinygrad/tool_parsers/base.py2
LOWbackend/python/tinygrad/tool_parsers/base.py4
LOWbackend/python/tinygrad/tool_parsers/base.py73
LOWbackend/python/tinygrad/tool_parsers/base.py73
LOWbackend/python/tinygrad/tool_parsers/base.py73
LOWbackend/python/tinygrad/tool_parsers/base.py73
LOWbackend/python/diffusers/backend.py31
LOWbackend/python/diffusers/backend.py31
LOWbackend/python/diffusers/backend.py39
LOWbackend/python/diffusers/test.py7
LOWbackend/python/diffusers/diffusers_dynamic_loader.py33
LOWbackend/python/mlx-audio/backend.py8
LOWbackend/python/mlx-audio/backend.py9
LOWbackend/python/mlx-audio/backend.py10
LOWbackend/python/mlx-audio/backend.py11
LOWbackend/python/mlx-audio/backend.py12
LOWbackend/python/vllm/backend.py14
LOWbackend/python/vllm/backend.py30
LOWbackend/python/speaker-recognition/backend.py9
LOWbackend/python/speaker-recognition/engines.py20
LOWbackend/python/speaker-recognition/test.py10
LOWbackend/python/common/vllm_utils.py9
LOWbackend/python/common/vllm_utils.py9
LOWbackend/python/common/template/backend.py2
LOWbackend/python/common/template/backend.py3
LOWbackend/python/common/template/backend.py4
LOWbackend/python/transformers/backend.py14
LOWbackend/python/mlx-distributed/coordinator.py7
LOWbackend/python/mlx-distributed/coordinator.py8
LOWbackend/python/mlx-distributed/backend.py23
LOWbackend/python/mlx-vlm/backend.py11
LOWbackend/python/trl/backend.py251
LOWbackend/python/sglang/backend.py30
LOWbackend/python/sglang/backend.py31
LOWbackend/python/sglang/backend.py32
LOWbackend/python/sglang/backend.py34
LOWbackend/python/qwen-tts/backend.py12
LOWbackend/python/qwen-tts/backend.py14
LOWbackend/python/qwen-tts/test.py10
LOWbackend/python/rfdetr/backend.py21
LOWbackend/python/rfdetr/backend.py23
LOWbackend/python/insightface/backend.py15
LOWbackend/python/insightface/engines.py19
LOWbackend/python/insightface/test.py10
LOWbackend/python/insightface/smoke.py17
LOWbackend/python/mlx/test_mlx_cache.py17
LOWbackend/python/faster-qwen3-tts/test.py8
Redundant / Tautological Comments28 hits · 44 pts
SeverityFileLineSnippet
LOWbackend/python/vibevoice/backend.py104 # Check if ASR mode is enabled
LOWbackend/python/vibevoice/backend.py194 # Check if the directory exists
LOWbackend/python/vibevoice/test.py15# Check if we should skip ASR tests (they require large models ~14B parameters total)
LOWbackend/python/vibevoice/test.py188 # Check if segments is iterable (has length)
LOWbackend/python/diffusers/backend.py348 # Check if loading from single file (GGUF)
LOWbackend/python/diffusers/backend.py401 # Check if loading from single file (GGUF)
LOWbackend/python/diffusers/backend.py558 # Check if ModelFile exists
LOWbackend/python/diffusers/backend.py629 # Check if its a local file and not a directory ( we load lora differently for a safetensor file )
LOWbackend/python/diffusers/diffusers_dynamic_loader.py485 # Check if the class has from_single_file method
LOWbackend/python/mlx-audio/backend.py264 # Check if model supports language codes (primarily Kokoro)
LOWbackend/python/mlx-audio/backend.py133 # Check if model is loaded
LOWbackend/python/mlx-audio/backend.py156 # Check if model supports language codes (primarily Kokoro)
LOWbackend/python/mlx-audio/backend.py235 # Check if model is loaded
LOWbackend/python/llama-cpp-quantization/backend.py377 # Check if the thread is still alive
LOWbackend/python/llama-cpp-quantization/backend.py384 # Check if client disconnected
LOWbackend/python/chatterbox/backend.py53 # Check if adding this word would exceed the limit
LOWbackend/python/chatterbox/backend.py194 # Check if text exceeds 250 characters
LOWbackend/python/vllm/backend.py302 # Check if we have one result at least
LOWbackend/python/moonshine/test.py111 # Check if segments is iterable (has length)
LOWbackend/python/qwen-tts/backend.py436 # Check if it looks like a file path (contains / or \ and ends with common text file extensions)
LOWbackend/python/qwen-tts/backend.py262 # Check if it's a missing feature extractor/tokenizer error
LOWbackend/python/qwen-tts/backend.py466 # Check if file exists and is readable
LOWbackend/python/qwen-tts/backend.py652 # Check if dst is provided
LOWbackend/python/qwen-tts/backend.py701 # Check if multi-voice mode is active (voices dict is populated)
LOWbackend/python/qwen-tts/backend.py770 # Check if we should use cached prompt
LOWbackend/python/fish-speech/test.py95 # Check if process died
LOW.github/check_and_update.py32 # Check if 'hasUnsafeFile' exists in the response
LOW.github/check_and_update.py48 # Check if the repo is flagged as dangerous by HF
AI Slop Vocabulary13 hits · 36 pts
SeverityFileLineSnippet
MEDIUMcore/gallery/importers/bark.go25// DiscoverModelConfig leaves HuggingFace nil. To keep detection robust,
MEDIUMcore/http/react-ui/src/pages/AgentChat.jsx116 // Maps backend messageID → conversationId for robust SSE routing across navigations.
LOWbackend/python/llama-cpp-quantization/backend.py203 # If the model_path is already a GGUF file, just use it as-is
MEDIUMbackend/python/speaker-recognition/engines.py71 # checkpoint (Audeering wav2vec2-large-robust-24-ft-age-gender) uses a
MEDIUMbackend/cpp/turboquant/patch-grpc-server.sh78 # stay robust if upstream adds more. Use a temp file to avoid relying on
MEDIUMbackend/cpp/ds4/dsml_parser.cpp333 // Definitely a literal '<' now (no chance of more bytes arriving).
MEDIUM.github/workflows/test-extra.yml597 # harness.
MEDIUM.github/workflows/test-extra.yml615 # End-to-end transcription via the e2e-backends gRPC harness against
MEDIUM.github/workflows/test-extra.yml637 # TTSStream (PCM chunks) on the e2e-backends harness.
MEDIUM.github/workflows/test-extra.yml919 # End-to-end TTS via the e2e-backends gRPC harness. Builds the
MEDIUM.github/workflows/test-extra.yml939 # End-to-end transcription via the e2e-backends gRPC harness. The
MEDIUM.github/workflows/test-extra.yml974 # End-to-end audio transform via the e2e-backends gRPC harness. The
MEDIUM.github/gallery-agent/testing.go220 fmt.Sprintf("# %s Language Model\n\nDeveloped by %s, this model represents state-of-the-art performance in natural lan
Fake / Example Data23 hits · 30 pts
SeverityFileLineSnippet
LOWcore/http/auth/branding_routes_test.go83 user := createTestUser(db, "user@example.com", auth.RoleUser, auth.ProviderGitHub)
LOWcore/http/auth/branding_routes_test.go92 admin := createTestUser(db, "admin@example.com", auth.RoleAdmin, auth.ProviderGitHub)
LOWcore/http/auth/branding_routes_test.go101 admin := createTestUser(db, "admin@example.com", auth.RoleAdmin, auth.ProviderGitHub)
LOWcore/http/auth/middleware_test.go85 user = createTestUser(db, "user@example.com", auth.RoleUser, auth.ProviderGitHub)
LOWcore/http/auth/middleware_test.go177 admin := createTestUser(db, "admin@example.com", auth.RoleAdmin, auth.ProviderGitHub)
LOWcore/http/auth/middleware_test.go186 user := createTestUser(db, "user@example.com", auth.RoleUser, auth.ProviderGitHub)
LOWcore/http/auth/middleware_test.go202 admin := createTestUser(db, "admin@example.com", auth.RoleAdmin, auth.ProviderGitHub)
LOWcore/http/auth/middleware_test.go211 user := createTestUser(db, "user@example.com", auth.RoleUser, auth.ProviderGitHub)
LOWcore/http/auth/middleware_test.go220 user := createTestUser(db, "user@example.com", auth.RoleUser, auth.ProviderGitHub)
LOWcore/http/auth/roles_test.go35 role := auth.AssignRole(db, "admin@example.com", "admin@example.com")
LOWcore/http/auth/roles_test.go42 role := auth.AssignRole(db, "Admin@Example.COM", "admin@example.com")
LOWcore/http/auth/roles_test.go49 role := auth.AssignRole(db, "other@example.com", "admin@example.com")
LOWcore/http/auth/roles_test.go69 user := createTestUser(db, "user@example.com", auth.RoleUser, auth.ProviderGitHub)
LOWcore/http/auth/roles_test.go71 promoted := auth.MaybePromote(db, user, "admin@example.com")
LOWcore/http/auth/roles_test.go77 user := createTestUser(db, "admin@example.com", auth.RoleAdmin, auth.ProviderGitHub)
LOWcore/http/auth/oauth_email_decision_test.go13 Expect(emailForRoleDecision("admin@example.com", true)).
LOWcore/http/auth/oauth_email_decision_test.go14 To(Equal("admin@example.com"))
LOWcore/http/auth/oauth_email_decision_test.go18 Expect(emailForRoleDecision("admin@example.com", false)).
LOWcore/http/auth/oauth_email_decision_test.go46 role := AssignRole(db, emailForRoleDecision("admin@example.com", false), "admin@example.com")
LOWcore/http/auth/oauth_email_decision_test.go52 role := AssignRole(db, emailForRoleDecision("admin@example.com", true), "admin@example.com")
LOWcore/http/routes/auth_test.go1037 admin := createRouteTestUser(db, "admin@example.com", auth.RoleAdmin)
LOWcore/http/routes/auth_test.go1062 admin := createRouteTestUser(db, "admin@example.com", auth.RoleAdmin)
LOWpkg/functions/parse_test.go2290 Arguments: `{"name":"John Doe","age":30,"active":true,"score":95.5}`,
Verbosity Indicators20 hits · 30 pts
SeverityFileLineSnippet
LOWcore/gallery/upgrade.go286 // Step 1: Download the new backend into the tmp directory
LOWcore/gallery/upgrade.go304 // Step 2: Validate — check that run.sh exists in the new content
LOWcore/gallery/upgrade.go311 // Step 3: Atomic swap — rename current to backup, then tmp to current
LOWcore/gallery/upgrade.go327 // Step 4: Write updated metadata, preserving alias from old metadata
LOWcore/gallery/upgrade.go360 // Step 5: Re-register backends so the model loader picks up any changes
LOWcore/gallery/upgrade.go365 // Step 6: Remove backup
LOWcore/gallery/backends.go445 // if doesn't exist, it might be an alias, so we need to check if we have a matching alias in
LOWcore/application/startup.go521// Since env vars are applied via AppOptions in run.go, we need to check if they're set.
LOWcore/services/nodes/router_test.go739 // Step 1: cached model found on old node
LOWcore/services/nodes/router.go243 // Step 1: Find and atomically lock a node with this model loaded
LOWcore/services/nodes/router.go288 // Step 2: Model not loaded — schedule loading with distributed lock to prevent duplicates
LOWbackend/python/llama-cpp-quantization/backend.py101 # Step 1: Download / resolve model
LOWbackend/python/llama-cpp-quantization/backend.py112 # Step 2: Convert to f16 GGUF
LOWbackend/python/llama-cpp-quantization/backend.py123 # Step 3: Quantize
LOWbackend/python/trl/backend.py740 # Step 1: Merge LoRA into base model
LOWbackend/python/trl/backend.py789 # Step 2: Convert to GGUF using convert_hf_to_gguf.py
LOWpkg/functions/parse_test.go191 // Step 1: Replace single quotes around keys and values with double quotes
LOWpkg/functions/parse_test.go193 // Step 2: Replace double quotes inside values with placeholders
LOWpkg/functions/parse_test.go224 // Step 1: Replace single quotes around keys and values with double quotes
LOWpkg/functions/parse_test.go226 // Step 2: Replace double quotes inside values with placeholders
Hallucination Indicators3 hits · 30 pts
SeverityFileLineSnippet
CRITICALcore/http/static/assets/marked.js6!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?def
CRITICALcore/http/static/assets/codemirror.min.js1!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define
CRITICALbackend/cpp/llama-cpp/grpc-server.cpp1370 if (params.speculative.has_dft() && !params.speculative.draft.mparams.path.empty()) {
Magic Placeholder Names6 hits · 30 pts
SeverityFileLineSnippet
HIGHcore/http/views/agent-task-details.html373 -H "Authorization: Bearer YOUR_API_KEY" \
HIGHcore/http/views/agent-task-details.html394 -H "Authorization: Bearer YOUR_API_KEY" \
HIGHcore/http/views/agent-task-details.html417 -H "Authorization: Bearer YOUR_API_KEY" \
HIGHcore/http/views/agent-task-details.html443 -H "Authorization: Bearer YOUR_API_KEY"</code></pre>
HIGHdocs/content/features/mcp.md417 api_key="your-api-key"
HIGHdocs/content/getting-started/troubleshooting.md275 -H "Authorization: Bearer YOUR_API_KEY"
Docstring Block Structure3 hits · 15 pts
SeverityFileLineSnippet
HIGHbackend/python/diffusers/diffusers_dynamic_loader.py128 Discover all subclasses of a given base class from diffusers. This function provides a generic way to discover
HIGHbackend/python/diffusers/diffusers_dynamic_loader.py318 Resolve a pipeline class from class_name, task, or model_id. Priority: 1. If class_name is provided, look
HIGHbackend/python/diffusers/diffusers_dynamic_loader.py428 Load a diffusers pipeline dynamically. This function resolves the appropriate pipeline class based on the prov
Dead Code5 hits · 10 pts
SeverityFileLineSnippet
MEDIUMbackend/python/mlx-distributed/backend.py604
MEDIUMbackend/python/mlx-distributed/backend.py605
MEDIUMbackend/python/mlx-distributed/backend.py609
MEDIUMbackend/python/mlx-distributed/backend.py614
MEDIUMbackend/python/mlx-distributed/backend.py616
Slop Phrases2 hits · 4 pts
SeverityFileLineSnippet
MEDIUMpkg/huggingface-api/client_test.go610 mockReadmeContent := "# Test Model\n\nThis is a test model for demonstration purposes."
MEDIUMpkg/huggingface-api/client_test.go629 Expect(content).To(Equal("# Test Model\n\nThis is a test model for demonstration purposes."))
Example Usage Blocks3 hits · 4 pts
SeverityFileLineSnippet
LOWdocker-compose.distributed.yaml9# Usage:
LOWscripts/model_gallery_info.py53# Example usage
LOWpkg/model/watchdog.go63// Example usage: