AI Slop Code RIsk Monitor

OpenByteInc/QuantDinger

Open-source AI Trading OS, agent trading, and vibe trading, with Jev System One integration. Research, build Python strategies, backtest, and paper/live trade across crypto, stocks, and forex. Launch your own multi-tenant trading SaaS with built-in user management, billing, payments, and settlement.

32.0 High pattern signal View on GitHub

Maintenance and Governance Review

This report summarizes scanner evidence for OpenByteInc/QuantDinger, a Python project with 12,666 GitHub stars. SynthScan examined 265,023 lines of code across 998 source files, recording 7112 pattern matches distributed across 20 syntactic categories. The legacy adjusted pattern signal is 32.0 (High pattern signal); it is not an authorship estimate.

Use the findings to ask whether maintainers can explain intent, verify dependencies, simplify unnecessary scaffolding, and focus review effort. Risk Payload v1 adds ownership, supply-chain, over-engineering, and review-effort vectors when available. These are prompts for human verification, not probabilities, security findings, or measured maintenance costs.

32.0
Adjusted Signal
32.0
Raw Pattern Score
100%
Time Factor
2026-10-09
Last Push
12.7K
Stars
Python
Language
265.0K
Lines of Code
998
Files
7.1K
Pattern Hits
2026-10-12
Scan Date
0.26
HC Hit Rate

Risk Review · v3

Use each vector to guide manual verification of the underlying findings.

Cognitive Ownership Risk 51.0/100 · HIGH

Can maintainers explain intent, assumptions, and trade-offs? 3786 finding(s).

Hallucinated Dependency & Supply Chain Risk 13.0/100 · LOW

Are imports declared and package/API names verified? 773 finding(s).

Agent Over-Engineering Ratio 74.6/100 · HIGH

Are wrappers, guards, and repeated structures necessary? 5858 finding(s).

PR Review Velocity Impact 81.9/100 · CRITICAL

Which changes need focused human review? 7112 finding(s).

What These Metrics Mean

Adjusted Signal
Legacy pattern score normalized per 1,000 scanned lines and multiplied by the repository-level time factor. It is not an estimate of AI authorship.
Raw Pattern Score
Sum of severity- and context-weighted pattern findings before applying the time factor.
Time Factor
A coarse multiplier based on repository last-push metadata. It does not identify when individual code was written.
Pattern Hits
Count of configured pattern findings. Review each location and surrounding code before acting.
HC Hit Rate
High- and critical-severity findings per scanned file. Severity is a configured detector weight, not proof of a vulnerability or authorship.
Lines / Files
Scan coverage denominators used by the legacy normalized score.

Pattern-Signal History

This chart tracks the legacy adjusted pattern score across scan runs. Changes can reflect source changes, scan coverage, or detector/scoring versions; they do not measure AI adoption or prove that a team refactored code. Compare runs only when their scoring versions are compatible. The dashed line tracks the raw pattern-hit count.

Severity Breakdown

Groups findings by configured severity weight. Severity is not a confidence estimate, security rating, or proof that a package is missing. Verify imports against the project's manifests and inspect each finding in its local design context.

CRITICAL 0HIGH 260MEDIUM 323LOW 6529

Directory Score Breakdown

This horizontal bar chart shows where configured pattern scores accumulate across directories. Treat the bars as locations to inspect, not as evidence of authorship or code quality. Use the file-level findings to decide whether a directory needs a focused ownership, dependency, complexity, or review check.

Pattern Findings

The scanner identified 7112 distinct pattern matches across 20 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a detector match to inspect in context. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.

Reading the findings table: The Severity column indicates the configured finding weight (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — legacy comment-context matches receive a ×1.5 score weight. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier under the legacy scoring model.

Hyper-Verbose Identifiers3282 hits · 3290 pts
SeverityFileLineSnippetContext
LOWmcp_server/tests/test_transport_resolution.py39def test_transport_default_is_stdio(monkeypatch, fresh_module):CODE
LOW⚡mcp_server/tests/test_transport_resolution.py56def test_transport_aliases_resolve(monkeypatch, fresh_module, raw, expected):CODE
LOW⚡mcp_server/tests/test_transport_resolution.py61def test_transport_unknown_exits(monkeypatch, fresh_module):CODE
LOW⚡mcp_server/tests/test_transport_resolution.py67def test_apply_http_settings_without_error(monkeypatch, fresh_module):CODE
LOW⚡mcp_server/tests/test_transport_resolution.py78def test_non_loopback_http_requires_auth(monkeypatch, fresh_module):CODE
LOW⚡mcp_server/tests/test_transport_resolution.py86def test_non_loopback_http_accepts_distinct_strong_auth(monkeypatch, fresh_module):CODE
LOW⚡mcp_server/tests/test_transport_resolution.py94def test_non_loopback_authenticated_http_requires_https(monkeypatch, fresh_module):CODE
LOW⚡mcp_server/tests/test_transport_resolution.py104def test_invalid_numeric_env_uses_default(monkeypatch, fresh_module):CODE
LOW⚡mcp_server/tests/test_security_and_tools.py32def test_mcp_tool_registry_complete(fresh_module):CODE
LOW⚡mcp_server/tests/test_security_and_tools.py39def test_gateway_tools_do_not_advertise_an_inferred_result_wrapper(fresh_module):CODE
LOW⚡mcp_server/tests/test_security_and_tools.py46def test_success_payload_is_preserved_without_a_result_wrapper(monkeypatch, fresh_module, body):CODE
LOW⚡mcp_server/tests/test_security_and_tools.py53def test_health_failures_set_protocol_error(fresh_module, monkeypatch, failure):CODE
LOW⚡mcp_server/tests/test_security_and_tools.py135def test_protocol_guard_denial_and_error_redaction(monkeypatch, fresh_module):CODE
LOW⚡mcp_server/tests/test_security_and_tools.py145def test_successful_empty_snapshot_is_not_an_error(monkeypatch, fresh_module):CODE
LOW⚡mcp_server/tests/test_security_and_tools.py153def test_strategy_authoring_contract_uses_agent_gateway(monkeypatch, fresh_module):CODE
LOW⚡mcp_server/tests/test_security_and_tools.py165def test_package_version_matches_pyproject():CODE
LOW⚡mcp_server/tests/test_security_and_tools.py175def test_protocol_server_version_matches_package(fresh_module):CODE
LOW⚡mcp_server/tests/test_security_and_tools.py181def test_create_strategy_uses_canonical_deployment_payload(monkeypatch, fresh_module):CODE
LOW⚡mcp_server/tests/test_security_and_tools.py246def test_stop_strategy_requires_confirmation(fresh_module):CODE
LOW⚡mcp_server/tests/test_security_and_tools.py252def test_place_quick_order_requires_confirmation(fresh_module):CODE
LOW⚡mcp_server/tests/test_security_and_tools.py258def test_indicator_code_size_rejected_in_mcp(monkeypatch, fresh_module):CODE
LOWmcp_server/tests/test_security_and_tools.py74def test_health_success_stays_success(fresh_module, monkeypatch):CODE
LOWmcp_server/tests/test_security_and_tools.py85def test_mcp_tools_are_actually_registered(fresh_module):CODE
LOWmcp_server/tests/test_security_and_tools.py90def test_every_tool_has_explicit_risk_annotations(fresh_module):CODE
LOWmcp_server/tests/test_security_and_tools.py111def test_protocol_marks_gateway_and_business_failures(monkeypatch, fresh_module, status, body):CODE
LOWmcp_server/tests/test_security_and_tools.py124def test_protocol_marks_transport_failures(monkeypatch, fresh_module, exception_type):CODE
LOWmcp_server/tests/test_security_and_tools.py220def test_quick_order_forwards_native_protection(monkeypatch, fresh_module):CODE
LOWmcp_server/tests/test_security_and_tools.py294def test_strategy_source_workspace_payloads(monkeypatch, fresh_module):CODE
LOWmcp_server/tests/test_security_and_tools.py337def test_source_restore_and_paper_cancel_require_confirmation(fresh_module):CODE
LOWmcp_server/tests/test_security_and_tools.py357def test_redaction_handles_camel_case_and_deep_values():CODE
LOWmcp_server/src/quantdinger_mcp/server.py558def get_indicator_authoring_contract() -> Any:CODE
LOWmcp_server/src/quantdinger_mcp/server.py679def get_strategy_authoring_contract() -> Any:CODE
LOWmcp_server/src/quantdinger_mcp/server.py754def list_strategy_source_versions(source_id: int) -> Any:CODE
LOWmcp_server/src/quantdinger_mcp/server.py760def restore_strategy_source_version(CODE
LOWmcp_server/src/quantdinger_mcp/server.py992def list_strategy_pending_orders(strategy_id: int, limit: int = 50, cursor: int = 0) -> Any:CODE
LOW⚡mcp_server/src/quantdinger_mcp/server.py1103def _apply_http_settings_from_env() -> None:CODE
LOW⚡mcp_server/src/quantdinger_mcp/server.py1124def _validate_network_security(transport: str) -> None:CODE
LOWmcp_server/src/quantdinger_mcp/security.py31def assert_indicator_code_size(code: str) -> None:CODE
LOW⚡backend_api_python/app/startup.py74def start_pending_order_worker():CODE
LOW⚡backend_api_python/app/startup.py99def start_execution_stream_supervisor():CODE
LOW⚡backend_api_python/app/startup.py190def _schedule_post_restore_position_sync() -> None:CODE
LOW⚡backend_api_python/app/startup.py261def _start_scheduler_services(*, include_celery_managed: bool = False) -> None:CODE
LOWbackend_api_python/app/startup.py46def get_execution_stream_supervisor():CODE
LOWbackend_api_python/app/startup.py55def _is_debug_reloader_parent() -> bool:CODE
LOWbackend_api_python/app/startup.py144def restore_running_strategies():CODE
LOWbackend_api_python/app/startup.py239def _start_trading_support_services(*, lease_guard=None) -> None:CODE
LOWbackend_api_python/app/startup.py250def stop_trading_support_services() -> None:CODE
LOWbackend_api_python/app/config/redis_urls.py38def celery_result_backend_url() -> str:CODE
LOWbackend_api_python/app/runtime/roles.py29def strategy_commands_enabled() -> bool:CODE
LOWbackend_api_python/app/utils/auth.py23def _configure_jwt_secret_warnings() -> None:CODE
LOWbackend_api_python/app/utils/db.py107def _resolve_market_symbols_sql_path() -> Path:CODE
LOWbackend_api_python/app/utils/db.py111def _resolve_strategy_templates_sql_path() -> Path:CODE
LOWbackend_api_python/app/utils/db.py124def _migration_timeout_seconds(name: str, default: int) -> int:STRING
LOWbackend_api_python/app/utils/db.py181def _apply_migration_component(STRING
LOW⚡backend_api_python/app/utils/local_brokers.py8def local_desktop_brokers_allowed() -> bool:CODE
LOW⚡backend_api_python/app/utils/local_brokers.py14def desktop_broker_cloud_reject_message() -> str:CODE
LOW⚡backend_api_python/app/utils/local_brokers.py22def require_local_desktop_brokers_allowed() -> None:CODE
LOWbackend_api_python/app/utils/trade_execution.py7def enrich_execution_reference(row):CODE
LOWbackend_api_python/app/utils/safe_exec.py190def _dangerous_pd_numpy_import(name: str) -> Optional[str]:CODE
LOWbackend_api_python/app/utils/safe_exec.py394def _assign_windows_process_memory_job(proc: Any, max_memory_mb: int) -> Any:CODE
3222 more matches not shown…
Excessive Try-Catch Wrapping1978 hits · 1838 pts
SeverityFileLineSnippetContext
LOWscripts/check_version.py39 except Exception:CODE
LOWmcp_server/src/quantdinger_mcp/server.py226 except Exception:CODE
LOW⚡mcp_server/src/quantdinger_mcp/server.py1112 except Exception:CODE
LOW⚡mcp_server/src/quantdinger_mcp/server.py1117 except Exception:CODE
LOWmcp_server/src/quantdinger_mcp/security.py84 except Exception:CODE
LOWmcp_server/src/quantdinger_mcp/security.py109 except Exception:CODE
LOWbackend_api_python/run.py14except Exception:CODE
LOWbackend_api_python/run.py28except Exception:CODE
LOWbackend_api_python/env_sync_core.py88 except Exception:CODE
LOW⚡backend_api_python/app/startup.py70 except Exception as e:CODE
LOW⚡backend_api_python/app/startup.py81 except Exception as e:CODE
LOW⚡backend_api_python/app/startup.py95 except Exception as e:CODE
LOW⚡backend_api_python/app/startup.py103 except Exception as e:CODE
LOW⚡backend_api_python/app/startup.py177 except Exception as e:CODE
LOW⚡backend_api_python/app/startup.py179 except Exception as e:CODE
LOW⚡backend_api_python/app/startup.py185 except Exception as e:CODE
LOW⚡backend_api_python/app/startup.py196 except Exception:CODE
LOW⚡backend_api_python/app/startup.py269 except Exception:CODE
LOW⚡backend_api_python/app/startup.py276 except Exception:CODE
LOW⚡backend_api_python/app/startup.py285 except Exception:CODE
LOW⚡backend_api_python/app/startup.py291 except Exception:CODE
LOWbackend_api_python/app/startup.py140 except Exception as e:CODE
LOWbackend_api_python/app/startup.py207 except Exception as exc:CODE
LOWbackend_api_python/app/_version.py66 except Exception:CODE
LOWbackend_api_python/app/__init__.py21except Exception:CODE
LOWbackend_api_python/app/__init__.py105 except Exception as exc:CODE
LOWbackend_api_python/app/__init__.py126 except Exception as sample_exc:CODE
LOWbackend_api_python/app/__init__.py128 except Exception as e:CODE
MEDIUMbackend_api_python/app/__init__.py100def _configure_ibkr_asyncio() -> None:CODE
MEDIUMbackend_api_python/app/__init__.py109def _bootstrap_database() -> None:CODE
LOWbackend_api_python/app/tasks/agent_jobs.py76 except Exception as exc:CODE
LOWbackend_api_python/app/utils/json_helpers.py18 except Exception:CODE
LOWbackend_api_python/app/utils/auth.py84 except Exception as e:CODE
LOWbackend_api_python/app/utils/auth.py193 except Exception as e:CODE
LOWbackend_api_python/app/utils/db.py235 except Exception:STRING
LOWbackend_api_python/app/utils/db.py238 except Exception:STRING
LOWbackend_api_python/app/utils/db.py344 except Exception as exc:STRING
LOWbackend_api_python/app/utils/db.py371 except Exception as exc:STRING
LOWbackend_api_python/app/utils/db.py377 except Exception as exc:STRING
LOWbackend_api_python/app/utils/config_loader.py34 except Exception as e:CODE
LOWbackend_api_python/app/utils/config_loader.py229 except Exception as e:CODE
LOWbackend_api_python/app/utils/config_loader.py311 except Exception as e:CODE
LOWbackend_api_python/app/utils/request_guard.py37 except Exception:CODE
LOWbackend_api_python/app/utils/request_guard.py107 except Exception:CODE
LOWbackend_api_python/app/utils/request_guard.py129 except Exception:CODE
LOWbackend_api_python/app/utils/timeutil.py29except Exception: # pragma: no cover - fallback for very old runtimesCODE
LOWbackend_api_python/app/utils/timeutil.py45 except Exception:CODE
LOWbackend_api_python/app/utils/timeutil.py80 except Exception:CODE
LOWbackend_api_python/app/utils/timeutil.py95 except Exception:CODE
LOWbackend_api_python/app/utils/safe_exec.py387 except Exception as exc:CODE
LOWbackend_api_python/app/utils/safe_exec.py569 except Exception as e:CODE
LOWbackend_api_python/app/utils/safe_exec.py622 except Exception as e:CODE
LOWbackend_api_python/app/utils/safe_exec.py1150 except Exception as e:CODE
LOWbackend_api_python/app/utils/cache.py90 except Exception as e:CODE
LOW⚡backend_api_python/app/utils/cache.py103 except Exception as e:CODE
LOW⚡backend_api_python/app/utils/cache.py111 except Exception as e:CODE
LOW⚡backend_api_python/app/utils/cache.py118 except Exception as e:CODE
LOWbackend_api_python/app/utils/trade_close_reason.py199 except Exception:CODE
LOW⚡backend_api_python/app/utils/trade_net_pnl.py39 except Exception:CODE
LOW⚡backend_api_python/app/utils/trade_net_pnl.py45 except Exception:CODE
1918 more matches not shown…
Empty Error Handlers243 hits · 1215 pts
SeverityFileLineSnippetContext
HIGHmcp_server/src/quantdinger_mcp/server.py1112except Exception:CODE
HIGHbackend_api_python/run.py14except Exception:CODE
HIGHbackend_api_python/run.py28except Exception:CODE
HIGHbackend_api_python/env_sync_core.py91except FileNotFoundError:CODE
HIGHbackend_api_python/app/__init__.py21except Exception:CODE
HIGHbackend_api_python/app/utils/db.py238except Exception:CODE
HIGHbackend_api_python/app/utils/request_guard.py107except Exception:CODE
HIGHbackend_api_python/app/utils/timeutil.py45except Exception:CODE
HIGHbackend_api_python/app/utils/safe_exec.py484except ValueError:CODE
HIGHbackend_api_python/app/utils/trade_net_pnl.py178except Exception:CODE
HIGHbackend_api_python/app/utils/trade_net_pnl.py197except Exception:CODE
HIGHbackend_api_python/app/utils/db_postgres.py212except Exception:CODE
HIGHbackend_api_python/app/utils/db_postgres.py206except Exception:CODE
HIGHbackend_api_python/app/utils/db_postgres.py249except Exception:CODE
HIGHbackend_api_python/app/utils/db_postgres.py421except Exception:CODE
HIGHbackend_api_python/app/utils/db_postgres.py777except Exception:CODE
HIGHbackend_api_python/app/utils/db_postgres.py541except Exception:CODE
HIGHbackend_api_python/app/utils/db_postgres.py762except Exception:CODE
HIGHbackend_api_python/app/utils/db_postgres.py546except Exception:CODE
HIGHbackend_api_python/app/utils/db_postgres.py563except Exception:CODE
HIGHbackend_api_python/app/utils/agent_auth.py302except RuntimeError:CODE
HIGHbackend_api_python/app/utils/safe_exec_worker.py155except Exception:CODE
HIGHbackend_api_python/app/professional_report/snapshot.py31except (OverflowError, OSError, ValueError):CODE
HIGHbackend_api_python/app/professional_report/snapshot.py48except ValueError:CODE
HIGHbackend_api_python/app/data_providers/heatmap.py180except Exception:CODE
HIGHbackend_api_python/app/data_providers/hk_research.py48except Exception:CODE
HIGHbackend_api_python/app/data_providers/hk_research.py53except Exception:CODE
HIGHbackend_api_python/app/data_providers/hk_research.py58except Exception:CODE
HIGHbackend_api_python/app/data_providers/hk_research.py89except Exception:CODE
HIGHbackend_api_python/app/data_providers/__init__.py326except Exception:CODE
HIGHbackend_api_python/app/data_providers/us_research.py274except Exception:CODE
HIGHbackend_api_python/app/data_providers/commodities.py92except Exception:CODE
HIGHbackend_api_python/app/data_providers/news.py43except Exception:CODE
HIGHbackend_api_python/app/data_providers/news.py56except Exception:CODE
HIGH…kend_api_python/app/data_sources/cn_hk_fundamentals.py687except ImportError:CODE
HIGHbackend_api_python/app/data_sources/forex.py76except Exception:CODE
HIGHbackend_api_python/app/data_sources/forex.py266except Exception:CODE
HIGHbackend_api_python/app/data_sources/futures.py44except Exception:CODE
HIGHbackend_api_python/app/data_sources/crypto.py684except Exception:CODE
HIGHbackend_api_python/app/data_sources/tencent.py92except Exception:CODE
HIGHbackend_api_python/app/data_sources/asia_stock_kline.py136except Exception:CODE
HIGHbackend_api_python/app/routes/auth.py782except (ValueError, TypeError):CODE
HIGHbackend_api_python/app/routes/auth.py447except (ValueError, TypeError):CODE
HIGHbackend_api_python/app/routes/user.py1035except Exception:CODE
HIGHbackend_api_python/app/routes/user.py1395except (TypeError, ValueError):CODE
HIGHbackend_api_python/app/routes/quick_trade.py754except Exception:CODE
HIGHbackend_api_python/app/routes/quick_trade.py156except Exception:CODE
HIGHbackend_api_python/app/routes/quick_trade.py206except Exception:CODE
HIGHbackend_api_python/app/routes/ai_chat.py824except Exception:CODE
HIGHbackend_api_python/app/routes/ai_chat.py889except (TypeError, ValueError, OSError, OverflowError):CODE
HIGHbackend_api_python/app/routes/ai_chat.py1852except Exception:CODE
HIGHbackend_api_python/app/routes/ai_chat.py3323except Exception:CODE
HIGHbackend_api_python/app/routes/ai_chat.py3329except Exception:CODE
HIGHbackend_api_python/app/routes/strategy_notifications.py96except Exception:CODE
HIGHbackend_api_python/app/routes/dashboard.py497except Exception:CODE
HIGHbackend_api_python/app/routes/dashboard.py596except Exception:CODE
HIGHbackend_api_python/app/routes/dashboard.py742except Exception:CODE
HIGHbackend_api_python/app/routes/fast_analysis.py302except Exception:CODE
HIGHbackend_api_python/app/routes/fast_analysis.py285except Exception:CODE
HIGHbackend_api_python/app/routes/fast_analysis.py290except Exception:CODE
183 more matches not shown…
Decorative Section Separators214 hits · 736 pts
SeverityFileLineSnippetContext
MEDIUMdocker-compose.yml93 # ========================COMMENT
MEDIUMdocker-compose.yml95 # ========================COMMENT
MEDIUMdocker-compose.yml127 # ========================COMMENT
MEDIUMdocker-compose.yml129 # ========================COMMENT
MEDIUMdocker-compose.yml257 # ========================COMMENT
MEDIUMdocker-compose.yml259 # ========================COMMENT
MEDIUMdocker-compose.yml610 # ========================COMMENT
MEDIUMdocker-compose.yml612 # ========================COMMENT
MEDIUMdocker-compose.yml646 # ========================COMMENT
MEDIUMdocker-compose.yml648 # ========================COMMENT
MEDIUMdocs/deployment/NOTIFICATION_SMS_CONFIG_CN.md93# =========================COMMENT
MEDIUMdocs/deployment/NOTIFICATION_SMS_CONFIG_CN.md95# =========================COMMENT
MEDIUM⚡docs/deployment/NOTIFICATION_EMAIL_CONFIG_EN.md72# =========================COMMENT
MEDIUM⚡docs/deployment/NOTIFICATION_EMAIL_CONFIG_EN.md74# =========================COMMENT
MEDIUM⚡docs/deployment/NOTIFICATION_SMS_CONFIG_EN.md92# =========================COMMENT
MEDIUM⚡docs/deployment/NOTIFICATION_SMS_CONFIG_EN.md94# =========================COMMENT
MEDIUMdocs/deployment/NOTIFICATION_EMAIL_CONFIG_CN.md74# =========================COMMENT
MEDIUMdocs/deployment/NOTIFICATION_EMAIL_CONFIG_CN.md76# =========================COMMENT
MEDIUMbackend_api_python/app/utils/agent_jobs.py283# ──────────────────────────── progress / streaming ────────────────────────────COMMENT
MEDIUMbackend_api_python/app/utils/agent_auth.py350# ─────────────────────────── verification ───────────────────────────COMMENT
MEDIUMbackend_api_python/app/utils/agent_auth.py393# ─────────────────────────── audit ───────────────────────────COMMENT
MEDIUMbackend_api_python/app/utils/agent_auth.py483# ─────────────────────────── decorator ───────────────────────────COMMENT
MEDIUMbackend_api_python/app/utils/agent_auth.py739# ─────────────────────────── idempotency ───────────────────────────COMMENT
MEDIUMbackend_api_python/app/utils/agent_auth.py776# ─────────────────────────── helpers for routes ───────────────────────────COMMENT
MEDIUMbackend_api_python/app/utils/agent_auth.py202# ─────────────────────────── token primitives ───────────────────────────STRING
MEDIUMbackend_api_python/app/utils/agent_auth.py245# ─────────────────────────── distributed rate limit ───────────────────────────STRING
MEDIUMbackend_api_python/app/data_providers/__init__.py38# ---------------------------------------------------------------------------COMMENT
MEDIUMbackend_api_python/app/data_providers/__init__.py45# ---------------------------------------------------------------------------COMMENT
MEDIUMbackend_api_python/app/data_providers/__init__.py79# ---------------------------------------------------------------------------COMMENT
MEDIUMbackend_api_python/app/data_providers/__init__.py81# ---------------------------------------------------------------------------COMMENT
MEDIUMbackend_api_python/app/data_providers/__init__.py154# ---------------------------------------------------------------------------COMMENT
MEDIUMbackend_api_python/app/data_providers/__init__.py156# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡backend_api_python/app/data_providers/opportunities.py232# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡backend_api_python/app/data_providers/opportunities.py234# ---------------------------------------------------------------------------COMMENT
MEDIUMbackend_api_python/app/data_providers/opportunities.py18# ---------------------------------------------------------------------------COMMENT
MEDIUMbackend_api_python/app/data_providers/opportunities.py20# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡…kend_api_python/app/data_sources/cn_hk_fundamentals.py520# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡…kend_api_python/app/data_sources/cn_hk_fundamentals.py522# ---------------------------------------------------------------------------COMMENT
MEDIUM…kend_api_python/app/data_sources/cn_hk_fundamentals.py99# ---------------------------------------------------------------------------COMMENT
MEDIUM…kend_api_python/app/data_sources/cn_hk_fundamentals.py101# ---------------------------------------------------------------------------COMMENT
MEDIUM…kend_api_python/app/data_sources/cn_hk_fundamentals.py373# ---------------------------------------------------------------------------COMMENT
MEDIUM…kend_api_python/app/data_sources/cn_hk_fundamentals.py375# ---------------------------------------------------------------------------COMMENT
MEDIUMbackend_api_python/app/data_sources/forex.py39# ---------------------------------------------------------------------------COMMENT
MEDIUMbackend_api_python/app/data_sources/forex.py41# ---------------------------------------------------------------------------COMMENT
MEDIUMbackend_api_python/app/data_sources/cache_manager.py172# ============================================COMMENT
MEDIUMbackend_api_python/app/data_sources/cache_manager.py173# ============================================COMMENT
MEDIUMbackend_api_python/app/data_sources/futures.py21# ---------------------------------------------------------------------------COMMENT
MEDIUMbackend_api_python/app/data_sources/futures.py23# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡backend_api_python/app/data_sources/circuit_breaker.py152# ============================================COMMENT
MEDIUM⚡backend_api_python/app/data_sources/circuit_breaker.py153# ============================================COMMENT
MEDIUM⚡backend_api_python/app/data_sources/asia_stock_kline.py104# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡backend_api_python/app/data_sources/asia_stock_kline.py106# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡backend_api_python/app/data_sources/asia_stock_kline.py126# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡backend_api_python/app/data_sources/asia_stock_kline.py128# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡backend_api_python/app/data_sources/asia_stock_kline.py324# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡backend_api_python/app/data_sources/asia_stock_kline.py326# ---------------------------------------------------------------------------COMMENT
MEDIUMbackend_api_python/app/data_sources/asia_stock_kline.py486# ---------------------------------------------------------------------------COMMENT
MEDIUMbackend_api_python/app/data_sources/asia_stock_kline.py488# ---------------------------------------------------------------------------COMMENT
MEDIUM⚡backend_api_python/app/routes/auth.py140# =============================================================================COMMENT
MEDIUM⚡backend_api_python/app/routes/auth.py142# =============================================================================COMMENT
154 more matches not shown…
Unused Imports758 hits · 704 pts
SeverityFileLineSnippetContext
LOWscripts/sync_env.py4CODE
LOWscripts/sync_env.py14CODE
LOWscripts/check_mojibake.py9CODE
LOWscripts/check_docs.py4CODE
LOWscripts/bump_version.py12CODE
LOWscripts/check_version.py12CODE
LOWmcp_server/tests/test_transport_resolution.py11CODE
LOWmcp_server/src/quantdinger_mcp/server.py7CODE
LOWmcp_server/src/quantdinger_mcp/security.py2CODE
LOWmcp_server/src/quantdinger_mcp/tool_contract.py4CODE
LOWbackend_api_python/env_sync_core.py3CODE
LOWbackend_api_python/app/startup.py2CODE
LOWbackend_api_python/app/_version.py8CODE
LOWbackend_api_python/app/celery_app.py3CODE
LOWbackend_api_python/app/__init__.py2CODE
LOWbackend_api_python/app/__init__.py28CODE
LOWbackend_api_python/app/__init__.py28CODE
LOWbackend_api_python/app/tasks/maintenance.py3CODE
LOWbackend_api_python/app/tasks/agent_jobs.py3CODE
LOWbackend_api_python/app/tasks/fast_analysis.py3CODE
LOWbackend_api_python/app/config/__init__.py2CODE
LOWbackend_api_python/app/config/__init__.py3CODE
LOWbackend_api_python/app/config/__init__.py4CODE
LOWbackend_api_python/app/config/__init__.py4CODE
LOWbackend_api_python/app/config/__init__.py5CODE
LOWbackend_api_python/app/config/__init__.py5CODE
LOWbackend_api_python/app/config/__init__.py5CODE
LOWbackend_api_python/app/config/__init__.py5CODE
LOWbackend_api_python/app/config/__init__.py5CODE
LOWbackend_api_python/app/config/__init__.py5CODE
LOWbackend_api_python/app/config/__init__.py5CODE
LOWbackend_api_python/app/config/redis_urls.py3CODE
LOWbackend_api_python/app/runtime/roles.py3CODE
LOWbackend_api_python/app/runtime/__init__.py3CODE
LOWbackend_api_python/app/runtime/__init__.py3CODE
LOWbackend_api_python/app/runtime/process.py3CODE
LOWbackend_api_python/app/utils/json_helpers.py3CODE
LOWbackend_api_python/app/utils/db.py24CODE
LOWbackend_api_python/app/utils/db.py24CODE
LOWbackend_api_python/app/utils/db.py24CODE
LOWbackend_api_python/app/utils/local_brokers.py3CODE
LOWbackend_api_python/app/utils/request_guard.py3CODE
LOWbackend_api_python/app/utils/notification_display.py6CODE
LOWbackend_api_python/app/utils/timeutil.py21CODE
LOWbackend_api_python/app/utils/market_visibility.py27CODE
LOWbackend_api_python/app/utils/technical_indicators.py8CODE
LOWbackend_api_python/app/utils/technical_indicators.py12CODE
LOWbackend_api_python/app/utils/__init__.py4CODE
LOWbackend_api_python/app/utils/__init__.py5CODE
LOWbackend_api_python/app/utils/__init__.py6CODE
LOWbackend_api_python/app/utils/trade_close_reason.py6CODE
LOWbackend_api_python/app/utils/trade_net_pnl.py10CODE
LOWbackend_api_python/app/utils/agent_jobs.py19CODE
LOWbackend_api_python/app/utils/resource_guard.py8CODE
LOWbackend_api_python/app/utils/logger.py3CODE
LOWbackend_api_python/app/utils/broker_session.py19CODE
LOWbackend_api_python/app/utils/numeric_precision.py3CODE
LOWbackend_api_python/app/utils/credential_crypto.py8CODE
LOWbackend_api_python/app/utils/language.py8CODE
LOWbackend_api_python/app/utils/strategy_runtime_logs.py3CODE
698 more matches not shown…
Deep Nesting381 hits · 292 pts
SeverityFileLineSnippetContext
LOWscripts/check_mojibake.py80CODE
LOWscripts/check_docs.py49CODE
LOWmcp_server/src/quantdinger_mcp/security.py43CODE
LOWmcp_server/src/quantdinger_mcp/security.py90CODE
LOWbackend_api_python/app/startup.py144CODE
LOWbackend_api_python/app/utils/db.py355CODE
LOWbackend_api_python/app/utils/config_loader.py236CODE
LOWbackend_api_python/app/utils/request_guard.py55CODE
LOWbackend_api_python/app/utils/timeutil.py50CODE
LOWbackend_api_python/app/utils/safe_exec.py863CODE
LOWbackend_api_python/app/utils/safe_exec.py1067CODE
LOWbackend_api_python/app/utils/safe_exec.py346CODE
LOWbackend_api_python/app/utils/agent_jobs.py81CODE
LOWbackend_api_python/app/utils/agent_jobs.py333CODE
LOWbackend_api_python/app/utils/db_postgres.py496CODE
LOWbackend_api_python/app/utils/agent_auth.py49CODE
LOWbackend_api_python/app/observability/metrics.py72CODE
LOWbackend_api_python/app/openapi/register.py134CODE
LOWbackend_api_python/app/openapi/register.py169CODE
LOWbackend_api_python/app/professional_report/snapshot.py215CODE
LOW…_api_python/app/professional_report/features/crypto.py139CODE
LOW…_api_python/app/professional_report/features/crypto.py292CODE
LOW…_api_python/app/professional_report/features/crypto.py421CODE
LOW…_api_python/app/professional_report/features/crypto.py513CODE
LOWbackend_api_python/app/data_providers/heatmap.py143CODE
LOWbackend_api_python/app/data_providers/heatmap.py163CODE
LOWbackend_api_python/app/data_providers/forex.py29CODE
LOWbackend_api_python/app/data_providers/forex.py69CODE
LOWbackend_api_python/app/data_providers/forex.py109CODE
LOWbackend_api_python/app/data_providers/forex.py158CODE
LOWbackend_api_python/app/data_providers/sentiment.py45CODE
LOWbackend_api_python/app/data_providers/sentiment.py114CODE
LOWbackend_api_python/app/data_providers/sentiment.py184CODE
LOWbackend_api_python/app/data_providers/sentiment.py253CODE
LOWbackend_api_python/app/data_providers/sentiment.py289CODE
LOWbackend_api_python/app/data_providers/sentiment.py325CODE
LOWbackend_api_python/app/data_providers/hk_research.py217CODE
LOWbackend_api_python/app/data_providers/__init__.py306CODE
LOWbackend_api_python/app/data_providers/us_research.py560CODE
LOWbackend_api_python/app/data_providers/opportunities.py85CODE
LOWbackend_api_python/app/data_providers/opportunities.py143CODE
LOWbackend_api_python/app/data_providers/opportunities.py236CODE
LOWbackend_api_python/app/data_providers/opportunities.py283CODE
LOWbackend_api_python/app/data_providers/opportunities.py323CODE
LOWbackend_api_python/app/data_providers/opportunities.py384CODE
LOWbackend_api_python/app/data_providers/crypto.py28CODE
LOWbackend_api_python/app/data_providers/crypto.py68CODE
LOW…kend_api_python/app/data_providers/company_research.py94CODE
LOW…kend_api_python/app/data_providers/company_research.py240CODE
LOWbackend_api_python/app/data_providers/commodities.py29CODE
LOWbackend_api_python/app/data_providers/commodities.py67CODE
LOWbackend_api_python/app/data_providers/commodities.py114CODE
LOWbackend_api_python/app/data_providers/commodities.py161CODE
LOWbackend_api_python/app/data_providers/indices.py30CODE
LOWbackend_api_python/app/data_providers/news.py15CODE
LOWbackend_api_python/app/workers/lease_heartbeat.py107CODE
LOWbackend_api_python/app/workers/trading.py166CODE
LOWbackend_api_python/app/workers/trading.py209CODE
LOWbackend_api_python/app/workers/trading.py396CODE
LOW…kend_api_python/app/data_sources/cn_hk_fundamentals.py103CODE
321 more matches not shown…
Modern Structural Boilerplate105 hits · 106 pts
SeverityFileLineSnippetContext
LOWbackend_api_python/run.py62 def _set_if_blank(key: str, value: str) -> None:CODE
LOWbackend_api_python/app/celery_app.py94__all__ = ["celery_app"]CODE
LOWbackend_api_python/app/config/__init__.py15__all__ = [CODE
LOWbackend_api_python/app/runtime/__init__.py5__all__ = ["ProcessRole", "current_process_role"]CODE
LOWbackend_api_python/app/utils/db.py414__all__ = [CODE
LOWbackend_api_python/app/utils/config_loader.py70 def set_nested(cfg: Dict[str, Any], dotted_key: str, value: Any) -> None:CODE
LOWbackend_api_python/app/utils/timeutil.py112__all__ = ["to_utc_iso"]CODE
LOWbackend_api_python/app/utils/__init__.py8__all__ = ['get_logger', 'CacheManager', 'get_retry_session']CODE
LOWbackend_api_python/app/utils/broker_session.py119__all__ = ['BrokerSessionRegistry']CODE
LOWbackend_api_python/app/utils/numeric_precision.py75__all__ = [CODE
LOW⚡backend_api_python/app/utils/safe_exec_worker.py259 def set_universe(self, *args: Any, **kwargs: Any) -> None:CODE
LOW⚡backend_api_python/app/utils/safe_exec_worker.py262 def set_benchmark(self, *args: Any, **kwargs: Any) -> None:CODE
LOW⚡backend_api_python/app/utils/safe_exec_worker.py268 def set_warmup(self, *args: Any, **kwargs: Any) -> None:CODE
LOW⚡backend_api_python/app/utils/safe_exec_worker.py274 def set_metadata(self, *args: Any, **kwargs: Any) -> None:CODE
LOWbackend_api_python/app/observability/__init__.py10__all__ = ["init_http_observability"]CODE
LOWbackend_api_python/app/observability/db_metrics.py31__all__ = [CODE
LOWbackend_api_python/app/openapi/schemas/__init__.py11__all__ = [CODE
LOW…end_api_python/app/professional_report/llm_contract.py104__all__ = ["FastAnalysisNarrative", "validate_llm_analysis"]CODE
LOWbackend_api_python/app/professional_report/__init__.py9__all__ = ["build_professional_report"]CODE
LOWbackend_api_python/app/professional_report/narrative.py77__all__ = ["has_mojibake", "normalize_report_text", "numeric_tokens", "validate_evidence_claims"]CODE
LOWbackend_api_python/app/professional_report/builder.py754__all__ = ["build_professional_report"]CODE
LOWbackend_api_python/app/professional_report/contracts.py366__all__ = [CODE
LOWbackend_api_python/app/professional_report/risk.py216__all__ = ["build_risk_plan"]CODE
LOWbackend_api_python/app/professional_report/prompt.py183__all__ = ["build_professional_analysis_prompt"]CODE
LOWbackend_api_python/app/professional_report/quality.py189__all__ = ["apply_quality_gate", "assess_snapshot_quality"]CODE
LOWbackend_api_python/app/professional_report/snapshot.py466__all__ = ["build_evidence_snapshot"]CODE
LOW…pi_python/app/professional_report/providers/catalog.py573__all__ = [CODE
LOW…i_python/app/professional_report/providers/__init__.py22__all__ = [CODE
LOW…_api_python/app/professional_report/features/equity.py164__all__ = ["build_equity_features"]CODE
LOW…pi_python/app/professional_report/features/__init__.py7__all__ = [CODE
LOW…_api_python/app/professional_report/features/crypto.py775__all__ = ["VERSION", "build_crypto_features", "extract_crypto_features"]CODE
LOWbackend_api_python/app/data_providers/hk_research.py275__all__ = [CODE
LOWbackend_api_python/app/data_providers/us_research.py617__all__ = [CODE
LOWbackend_api_python/app/data_providers/news.py75__all__ = ["fetch_financial_news", "get_economic_calendar", "get_economic_calendar_payload"]CODE
LOWbackend_api_python/app/data_sources/cache_manager.py23logger = logging.getLogger(__name__)CODE
LOWbackend_api_python/app/data_sources/rate_limiter.py18logger = logging.getLogger(__name__)CODE
LOWbackend_api_python/app/data_sources/__init__.py13__all__ = [CODE
LOWbackend_api_python/app/data_sources/__init__.py35__all__ = [CODE
LOWbackend_api_python/app/data_sources/circuit_breaker.py21logger = logging.getLogger(__name__)CODE
LOWbackend_api_python/app/data_sources/native_crypto.py628__all__ = [CODE
LOWbackend_api_python/app/events/dispatcher.py82__all__ = ["StrategyDueDispatcher"]CODE
LOWbackend_api_python/app/events/protocol.py297__all__ = [CODE
LOWbackend_api_python/app/events/__init__.py19__all__ = [CODE
LOWbackend_api_python/app/events/bar_clock.py266__all__ = [CODE
LOWbackend_api_python/app/events/bus.py118__all__ = ["EventBus", "EventSubscription", "InMemoryEventBus"]CODE
LOWbackend_api_python/app/events/topics.py98__all__ = ["TopicSpec", "event_topic_map", "topic_for_event", "topic_specs"]CODE
LOWbackend_api_python/app/events/kafka.py300__all__ = [CODE
LOWbackend_api_python/app/events/evaluator.py252__all__ = ["StrategyEvaluationBatchHandler"]CODE
LOW…nd_api_python/app/services/shared_market_price_feed.py229__all__ = [CODE
LOWbackend_api_python/app/services/event_inbox.py272__all__ = [CODE
LOW…pi_python/app/services/strategy_event_subscriptions.py210__all__ = [CODE
LOWbackend_api_python/app/services/virtual_trading.py853__all__ = [CODE
LOWbackend_api_python/app/services/ai_copilot_store.py440def update_request_usage(cur, request_id: int, **values: Any) -> None:CODE
LOW…nd_api_python/app/services/distributed_runtime_host.py201__all__ = ["DistributedRuntimeHost"]CODE
LOWbackend_api_python/app/services/trading_executor.py63__all__ = ["TradingExecutor", "live_history_days"]CODE
LOWbackend_api_python/app/services/trading_executor.py158 def set_runtime_fencing_token(self, strategy_id: int, fencing_token: int) -> None:CODE
LOWbackend_api_python/app/services/strategy_daily_pnl.py476__all__ = [STRING
LOW…end_api_python/app/services/virtual_execution_costs.py106__all__ = [CODE
LOWbackend_api_python/app/services/usdt_payment_service.py17__all__ = [CODE
LOW…end_api_python/app/services/alpaca_trading/__init__.py19__all__ = ['AlpacaClient', 'AlpacaConfig', 'normalize_symbol', 'parse_symbol']CODE
45 more matches not shown…
AI Slop Vocabulary22 hits · 55 pts
SeverityFileLineSnippetContext
MEDIUMbackend_api_python/app/routes/quick_trade.py435 # Swap input is margin and expands by leverage.COMMENT
MEDIUMbackend_api_python/app/routes/quick_trade.py528 # 50 USDT notional at leverage=1 needs ~50 USDT collateral. Many usersCOMMENT
MEDIUM⚡backend_api_python/app/routes/global_market.py146 """Get comprehensive market sentiment indicators."""STRING
MEDIUM…end_api_python/app/services/ai_generation_contracts.py97## Contract leverageCOMMENT
MEDIUM⚡backend_api_python/app/services/pending_order_worker.py1826 # - For OKX swap, leverage must be set via private endpoint; otherwise exchange defaults apply.COMMENT
MEDIUM⚡backend_api_python/app/services/pending_order_worker.py1827 # - For other exchanges, leverage setting is not implemented yet in this local client.COMMENT
MEDIUMbackend_api_python/app/services/llm.py1405 """Safe LLM call with robust JSON parsing and fallback structure."""STRING
LOWbackend_api_python/app/services/symbol_name.py229 # 1) Seed (already in our DB — nothing to learn, just return).COMMENT
MEDIUMbackend_api_python/app/services/indicator_workspace.py66 "# @strategy, # signal_form, # exit_owner, # flip_mode, # timeframe, risk, leverage, trade direction, stop lCODE
MEDIUM⚡backend_api_python/app/services/portfolio_monitor.py464 """Build a comprehensive text report (backward compatible)."""STRING
MEDIUMbackend_api_python/app/services/live_trading/okx.py78 # Best-effort cache for leverage settings to avoid spamming set-leverage on every tick.COMMENT
MEDIUM…hon/app/services/live_trading/account_configuration.py97 """Apply requested leverage and margin mode or reject the order."""STRING
MEDIUMbackend_api_python/app/services/live_trading/bitget.py78 # Best-effort cache for leverage settings to avoid spamming set-leverage on every tick.COMMENT
MEDIUMbackend_api_python/app/services/live_trading/gate.py901 # Gate expects ``leverage`` / ``cross_leverage_limit`` as **query parameters**, not JSON bodyCOMMENT
MEDIUMbackend_api_python/app/services/live_trading/gate.py902 # (see gateapi-python: update_position_leverage). Cross / portfolio mode: leverage=0 + cross_leverage_limit.COMMENT
MEDIUMbackend_api_python/app/services/live_trading/binance.py1086 """Read back symbol-level margin mode and leverage from positionRisk.STRING
MEDIUM…d_api_python/app/services/usdt_payment/watchers/evm.py118# mainnet, and Etherscan's indexed tokentx endpoint is more robustCOMMENT
MEDIUMbackend_api_python/app/services/grid/engine.py1569 """One grid line's base quantity (amountPerGrid × leverage / price), exchange-normalized."""STRING
MEDIUMbackend_api_python/tests/test_grid_engine.py508 """100 USDT * 20% margin * 20x leverage ≈ 400 USDT notional at 72710."""STRING
MEDIUM⚡backend_api_python/tests/test_indicator_code_quality.py74# @strategy leverage 2COMMENT
MEDIUM⚡backend_api_python/tests/test_risk_pct_basis.py62 # 92 / 100 = -8% > -9% — must NOT trigger even at 10x leverage.COMMENT
MEDIUMbackend_api_python/tests/test_risk_pct_basis.py114 # 16% price move required regardless of leverage.COMMENT
Cross-File Repetition10 hits · 50 pts
SeverityFileLineSnippetContext
HIGH…api_python/app/services/strategy_command_repository.py0select 1 from qd_strategy_runtime_leases where strategy_id = %s and fencing_token = %s and lease_expires_at >= now() limSTRING
HIGHbackend_api_python/app/services/strategy.py0select 1 from qd_strategy_runtime_leases where strategy_id = %s and fencing_token = %s and lease_expires_at >= now() limSTRING
HIGH…_api_python/app/services/strategy_v2/live_execution.py0select 1 from qd_strategy_runtime_leases where strategy_id = %s and fencing_token = %s and lease_expires_at >= now() limSTRING
HIGHbackend_api_python/app/services/live_trading/bybit.py0convert decimal to string with controlled precision. bitget requires quantities to match sizestep/sizeplace precision. aSTRING
HIGH…nd_api_python/app/services/live_trading/bitget_spot.py0convert decimal to string with controlled precision. bitget requires quantities to match sizestep/sizeplace precision. aSTRING
HIGHbackend_api_python/app/services/live_trading/bitget.py0convert decimal to string with controlled precision. bitget requires quantities to match sizestep/sizeplace precision. aSTRING
HIGHbackend_api_python/tests/test_agent_current_contract.py0def initialize(context): context.set_universe(["usstock:aapl"]) context.subscribe(frequency="1d") def handle_data(contexSTRING
HIGHbackend_api_python/tests/test_strategy_evolution.py0def initialize(context): context.set_universe(["usstock:aapl"]) context.subscribe(frequency="1d") def handle_data(contexSTRING
HIGHbackend_api_python/tests/test_strategy_v2_service.py0def initialize(context): context.set_universe(["usstock:aapl"]) context.subscribe(frequency="1d") def handle_data(contexSTRING
HIGHbackend_api_python/tests/test_strategy_v2_runtime.py0def initialize(context): context.set_universe(["usstock:aapl"]) context.subscribe(frequency="1d") def handle_data(contexSTRING
Structural Annotation Overuse28 hits · 47 pts
SeverityFileLineSnippetContext
LOWdocs/deployment/OAUTH_CONFIG_EN.md17### Step 1: Create a Google Cloud ProjectCOMMENT
LOWdocs/deployment/OAUTH_CONFIG_EN.md23### Step 2: Configure OAuth Consent ScreenCOMMENT
LOWdocs/deployment/OAUTH_CONFIG_EN.md35### Step 3: Create OAuth 2.0 Client IDCOMMENT
LOWdocs/deployment/OAUTH_CONFIG_EN.md49### Step 4: Configure .env FileCOMMENT
LOWdocs/deployment/OAUTH_CONFIG_EN.md62### Step 1: Create GitHub OAuth AppCOMMENT
LOWdocs/deployment/OAUTH_CONFIG_EN.md75### Step 2: Get CredentialsCOMMENT
LOWdocs/deployment/OAUTH_CONFIG_EN.md81### Step 3: Configure .env FileCOMMENT
LOW⚡docs/deployment/OAUTH_CONFIG_EN.md96### Step 1: Create Turnstile WidgetCOMMENT
LOW⚡docs/deployment/OAUTH_CONFIG_EN.md106### Step 2: Get KeysCOMMENT
LOW⚡docs/deployment/OAUTH_CONFIG_EN.md112### Step 3: Configure .env FileCOMMENT
LOWdocs/deployment/NOTIFICATION_EMAIL_CONFIG_EN.md48### Step 1: Obtain SMTP Service InformationCOMMENT
LOW⚡docs/deployment/NOTIFICATION_EMAIL_CONFIG_EN.md67### Step 2: Configure Environment VariablesCOMMENT
LOWdocs/deployment/NOTIFICATION_EMAIL_CONFIG_EN.md103### Step 3: Enable Email Notifications in StrategyCOMMENT
LOWdocs/deployment/NOTIFICATION_SMS_CONFIG_EN.md45### Step 1: Create a Twilio AccountCOMMENT
LOWdocs/deployment/NOTIFICATION_SMS_CONFIG_EN.md57### Step 2: Obtain API CredentialsCOMMENT
LOWdocs/deployment/NOTIFICATION_SMS_CONFIG_EN.md71### Step 3: Get a Phone NumberCOMMENT
LOW⚡docs/deployment/NOTIFICATION_SMS_CONFIG_EN.md87### Step 4: Configure Environment VariablesCOMMENT
LOWdocs/deployment/NOTIFICATION_SMS_CONFIG_EN.md113### Step 5: Enable SMS Notifications in StrategyCOMMENT
LOWdocs/deployment/NOTIFICATION_TELEGRAM_CONFIG_EN.md27## Step 1: Create a Telegram BotCOMMENT
LOWdocs/deployment/NOTIFICATION_TELEGRAM_CONFIG_EN.md36## Step 2: Obtain Bot TokenCOMMENT
LOWdocs/deployment/NOTIFICATION_TELEGRAM_CONFIG_EN.md48## Step 3: Get Your User IDCOMMENT
LOWdocs/deployment/NOTIFICATION_TELEGRAM_CONFIG_EN.md71## Step 4: Configure Environment VariablesCOMMENT
LOWdocs/deployment/NOTIFICATION_TELEGRAM_CONFIG_EN.md84## Step 5: Enable Telegram Notifications in StrategyCOMMENT
LOW⚡backend_api_python/app/routes/auth.py175 # Step 1: Verify Turnstile (if enabled)COMMENT
LOW⚡backend_api_python/app/routes/auth.py184 # Step 2: Check rate limitingCOMMENT
LOW⚡backend_api_python/app/routes/auth.py191 # Step 3: AuthenticateCOMMENT
LOWbackend_api_python/app/routes/auth.py272 # Step 4: Record successful loginCOMMENT
LOW…pi_python/app/services/usdt_payment/watchers/solana.py183 # Step 1: resolve the watched account.COMMENT
Redundant / Tautological Comments24 hits · 33 pts
SeverityFileLineSnippetContext
LOWscripts/generate-secret-key.sh9# Check if .env exists.COMMENT
LOWbackend_api_python/docker-entrypoint.sh11# Check if .env file existsCOMMENT
LOW⚡backend_api_python/app/routes/auth.py197 # Check if user has no password set (code-login user)COMMENT
LOWbackend_api_python/app/routes/auth.py416 # Check if user existsCOMMENT
LOWbackend_api_python/app/routes/auth.py421 # Check if registration is enabledCOMMENT
LOWbackend_api_python/app/routes/auth.py719 # Check if registration is enabledCOMMENT
LOWbackend_api_python/app/routes/auth.py764 # Check if username already existsCOMMENT
LOWbackend_api_python/app/routes/auth.py769 # Check if email already existsCOMMENT
LOWbackend_api_python/app/routes/portfolio.py86 # Check if force refresh (skip cache)COMMENT
LOWbackend_api_python/app/routes/portfolio.py316 # Check if force refreshCOMMENT
LOWbackend_api_python/app/routes/portfolio.py728 # Check if alert already exists for this position (unique constraint)COMMENT
LOWbackend_api_python/app/services/pending_order_worker.py1727 # Check if this is an IBKR client (US stocks)COMMENT
LOW⚡backend_api_python/app/services/oauth_service.py681 # Check if user has password (can't unlink last auth method)COMMENT
LOW⚡backend_api_python/app/services/oauth_service.py689 # Check if this is the only OAuth linkCOMMENT
LOWbackend_api_python/app/services/oauth_service.py466 # Check if OAuth link existsCOMMENT
LOWbackend_api_python/app/services/oauth_service.py516 # Check if user exists with same emailCOMMENT
LOWbackend_api_python/app/services/llm.py1144 # Check if we have API key for the detected providerCOMMENT
LOWbackend_api_python/app/services/security_service.py275 # Check if still in block periodCOMMENT
LOW⚡backend_api_python/app/services/email_service.py53 # Check if email is properly configuredCOMMENT
LOWbackend_api_python/app/services/email_service.py135 # Check if locked due to too many failed attemptsCOMMENT
LOWbackend_api_python/app/services/email_service.py171 # Check if code matchesCOMMENT
LOWbackend_api_python/app/services/portfolio_monitor.py1530 # Check if we can trigger (not triggered yet, or repeat interval passed)STRING
LOWbackend_api_python/app/services/user_service.py644 # Check if user has no password (code-login user)COMMENT
LOWbackend_api_python/app/services/user_service.py766 # Check if username already existsCOMMENT
Cross-Language Confusion5 hits · 25 pts
SeverityFileLineSnippetContext
HIGHbackend_api_python/app/services/strategy_v2/runtime.py252 key not in updated or not frame.equals(updated[key].iloc[:len(frame)])CODE
HIGHbackend_api_python/app/services/strategy_v2/runtime.py452 or not cached.index.equals(frame.index[:cached_length])CODE
HIGHbackend_api_python/app/services/strategy_v2/data.py304 if any(not baseline.equals(rows.iloc[index]) for index in range(1, len(rows))):CODE
HIGH…ckend_api_python/tests/test_strategy_v2_market_data.py643 assert second.equals(first)CODE
HIGHbackend_api_python/tests/test_llm_litellm_provider.py268 b'data: {"choices":[{"delta":{"content":"partial"},"finish_reason":null}]}',CODE
AI Structural Patterns23 hits · 19 pts
SeverityFileLineSnippetContext
LOWmcp_server/src/quantdinger_mcp/server.py385CODE
LOWmcp_server/src/quantdinger_mcp/server.py629CODE
LOWbackend_api_python/app/professional_report/snapshot.py142CODE
LOWbackend_api_python/app/routes/user.py873CODE
LOWbackend_api_python/app/routes/global_market.py174CODE
LOWbackend_api_python/app/routes/ai_chat.py731CODE
LOWbackend_api_python/app/services/pending_order_worker.py2848CODE
LOWbackend_api_python/app/services/ai_copilot_store.py274CODE
LOWbackend_api_python/app/services/community_service.py251CODE
LOWbackend_api_python/app/services/community_service.py593CODE
LOWbackend_api_python/app/services/research_agent.py151CODE
LOWbackend_api_python/app/services/live_trading/htx_v5.py370CODE
LOWbackend_api_python/app/services/live_trading/records.py478CODE
LOWbackend_api_python/app/services/strategy_v2/service.py44CODE
LOWbackend_api_python/app/services/strategy_v2/service.py145CODE
LOWbackend_api_python/app/services/strategy_v2/runtime.py1704CODE
LOW…api_python/app/services/pending_orders/fill_records.py126CODE
LOW…pi_python/app/services/execution_streams/repository.py15CODE
LOW…_python/app/services/strategy_runtime/order_intents.py84CODE
LOW…d_api_python/app/services/strategy_runtime/identity.py75CODE
LOWbackend_api_python/app/services/grid/engine.py1943CODE
LOWbackend_api_python/app/services/grid/fill_handler.py27CODE
LOWbackend_api_python/app/services/grid/fill_handler.py103CODE
Synthetic Comment Markers2 hits · 16 pts
SeverityFileLineSnippetContext
HIGH⚡backend_api_python/app/services/ai_calibration.py148 # Approx correctness rules (as requested)COMMENT
HIGHbackend_api_python/app/services/ai_report_pdf.py405 "disclaimer": "This report is generated by AI for research only and is not investment advice.",CODE
Over-Commented Block13 hits · 12 pts
SeverityFileLineSnippetContext
LOWdocker-compose.ghcr.yml1# QuantDinger Docker Compose - GHCR prebuilt images (zero-repo deploy)COMMENT
LOWdocker-compose.ghcr.yml21# `migrations/init.sql` idempotently on every start, so no host-side SQLCOMMENT
LOWinstall.sh1#!/usr/bin/env bashCOMMENT
LOWdocker-compose.build.yml1# Override file for local frontend builds.COMMENT
LOWdocker-compose.yml1# QuantDinger Docker Compose - One-Click DeploymentCOMMENT
LOW.github/workflows/docker-publish.yml1name: Publish backend image to GHCRCOMMENT
LOWbackend_api_python/requirements.txt41# Durable background jobs and periodic maintenanceCOMMENT
LOWbackend_api_python/app/services/builtin_indicators.py41# * output['signals'] is chart-only and never drives orders by itselfCOMMENT
LOWbackend_api_python/app/services/oauth_service.py161 # FRONTEND_URL accepts a comma-separated list of origins (the sameCOMMENT
LOWbackend_api_python/app/services/usdt_payment/service.py101 updated_at TIMESTAMP DEFAULT NOW()COMMENT
LOW…d_api_python/app/services/usdt_payment/watchers/evm.py81 "https://bsc-dataseed4.binance.org",COMMENT
LOW…d_api_python/app/services/usdt_payment/watchers/evm.py101# eth_getLogs; we cap at 4800 to stay safely under that. At 0.75s/blockCOMMENT
LOW…pi_python/app/services/usdt_payment/watchers/solana.py181 min_ts = int(ct.timestamp()) - 60 if ct else NoneCOMMENT
Verbosity Indicators5 hits · 9 pts
SeverityFileLineSnippetContext
LOW⚡backend_api_python/app/routes/auth.py175 # Step 1: Verify Turnstile (if enabled)COMMENT
LOW⚡backend_api_python/app/routes/auth.py184 # Step 2: Check rate limitingCOMMENT
LOW⚡backend_api_python/app/routes/auth.py191 # Step 3: AuthenticateCOMMENT
LOWbackend_api_python/app/routes/auth.py272 # Step 4: Record successful loginCOMMENT
LOW…pi_python/app/services/usdt_payment/watchers/solana.py183 # Step 1: resolve the watched account.COMMENT
Modern AI Meta-Vocabulary3 hits · 8 pts
SeverityFileLineSnippetContext
MEDIUMdocker-compose.ghcr.yml17# - .env contains backend runtime settings and Docker Compose orchestration knobs.COMMENT
MEDIUMdocs/architecture/ARCHITECTURE.md52 ai/ # skills, prompts, provider orchestrationCODE
MEDIUMdocs/architecture/V6_HYPERSCALE_ARCHITECTURE_PLAN.md793### Phase 2: event-driven bar evaluationCOMMENT
Fake / Example Data10 hits · 8 pts
SeverityFileLineSnippetContext
LOWbackend_api_python/app/routes/settings.py339 'default': 'admin@example.com',CODE
LOWbackend_api_python/app/routes/settings.py2264 if requested_admin_email and requested_admin_email != 'admin@example.com':CODE
LOWbackend_api_python/app/services/security_service.py28 'placeholder',CODE
LOWbackend_api_python/app/services/user_service.py384 if email == 'admin@example.com':CODE
LOWbackend_api_python/app/services/user_service.py385 return {'synced': False, 'reason': 'placeholder'}CODE
LOWbackend_api_python/app/services/user_service.py415 if current_email and current_email != 'admin@example.com' and not overwrite_existing:CODE
LOWbackend_api_python/app/services/user_service.py1128 admin_email = os.getenv('ADMIN_EMAIL', 'admin@example.com')CODE
LOWbackend_api_python/tests/test_db_log_noise_fixes.py80 result = service.start_setup(9383, "user@example.com")CODE
LOW…ckend_api_python/tests/test_initial_password_policy.py88 "email": "admin@example.com",CODE
LOW…ckend_api_python/tests/test_initial_password_policy.py162 "email": "admin@example.com",CODE
Dead Code3 hits · 6 pts
SeverityFileLineSnippetContext
MEDIUMbackend_api_python/app/data_sources/factory.py139CODE
MEDIUMbackend_api_python/app/data_sources/factory.py144CODE
MEDIUM…kend_api_python/tests/test_ai_chat_snapshot_quality.py238CODE
Example Usage Blocks3 hits · 4 pts
SeverityFileLineSnippetContext
LOWinstall.sh5# Usage:COMMENT
LOWdocker-compose.build.yml2# Usage:COMMENT
LOWdocker-compose.yml2# Usage:COMMENT