AI Slop Code RIsk Monitor

Hoper-J/AI-Guide-and-Demos-zh_CN

这是一份入门AI/LLM大模型的逐步指南,包含教程和演示代码,带你从API走进本地大模型部署和微调,代码文件会提供Kaggle或Colab在线版本,即便没有显卡也可以进行学习。项目中还开设了一个小型的代码游乐场🎡,你可以尝试在里面实验一些有意思的AI脚本。同时,包含李宏毅 (HUNG-YI LEE)2024生成式人工智能导论课程的完整中文镜像作业。

8.0 Moderate pattern signal View on GitHub

Maintenance and Governance Review

This report summarizes scanner evidence for Hoper-J/AI-Guide-and-Demos-zh_CN, a Python project with 4,676 GitHub stars. SynthScan examined 42,487 lines of code across 80 source files, recording 149 pattern matches distributed across 10 syntactic categories. The legacy adjusted pattern signal is 8.0 (Moderate 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.

8.0
Adjusted Signal
8.0
Raw Pattern Score
100%
Time Factor
2026-09-28
Last Push
4.7K
Stars
Python
Language
42.5K
Lines of Code
80
Files
149
Pattern Hits
2026-10-12
Scan Date
0.45
HC Hit Rate

Risk Review · v3

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

Cognitive Ownership Risk 5.7/100 · LOW

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

Hallucinated Dependency & Supply Chain Risk 21.0/100 · LOW

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

Agent Over-Engineering Ratio 12.5/100 · LOW

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

PR Review Velocity Impact 35.4/100 · MEDIUM

Which changes need focused human review? 149 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 1HIGH 35MEDIUM 19LOW 94

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 149 distinct pattern matches across 10 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.

Magic Placeholder Names35 hits · 182 pts
SeverityFileLineSnippetContext
HIGHGuide/DeepSeek API 流式输出解析 - OpenAI SDK.md28 api_key="your-api-key",CODE
HIGHGuide/DeepSeek API 流式输出解析 - OpenAI SDK.md216 api_key="your-api-key",CODE
HIGHGuide/DeepSeek API 多轮对话 - OpenAI SDK.md49os.environ["DEEPSEEK_API_KEY"] = "your-api-key"CODE
HIGHGuide/DeepSeek API 多轮对话 - OpenAI SDK.md81os.environ["DEEPSEEK_API_KEY"] = "your-api-key"CODE
HIGHGuide/DeepSeek API 多轮对话 - OpenAI SDK.md199os.environ["DEEPSEEK_API_KEY"] = "your-api-key"CODE
HIGHGuide/DeepSeek API 多轮对话 - OpenAI SDK.md305os.environ["DEEPSEEK_API_KEY"] = "your-api-key"CODE
HIGHGuide/DeepSeek API 多轮对话 - OpenAI SDK.md364os.environ["DEEPSEEK_API_KEY"] = "your-api-key"CODE
HIGHGuide/DeepSeek API 多轮对话 - OpenAI SDK.md405os.environ["DEEPSEEK_API_KEY"] = "your-api-key"CODE
HIGHGuide/DeepSeek API 多轮对话 - OpenAI SDK.md465os.environ["DEEPSEEK_API_KEY"] = "your-api-key"CODE
HIGHGuide/DeepSeek API 多轮对话 - OpenAI SDK.md553os.environ["DEEPSEEK_API_KEY"] = "your-api-key"CODE
HIGHGuide/01. 初识 LLM API:环境配置与多轮对话演示.md57export OPENAI_API_KEY="your-api-key"CODE
HIGHGuide/01. 初识 LLM API:环境配置与多轮对话演示.md63set OPENAI_API_KEY=your-api-keyCODE
HIGH⚡Guide/01. 初识 LLM API:环境配置与多轮对话演示.md75 echo 'export OPENAI_API_KEY="your-api-key"' >> ~/.bashrcCODE
HIGH⚡Guide/01. 初识 LLM API:环境配置与多轮对话演示.md82 echo 'export OPENAI_API_KEY="your-api-key"' >> ~/.zshrcCODE
HIGH⚡Guide/01. 初识 LLM API:环境配置与多轮对话演示.md91 echo export OPENAI_API_KEY="your-api-key" >> %USERPROFILE%\Documents\WindowsPowerShell\Microsoft.PowerShell_profile.CODE
HIGHGuide/01. 初识 LLM API:环境配置与多轮对话演示.md102os.environ['OPENAI_API_KEY'] = 'your-api-key'CODE
HIGHGuide/01. 初识 LLM API:环境配置与多轮对话演示.md152 api_key=os.getenv('OPENAI_API_KEY'), # 如果你没有配置环境变量,使用 api_key="your-api-key" 替换CODE
HIGHGuide/01. 初识 LLM API:环境配置与多轮对话演示.md175>注意,不要误用成 `api_key=os.getenv("your-api-key")`,`os.getenv()`用于获取对应系统环境变量的值,API本身并不是这个环境变量,正确的用法是 ``api_key="your-api-key"CODE
HIGHGuide/01. 初识 LLM API:环境配置与多轮对话演示.md319os.environ['ZHIPUAI_API_KEY'] = 'your-api-key' # 1CODE
HIGHGuide/01. 初识 LLM API:环境配置与多轮对话演示.md453os.environ['DEEPSEEK_API_KEY'] = 'your-api-key' # 1CODE
HIGHGuide/DeepSeek API 统一模型对话逻辑与流式输出.md189 "api_key": "your-api-key",CODE
HIGHGuide/DeepSeek API 统一模型对话逻辑与流式输出.md205> api_key="your-api-key",CODE
HIGHGuide/DeepSeek API 统一模型对话逻辑与流式输出.md413 "api_key": "your-api-key",CODE
HIGHGuide/DeepSeek API 统一模型对话逻辑与流式输出.md435 "api_key": "your-api-key",CODE
HIGHGuide/DeepSeek API 输出解析 - OpenAI SDK.md30 api_key="your-api-key", # 1:替换成对应的 API_Key,可以使用环境变量而非明文填写,即 api_key=os.getenv("DEEPSEEK_API_KEY")CODE
HIGHGuide/DeepSeek API 输出解析 - OpenAI SDK.md66- api_key="your-api-key", #1CODE
HIGHGuide/DeepSeek API 输出解析 - OpenAI SDK.md73+ api_key="your-api-key", #1CODE
HIGHGuide/DeepSeek API 输出解析 - OpenAI SDK.md87 api_key="your-api-key", # 1:替换成对应的 API_KeyCODE
HIGHGuide/DeepSeek API 输出解析 - OpenAI SDK.md293 api_key="your-api-key", # 1:替换成对应的 API_KeyCODE
HIGHGuide/DeepSeek API 的获取与对话示例.md72os.environ["DEEPSEEK_API_KEY"] = "your-api-key" # 1CODE
HIGHGuide/DeepSeek API 的获取与对话示例.md139os.environ["SILICONFLOW_API_KEY"] = "your-api-key" # 1CODE
HIGHGuide/DeepSeek API 的获取与对话示例.md223os.environ["DASHSCOPE_API_KEY"] = "your-api-key" # 1CODE
HIGHGuide/DeepSeek API 的获取与对话示例.md290os.environ["BAIDU_API_KEY"] = "your-api-key" # 1CODE
HIGHGuide/DeepSeek API 的获取与对话示例.md408os.environ["ARK_API_KEY"] = "your-api-key" # 1CODE
HIGHCodePlayground/README.md117uv run python summarizer.py file_path [--api_key YOUR_API_KEY] [--output_dir OUTPUT_DIR] [其他可选参数]CODE
Excessive Try-Catch Wrapping48 hits · 48 pts
SeverityFileLineSnippetContext
LOWGuide/03. 进阶指南:自定义 Prompt 提升大模型解题能力.md98except Exception as e:CODE
LOWGuide/03. 进阶指南:自定义 Prompt 提升大模型解题能力.md151 except Exception:CODE
LOWGuide/03. 进阶指南:自定义 Prompt 提升大模型解题能力.md195 except Exception as e:CODE
LOWGuide/03. 进阶指南:自定义 Prompt 提升大模型解题能力.md216 except Exception as e:CODE
LOWGuide/03. 进阶指南:自定义 Prompt 提升大模型解题能力.md237 except Exception as e:CODE
LOWGuide/02. 简单入门:通过 API 与 Gradio 构建 AI 应用.md70except Exception as e:CODE
LOWGuide/02. 简单入门:通过 API 与 Gradio 构建 AI 应用.md287 except Exception as e:CODE
LOWGuide/02. 简单入门:通过 API 与 Gradio 构建 AI 应用.md425 except Exception as e:CODE
LOW…6. 用 LoRA 微调 Stable Diffusion:拆开炼丹炉,动手实现你的第一次 AI 绘画.md142except Exception:CODE
LOW…6. 用 LoRA 微调 Stable Diffusion:拆开炼丹炉,动手实现你的第一次 AI 绘画.md440 except Exception as e:CODE
LOW…e/深入 FastMCP 源码:认识 tool()、resource() 和 prompt() 装饰器.md1238 except Exception as e:CODE
LOW…e/深入 FastMCP 源码:认识 tool()、resource() 和 prompt() 装饰器.md1363 except Exception as e:CODE
LOW…e/深入 FastMCP 源码:认识 tool()、resource() 和 prompt() 装饰器.md1421 except Exception as e:CODE
LOW…e/深入 FastMCP 源码:认识 tool()、resource() 和 prompt() 装饰器.md1882 except Exception as e:CODE
LOW…e/深入 FastMCP 源码:认识 tool()、resource() 和 prompt() 装饰器.md1927 except Exception as e:CODE
LOW…e/深入 FastMCP 源码:认识 tool()、resource() 和 prompt() 装饰器.md2019 except Exception as e:CODE
LOW…e/深入 FastMCP 源码:认识 tool()、resource() 和 prompt() 装饰器.md2071 except Exception as e:CODE
LOW…e/深入 FastMCP 源码:认识 tool()、resource() 和 prompt() 装饰器.md2082 except Exception as e:CODE
LOW…e/深入 FastMCP 源码:认识 tool()、resource() 和 prompt() 装饰器.md2092 except Exception as e:CODE
LOW…GUF 模型(分片 & Shared & Split & 00001-of-0000...的解决方法).md239except Exception as e:CODE
LOW…GUF 模型(分片 & Shared & Split & 00001-of-0000...的解决方法).md257except Exception as e:CODE
LOW…GUF 模型(分片 & Shared & Split & 00001-of-0000...的解决方法).md274except Exception as e:CODE
LOW…GUF 模型(分片 & Shared & Split & 00001-of-0000...的解决方法).md285except Exception as e:CODE
LOW…GUF 模型(分片 & Shared & Split & 00001-of-0000...的解决方法).md502except Exception as e:CODE
LOW…GUF 模型(分片 & Shared & Split & 00001-of-0000...的解决方法).md516except Exception as e:CODE
LOW…GUF 模型(分片 & Shared & Split & 00001-of-0000...的解决方法).md532except Exception as e:CODE
LOW…GUF 模型(分片 & Shared & Split & 00001-of-0000...的解决方法).md543except Exception as e:CODE
LOW…9b. 从加载到对话:使用 Llama-cpp-python 本地运行量化 LLM 大模型(GGUF).md476 except Exception as e:CODE
LOWCodePlayground/chat.py91 except Exception as e:CODE
LOWCodePlayground/chat.py197 except Exception as e:CODE
LOWCodePlayground/chat.py371 except Exception as e:CODE
LOWCodePlayground/chat.py439 except Exception as e:CODE
LOWCodePlayground/summarizer.py90 except Exception as e:CODE
LOWCodePlayground/summarizer.py145 except Exception as e:CODE
LOWCodePlayground/summarizer.py200 except Exception as e:CODE
LOWCodePlayground/summarizer.py348 except Exception as e:STRING
LOWCodePlayground/sd_lora.py97 except Exception as e:CODE
LOWCodePlayground/utils/config_manager.py48 except Exception as e:CODE
LOWCodePlayground/utils/config_manager.py81 except Exception as e:CODE
LOWDemos/mcp/debug_func_metadata.py30 except Exception as e:CODE
LOWDemos/mcp/debug_func_metadata.py155 except Exception as e:CODE
LOWDemos/mcp/debug_func_metadata.py213 except Exception as e:CODE
LOWDemos/mcp/debug_message_validator.py135 except Exception as e:CODE
LOWDemos/mcp/debug_message_validator.py180 except Exception as e:CODE
LOWDemos/mcp/debug_message_validator.py272 except Exception as e:CODE
LOWDemos/mcp/debug_message_validator.py324 except Exception as e:CODE
LOWDemos/mcp/debug_message_validator.py335 except Exception as e:CODE
LOWDemos/mcp/debug_message_validator.py345 except Exception as e:CODE
Decorative Section Separators14 hits · 42 pts
SeverityFileLineSnippetContext
MEDIUMGuide/07. 探究模型参数与显存的关系以及不同精度造成的影响.md561# ---------------------------COMMENT
MEDIUMGuide/07. 探究模型参数与显存的关系以及不同精度造成的影响.md563# ---------------------------COMMENT
MEDIUMGuide/07. 探究模型参数与显存的关系以及不同精度造成的影响.md574# ---------------------------COMMENT
MEDIUMGuide/07. 探究模型参数与显存的关系以及不同精度造成的影响.md576# ---------------------------COMMENT
MEDIUMGuide/07. 探究模型参数与显存的关系以及不同精度造成的影响.md622# ---------------------------COMMENT
MEDIUMGuide/07. 探究模型参数与显存的关系以及不同精度造成的影响.md624# ---------------------------COMMENT
MEDIUMGuide/07. 探究模型参数与显存的关系以及不同精度造成的影响.md660# ---------------------------COMMENT
MEDIUMGuide/07. 探究模型参数与显存的关系以及不同精度造成的影响.md662# ---------------------------COMMENT
MEDIUMCodePlayground/chat.py1# ===============================================================COMMENT
MEDIUMCodePlayground/chat.py16# ===============================================================COMMENT
MEDIUMCodePlayground/summarizer.py1# ===============================================================COMMENT
MEDIUMCodePlayground/summarizer.py15# ===============================================================COMMENT
MEDIUMCodePlayground/sd_lora.py1# ===============================================================COMMENT
MEDIUMCodePlayground/sd_lora.py14# ===============================================================COMMENT
Hyper-Verbose Identifiers24 hits · 24 pts
SeverityFileLineSnippetContext
LOWGuide/17. 浅谈 RTN 模型量化:非对称 vs 对称.md530def pytorch_quantize_symmetric(fp32_tensor):CODE
LOWGuide/17. 浅谈 RTN 模型量化:非对称 vs 对称.md559def custom_quantize_compare_symmetric(fp32_values):CODE
LOWGuide/14. PEFT:在大模型中快速应用 LoRA.md153def print_trainable_parameters(model):CODE
LOWGuide/07. 探究模型参数与显存的关系以及不同精度造成的影响.md383def load_model_and_measure_memory(precision, model_name, device):CODE
LOWGuide/21. BPE vs WordPiece:理解 Tokenizer 的工作原理与子词分割方法.md544def count_char_pairs_wordpiece(word_freq):CODE
LOWGuide/21. BPE vs WordPiece:理解 Tokenizer 的工作原理与子词分割方法.md715def count_char_pairs_wordpiece(word_freq):CODE
LOW…e/f. 交叉熵损失函数 nn.CrossEntropyLoss() 详解和要点提醒(PyTorch).md538def custom_weighted_cross_entropy(logits, targets, weights):CODE
LOW…e/f. 交叉熵损失函数 nn.CrossEntropyLoss() 详解和要点提醒(PyTorch).md559def custom_label_smoothing_cross_entropy(logits, targets, alpha):CODE
LOW…e/f. 交叉熵损失函数 nn.CrossEntropyLoss() 详解和要点提醒(PyTorch).md581def custom_both_cross_entropy(logits, targets, weights, alpha):CODE
LOW…e/深入 FastMCP 源码:认识 tool()、resource() 和 prompt() 装饰器.md1933def demo_prompt_render_simulation():CODE
LOW…e/深入 FastMCP 源码:认识 tool()、resource() 和 prompt() 装饰器.md1968 def simulate_render_conversion(result):CODE
LOW…e/深入 FastMCP 源码:认识 tool()、resource() 和 prompt() 装饰器.md2041def debug_pydantic_union_behavior():CODE
LOW…de/Agents/Claude Code 必备的用量监控工具:claude-monitor 实践指南.md558 def calculate_hourly_burn_rate(CODE
LOWPaperNotes/Transformer 论文精读.md693def scaled_dot_product_attention(Q, K, V, mask=None):CODE
LOWPaperNotes/Transformer 论文精读.md1090def scaled_dot_product_attention(Q, K, V, mask=None):CODE
LOWPaperNotes/Transformer 论文精读.md1216def scaled_dot_product_attention(Q, K, V, mask=None):CODE
LOWPaperNotes/Transformer 论文精读.md1355def scaled_dot_product_attention(Q, K, V, mask=None):CODE
LOWPaperNotes/Transformer 论文精读.md1375def scaled_dot_product_attention(Q, K, V, mask=None):CODE
LOWPaperNotes/Transformer 论文精读.md1401def scaled_dot_product_attention(Q, K, V, mask=None):CODE
LOWPaperNotes/Transformer 论文精读.md1564def scaled_dot_product_attention(Q, K, V, mask=None):CODE
LOWCodePlayground/utils/environment_manager.py59 def check_pytorch_transformers(self):CODE
LOWDemos/mcp/debug_message_validator.py186def demo_prompt_render_simulation():CODE
LOWDemos/mcp/debug_message_validator.py221 def simulate_render_conversion(result):CODE
LOWDemos/mcp/debug_message_validator.py294def debug_pydantic_union_behavior():CODE
Modern AI Meta-Vocabulary5 hits · 12 pts
SeverityFileLineSnippetContext
MEDIUMGuide/20. RAG 入门实践:从文档拆分到向量数据库与问答构建.md1# RAG 入门实践:从文档拆分到向量数据库与问答构建COMMENT
MEDIUM…us 4.7,Auto 模式开放,新的思考等级 xhigh,以及“限免3次”的 ultrareview.md101> *More effort control: Opus 4.7 introduces a new `xhigh` (“extra high”) [effort level](https://platform.claude.com/docsCODE
MEDIUMPaperNotes/GPT 论文精读.md63 - [关于 Zero-shot](#关于-zero-shot)CODE
MEDIUMPaperNotes/GPT 论文精读.md79 - [Q1:Zero-Shot、One-Shot 和 Few-Shot 的区别是什么?和 In-Context Learning 有什么关系?与微调有什么不同?](#q1zero-shotone-shot-和-few-shotCODE
MEDIUMPaperNotes/Transformer 论文精读.md3060### Q4: 词嵌入 Word Embedding(输入处理)和句子嵌入 Sentence Embedding(e.g., in RAG)是同一回事吗?COMMENT
Hallucination Indicators1 hit · 10 pts
SeverityFileLineSnippetContext
CRITICALGuide/17. 浅谈 RTN 模型量化:非对称 vs 对称.md671> torch.ao.quantization.observer.UniformQuantizationObserverBase._calculate_qparams()CODE
Over-Commented Block8 hits · 8 pts
SeverityFileLineSnippetContext
LOWGuide/18. 模型量化技术概述及 GGUF & GGML 文件格式解析.md521 // The value is a 16-bit signed little-endian integer.COMMENT
LOWGuide/18. 模型量化技术概述及 GGUF & GGML 文件格式解析.md581 // - It must be a hierarchical key, where each segment is `lower_snake_case` and separated by a `.`.COMMENT
LOWGuide/18. 模型量化技术概述及 GGUF & GGML 文件格式解析.md621struct gguf_tensor_info_t {COMMENT
LOWGuide/18. 模型量化技术概述及 GGUF & GGML 文件格式解析.md641};COMMENT
LOWGuide/18. 模型量化技术概述及 GGUF & GGML 文件格式解析.md661 // This is arbitrary binary data corresponding to the weights of the model. This data should be closeCOMMENT
LOWCodePlayground/chat.py1# ===============================================================COMMENT
LOWCodePlayground/summarizer.py1# ===============================================================COMMENT
LOWCodePlayground/sd_lora.py1# ===============================================================COMMENT
Unused Imports7 hits · 7 pts
SeverityFileLineSnippetContext
LOWCodePlayground/summarizer.py27CODE
LOWCodePlayground/summarizer.py28CODE
LOWCodePlayground/summarizer.py31CODE
LOWCodePlayground/summarizer.py44CODE
LOWCodePlayground/sd_lora.py20CODE
LOWDemos/mcp/debug_func_metadata.py8CODE
LOWDemos/mcp/debug_func_metadata.py8CODE
Deep Nesting6 hits · 6 pts
SeverityFileLineSnippetContext
LOWCodePlayground/chat.py291CODE
LOWCodePlayground/chat.py48CODE
LOWCodePlayground/summarizer.py271CODE
LOWCodePlayground/sd_lora.py375CODE
LOWDemos/mcp/debug_message_validator.py186CODE
LOWDemos/mcp/debug_message_validator.py221CODE
Fake / Example Data1 hit · 1 pts
SeverityFileLineSnippetContext
LOWGuide/Agents/Sub2API 自建中转:把 AI 订阅变成自己的 API Key.md644http_headers = { "x-openai-actor-authorization" = "placeholder" }CODE